org.outerj.xreporter.datatype.type
Interface ValidationRule

All Known Implementing Classes:
BigDecimalMaxExclusiveValidationRule, BigDecimalMaxInclusiveValidationRule, BigDecimalMinExclusiveValidationRule, BigDecimalMinInclusiveValidationRule, ExpressionValidationRule, LongMaxExclusiveValidationRule, LongMaxInclusiveValidationRule, LongMinExclusiveValidationRule, LongMinInclusiveValidationRule, StringLengthValidationRule, StringMaxLengthValidationRule, StringMinLengthValidationRule, StringRegexpValidationRule

public interface ValidationRule

Interface for objects that can validate a value.


Method Summary
 java.lang.String validate(java.lang.Object value, ExecutionContext executionContext)
          Validates the given value.
 

Method Detail

validate

public java.lang.String validate(java.lang.Object value,
                                 ExecutionContext executionContext)
Validates the given value. The value will already be parsed, so if it is e.g. a BigDecimal then the value will be an instance of BigDecimal. If validation is successful, this method should return null, otherwise it should return a (localized) error message.