|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.swing.InputVerifier
com.gridsystems.config.tools.TextVerifier
com.gridsystems.config.tools.NumberVerifier
public class NumberVerifier
Ensures a value is a valid integer between two limits.
| Field Summary | |
|---|---|
protected java.lang.String |
id
Error identifier. |
static java.lang.String |
ID_EMPTY
Error detected by this verifier. |
static java.lang.String |
ID_INVALID
Error detected by this verifier. |
static java.lang.String |
ID_OUTOFRANGE
Error detected by this verifier. |
| Fields inherited from class com.gridsystems.config.tools.TextVerifier |
|---|
support |
| Constructor Summary | |
|---|---|
NumberVerifier(ErrorSupport support,
java.lang.String id)
Creates a new instance with no bounds, and not empty values allowed. |
|
NumberVerifier(ErrorSupport support,
java.lang.String id,
boolean emptyAllowed)
Creates a new instance with no bounds. |
|
NumberVerifier(ErrorSupport support,
java.lang.String id,
int min,
int max,
boolean emptyAllowed)
Creates a new instance. |
|
| Method Summary | |
|---|---|
void |
cleanErrors()
Removes from the error support manager the list of errors of this verifier. |
boolean |
verify(java.lang.String text)
Performs the validation of the specified text. |
| Methods inherited from class com.gridsystems.config.tools.TextVerifier |
|---|
updateError, verify |
| Methods inherited from class javax.swing.InputVerifier |
|---|
shouldYieldFocus |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String ID_EMPTY
public static final java.lang.String ID_OUTOFRANGE
public static final java.lang.String ID_INVALID
protected java.lang.String id
| Constructor Detail |
|---|
public NumberVerifier(ErrorSupport support,
java.lang.String id)
support - The ErrorSupport instanceid - The error identifier
public NumberVerifier(ErrorSupport support,
java.lang.String id,
boolean emptyAllowed)
support - The ErrorSupport instanceid - The error identifieremptyAllowed - Whether to allow empty values or not
public NumberVerifier(ErrorSupport support,
java.lang.String id,
int min,
int max,
boolean emptyAllowed)
support - The ErrorSupport instanceid - The error identifiermin - Minimum valid valuemax - Maximum valid valueemptyAllowed - Whether to allow empty values or not| Method Detail |
|---|
public boolean verify(java.lang.String text)
verify in class TextVerifiertext - The text to verify
public void cleanErrors()
TextVerifierThis method will be used on field deactivation.
cleanErrors in class TextVerifierTextVerifier.cleanErrors()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||