Modifier and Type | Field and Description |
---|---|
static String |
ERROR_CODE
Error code for too many occurrences of a character.
|
protected int |
maxOccurrences
Maximum umber of occurrences to allow.
|
Constructor and Description |
---|
CharacterOccurrencesRule(int maxAllowedOccurrences)
Creates a new character occurrences rule.
|
Modifier and Type | Method and Description |
---|---|
protected Map<String,Object> |
createRuleResultDetailParameters(char c,
int occurrences)
Creates the parameter data for the rule result detail.
|
String |
toString() |
RuleResult |
validate(PasswordData passwordData)
Validates the supplied password data per the requirements of this rule.
|
public static final String ERROR_CODE
protected int maxOccurrences
public CharacterOccurrencesRule(int maxAllowedOccurrences)
maxAllowedOccurrences
- the maximum allowed number of occurrences of any characterpublic RuleResult validate(PasswordData passwordData)
Rule
protected Map<String,Object> createRuleResultDetailParameters(char c, int occurrences)
c
- the character that occurred too many timesoccurrences
- the number of times the character occurredCopyright © 2003-2024 Virginia Tech. All Rights Reserved.