|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.vt.middleware.password.AbstractSequenceRule
public abstract class AbstractSequenceRule
Provide common implementation for keyboard sequence rules.
| Field Summary | |
|---|---|
static int |
DEFAULT_SEQUENCE_LENGTH
Default length of keyboard sequence, value is 5. |
static java.lang.String |
ERROR_CODE
Error code for sequence validation failures. |
static int |
MINIMUM_SEQUENCE_LENGTH
Minimum length of keyboard sequence, value is 3. |
protected int |
sequenceLength
Number of characters in sequence to match. |
protected boolean |
wrapSequence
Whether or not to wrap a sequence when searching for matches. |
| Constructor Summary | |
|---|---|
AbstractSequenceRule()
|
|
| Method Summary | |
|---|---|
protected abstract char[][] |
getSequence(int n)
Returns the sequence of character pairs for which to search. |
protected abstract int |
getSequenceCount()
Returns the number of character sequences used in this implementation. |
protected void |
setSequenceLength(int sl)
Sets the sequence length. |
java.lang.String |
toString()
Returns a string representation of this object. |
RuleResult |
validate(PasswordData passwordData)
Validates the supplied password data per the requirements of this rule. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String ERROR_CODE
public static final int DEFAULT_SEQUENCE_LENGTH
public static final int MINIMUM_SEQUENCE_LENGTH
protected int sequenceLength
protected boolean wrapSequence
| Constructor Detail |
|---|
public AbstractSequenceRule()
| Method Detail |
|---|
public RuleResult validate(PasswordData passwordData)
validate in interface RulepasswordData - to verify (not null).
public java.lang.String toString()
toString in class java.lang.Objectprotected void setSequenceLength(int sl)
sl - sequence lengthprotected abstract char[][] getSequence(int n)
n - provides support for multiple character sequences that are
indexed from 0 to n.
protected abstract int getSequenceCount()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||