|
||||||||||
| 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
public abstract class TextVerifier
InputVerifier subclass that can be also used in non-Swing environments.
It substitutes the default verify(JComponent) method by a verify(String) method. Although not so general as its superclass, it is a valid implementation for text fields.
| Field Summary | |
|---|---|
protected ErrorSupport |
support
The error message. |
| Constructor Summary | |
|---|---|
TextVerifier(ErrorSupport support)
Creates an instance. |
|
| Method Summary | |
|---|---|
abstract void |
cleanErrors()
Removes from the error support manager the list of errors of this verifier. |
protected void |
updateError(java.lang.String id,
boolean add)
Shows the error message if a validation error occurs. |
boolean |
verify(javax.swing.JComponent c)
|
abstract boolean |
verify(java.lang.String text)
Validates a text string. |
| 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 |
|---|
protected ErrorSupport support
| Constructor Detail |
|---|
public TextVerifier(ErrorSupport support)
support - Error message support.| Method Detail |
|---|
public boolean verify(javax.swing.JComponent c)
verify in class javax.swing.InputVerifierpublic abstract boolean verify(java.lang.String text)
text - The string to validate
protected void updateError(java.lang.String id,
boolean add)
id - The error identifieradd - The error actionpublic abstract void cleanErrors()
This method will be used on field deactivation.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||