Package com.aquima.interactions.rule
Interface IValidator
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
BankAccountValidator
,DateValidator
,IbanValidator
,NumberValidator
,RegexpValidator
,RequiredValidator
,SofiNumberValidator
,StringValidator
,ValidatorBase
This interface defines the methods needed for a (custom) value validator.
- Since:
- 7.1
- Author:
- O. Kerpershoek
-
Method Summary
Modifier and TypeMethodDescriptionThis method returns the type of the validator.boolean
validate
(IValue attrValue, IParameters parameters) This method will be invoked for each value that should be validated by this validator.
-
Method Details
-
getTypeName
String getTypeName()This method returns the type of the validator. The type name is used to link the validator definition, the actual validator, and the validation definition together.- Returns:
- The type name of the validator.
-
validate
This method will be invoked for each value that should be validated by this validator.- Parameters:
attrValue
- The value that should be validated.parameters
- The (optional) parameters that can be used during validation.- Returns:
- Boolean indicating if the value is deemed valid by this validator.
-