| org.apache.cocoon.woody.datatype.ValidationRule
All known Subclasses: org.apache.cocoon.woody.datatype.validationruleimpl.AbstractValidationRule,
ValidationRule | public interface ValidationRule (Code) | | Interface for validation rules. Most
Datatype implementations will
perform their validation by checking a number of these validation rules
(though strictly spoken this is not required).
version: $Id: ValidationRule.java 433543 2006-08-22 06:22:54Z crossley $ |
Method Summary | |
boolean | supportsType(Class clazz, boolean arrayType) Returns true if this ValidationRule supports validating objects of the same class
as the one specified. | ValidationError | validate(Object value, ExpressionContext expressionContext) |
supportsType | boolean supportsType(Class clazz, boolean arrayType)(Code) | | Returns true if this ValidationRule supports validating objects of the same class
as the one specified. If the flag 'arrayType' is true, this method will return true
if this validation rule can validate arrays of these objects (i.e. the object passed
to the validate method will then be an array).
|
validate | ValidationError validate(Object value, ExpressionContext expressionContext)(Code) | | Parameters: value - a value of a class supported by the ValidationRule implementation Parameters: expressionContext - many validation rules use the xReporter expression interpreter,the expressionContext allows to resolve variables used in these expressions. |
|
|