ConstraintValidator

Undocumented in source.

Members

Functions

initialize
void initialize(A constraintAnnotation)

Initializes the validator in preparation for {@link #isValid(Object, ConstraintValidatorContext)} calls. The constraint annotation for a given constraint declaration is passed. <p> This method is guaranteed to be called before any use of this instance for validation. <p> The default implementation is a no-op.

isValid
bool isValid(T value, ConstraintValidatorContext context)

Implements the validation logic. The state of {@code value} must not be altered. <p> This method can be accessed concurrently, thread-safety must be ensured by the implementation.

Meta