org.barracudamvc.core.forms.validators
Class DateValidator
java.lang.Object
org.barracudamvc.core.forms.AbstractFormValidator
org.barracudamvc.core.forms.DefaultFormValidator
org.barracudamvc.core.forms.validators.DateValidator
- All Implemented Interfaces:
- FormValidator
public class DateValidator
- extends DefaultFormValidator
This validator ensures that a value is a valid date
- Since:
- 1.0
- Version:
- %I%, %G%
- Author:
- Robert Leftwich , Christian Cryder [christianc@granitepeaks.com], Jacob Kjome , Diez B. Roggisch
Method Summary |
void |
validateFormElement(Object val,
FormElement element,
boolean deferExceptions)
Validate a FormElement to make sure the value is a valid date
Validation is not supported for
FormType.BOOLEAN
FormType,INTEGER
FormType.LONG
FormType.SHORT
FormType.DOUBLE
FormType.FLOAT |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DateValidator
public DateValidator()
- Public constructor.
DateValidator
public DateValidator(String ierrmsg)
- Public constructor.
- Parameters:
ierrmsg
- the message associated with this error
validateFormElement
public void validateFormElement(Object val,
FormElement element,
boolean deferExceptions)
throws ValidationException
- Validate a FormElement to make sure the value is a valid date
Validation is not supported for
FormType.BOOLEAN
FormType,INTEGER
FormType.LONG
FormType.SHORT
FormType.DOUBLE
FormType.FLOAT
- Overrides:
validateFormElement
in class DefaultFormValidator
- Parameters:
val
- the value to compare the element value toelement
- the form element that contains the val
to validate elements by comparing them with other elements)deferExceptions
- do we want to deferValidation exceptions
and attempt to validate all elements so that we can process
all the exceptions at once
- Throws:
ValidationException
- if the element is not valid
Copyright © 2006 BarracudaMVC.org All Rights Reserved.