org.apache.beehive.netui.pageflow.validation
Class ValidatorRules

Object
  extended by FieldChecks
      extended by ValidatorRules
All Implemented Interfaces:
Serializable

public class ValidatorRules
extends FieldChecks

See Also:
Serialized Form

Field Summary
 
Fields inherited from class FieldChecks
FIELD_TEST_EQUAL, FIELD_TEST_NOTNULL, FIELD_TEST_NULL
 
Constructor Summary
ValidatorRules()
           
 
Method Summary
static boolean validateLongRange(Object bean, ValidatorAction va, Field field, ActionMessages errors, HttpServletRequest request)
          Checks if a fields value is within a range (min & max specified in the vars attribute).
static boolean validateValidWhen(Object bean, ValidatorAction va, Field field, ActionMessages errors, HttpServletRequest request, ServletContext servletContext)
           
 
Methods inherited from class FieldChecks
isString, validateByte, validateCreditCard, validateDate, validateDouble, validateDoubleRange, validateEmail, validateFloat, validateFloatRange, validateInteger, validateIntRange, validateLong, validateMask, validateMaxLength, validateMinLength, validateRequired, validateRequiredIf, validateShort, validateUrl
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ValidatorRules

public ValidatorRules()
Method Detail

validateValidWhen

public static boolean validateValidWhen(Object bean,
                                        ValidatorAction va,
                                        Field field,
                                        ActionMessages errors,
                                        HttpServletRequest request,
                                        ServletContext servletContext)

validateLongRange

public static boolean validateLongRange(Object bean,
                                        ValidatorAction va,
                                        Field field,
                                        ActionMessages errors,
                                        HttpServletRequest request)
Checks if a fields value is within a range (min & max specified in the vars attribute).

Parameters:
bean - The bean validation is being performed on.
va - The ValidatorAction that is currently being performed.
field - The Field object associated with the current field being validated.
errors - The ActionMessages object to add errors to if any validation errors occur.
request - Current request object.
Returns:
True if in range, false otherwise.