| 
 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectnl.openedge.baritus.validation.AbstractValidator
nl.openedge.baritus.validation.AbstractFieldValidator
nl.openedge.baritus.validation.impl.RegexValidator
Tests for a match against a regex pattern. if property 'mode' is MODE_VALID_IF_MATCHES (which is the default), isValid returns true if the input matches the pattern. If property mode is MODE_INVALID_IF_MATCHES (i.e. else), isValid returns false if the input matches the pattern.
| Field Summary | |
| static int | MODE_INVALID_IF_MATCHESwhen in this mode, isValid will return false if the input matches the pattern | 
| static int | MODE_VALID_IF_MATCHESwhen in this mode, isValid will return true if the input matches the pattern | 
| Constructor Summary | |
| RegexValidator()construct without parameters | |
| RegexValidator(java.util.regex.Pattern pattern)construct with pattern | |
| RegexValidator(java.util.regex.Pattern pattern,
               int mode)construct with pattern and mode | |
| RegexValidator(java.lang.String errorMessageKey,
               java.util.regex.Pattern pattern)construct with errorMessageKey and pattern | |
| RegexValidator(java.lang.String errorMessageKey,
               java.util.regex.Pattern pattern,
               int mode)construct with message prefix, pattern and mode | |
| RegexValidator(java.lang.String errorMessageKey,
               ValidationActivationRule rule,
               java.util.regex.Pattern pattern)construct with errorMessageKey, rule and pattern | |
| RegexValidator(java.lang.String errorMessageKey,
               ValidationActivationRule rule,
               java.util.regex.Pattern pattern,
               int mode)construct with errorMessageKey, rule, pattern and mode | |
| Method Summary | |
|  java.lang.String | getErrorMessageKey()Get key of error message. | 
|  int | getMode()get mode | 
|  java.util.regex.Pattern | getPattern()get pattern | 
|  boolean | isValid(org.infohazard.maverick.flow.ControllerContext cctx,
        FormBeanContext formBeanContext,
        java.lang.String fieldName,
        java.lang.Object value)Checks if value is valid. | 
|  void | setErrorMessageKey(java.lang.String string)Set key of error message. | 
|  void | setMode(int i)set mode | 
|  void | setPattern(java.util.regex.Pattern pattern)set pattern | 
| Methods inherited from class nl.openedge.baritus.validation.AbstractFieldValidator | 
| getOverrideValue | 
| Methods inherited from class nl.openedge.baritus.validation.AbstractValidator | 
| getFieldName, getLocalizedMessage, getLocalizedMessage, getLocalizedMessage, getLocalizedMessage, getValidationActivationRule, removeValidationActivationRule, setErrorMessage, setValidationRule | 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Methods inherited from interface nl.openedge.baritus.validation.ValidationRuleDependend | 
| getValidationActivationRule, removeValidationActivationRule, setValidationRule | 
| Field Detail | 
public static final int MODE_VALID_IF_MATCHES
public static final int MODE_INVALID_IF_MATCHES
| Constructor Detail | 
public RegexValidator()
public RegexValidator(java.util.regex.Pattern pattern)
pattern - 
public RegexValidator(java.lang.String errorMessageKey,
                      java.util.regex.Pattern pattern)
errorMessageKey - pattern - 
public RegexValidator(java.lang.String errorMessageKey,
                      ValidationActivationRule rule,
                      java.util.regex.Pattern pattern)
errorMessageKey - rule - pattern - 
public RegexValidator(java.util.regex.Pattern pattern,
                      int mode)
pattern - mode - 
public RegexValidator(java.lang.String errorMessageKey,
                      java.util.regex.Pattern pattern,
                      int mode)
errorMessageKey - pattern - mode - 
public RegexValidator(java.lang.String errorMessageKey,
                      ValidationActivationRule rule,
                      java.util.regex.Pattern pattern,
                      int mode)
errorMessageKey - rule - pattern - mode - | Method Detail | 
public boolean isValid(org.infohazard.maverick.flow.ControllerContext cctx,
                       FormBeanContext formBeanContext,
                       java.lang.String fieldName,
                       java.lang.Object value)
FieldValidator
cctx - maverick contextformBeanContext - context with bean for this currentRequestfieldName - field name of parametervalue - the value of this parameter
FieldValidator.isValid(org.infohazard.maverick.flow.ControllerContext, nl.openedge.baritus.FormBeanContext, java.lang.String, java.lang.Object)public int getMode()
public java.util.regex.Pattern getPattern()
public void setMode(int i)
i - modepublic void setPattern(java.util.regex.Pattern pattern)
pattern - regex patternpublic java.lang.String getErrorMessageKey()
public void setErrorMessageKey(java.lang.String string)
string - key of error message| 
 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||