@Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        if (getMinPasswordLength()>0)        sb.append("length>=") .append(getMinPasswordLength())             .append(' ');
        if (getMinNumUpperCaseChars()>0)     sb.append("upper>=")  .append(getMinNumUpperCaseChars())          .append(' ');
        if (getMinNumLowerCaseChars()>0)     sb.append("lower>=")  .append(getMinNumLowerCaseChars())          .append(' ');
        if (getMinNumNumericChars()>0)       sb.append("digit>=")  .append(getMinNumNumericChars())            .append(' ');
        if (getMinNumSpecialChars()>0)       sb.append("special>=").append(getMinNumSpecialChars())            .append(' ');
        if (getExpirePasswords())            sb.append("age<=")    .append(getNumberofDaysUntilExpiration())   .append(' ');
        if (getPreventPasswordRepeats())     sb.append("repeat>=") .append(getNumberofPasswordsBeforeRepeats()).append(' ');
        if (getRestrictUserNameInPassword()) sb.append("!user")                                                .append(' ');
        if (sb.length()>0) sb.setLength(sb.length()-1); // truncate final spurious ' '
        return sb.toString();
    }