public interface ConstraintValidatorRegistry
| Modifier and Type | Method and Description |
|---|---|
<A extends java.lang.annotation.Annotation,T> |
findConstraintValidator(java.lang.Class<A> constraintType,
java.lang.Class<T> targetType)
Finds a constraint validator for the given type and target type.
|
default <A extends java.lang.annotation.Annotation,T> |
getConstraintValidator(java.lang.Class<A> constraintType,
java.lang.Class<T> targetType)
Finds a constraint validator for the given type and target type.
|
@NonNull <A extends java.lang.annotation.Annotation,T> java.util.Optional<ConstraintValidator<A,T>> findConstraintValidator(@NonNull java.lang.Class<A> constraintType, @NonNull java.lang.Class<T> targetType)
A - The annotation typeT - The target typeconstraintType - The annotation type of the constraint.targetType - The type being validated.@NonNull default <A extends java.lang.annotation.Annotation,T> ConstraintValidator<A,T> getConstraintValidator(@NonNull java.lang.Class<A> constraintType, @NonNull java.lang.Class<T> targetType)
A - The annotation typeT - The target typeconstraintType - The annotation type of the constraint.targetType - The type being validated.javax.validation.ValidationException - if no validator is present