Package play.data.validation
Class Constraints.ValidatorWithPayload<T>
- Object
-
- play.data.validation.Constraints.ValidatorWithPayload<T>
-
- Direct Known Subclasses:
Constraints.ValidatePayloadWithValidator
- Enclosing class:
- Constraints
public abstract static class Constraints.ValidatorWithPayload<T> extends Object
Super-type for validators with a payload.
-
-
Constructor Summary
Constructors Constructor Description ValidatorWithPayload()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract F.Tuple<String,Object[]>
getErrorMessageKey()
boolean
isValid(T object, javax.validation.ConstraintValidatorContext constraintContext)
abstract boolean
isValid(T object, Constraints.ValidationPayload payload)
-
-
-
Method Detail
-
isValid
public abstract boolean isValid(T object, Constraints.ValidationPayload payload)
- Parameters:
object
- the value to test.payload
- the payload providing validation context information.- Returns:
true
if this value is valid.
-
isValid
public boolean isValid(T object, javax.validation.ConstraintValidatorContext constraintContext)
- Parameters:
object
- the object to checkconstraintContext
- The JSR-303 validation context.- Returns:
true
if this value is valid for the given constraint.
-
-