Top Description Methods
org.hibernate.validator.cfg.context

public Interface ConstraintDefinitionTarget

Known Direct Subinterfaces
org.hibernate.validator.cfg.context.ConstraintMappingTarget
Imports
java.lang.annotation.Annotation

Facet of a constraint definition creational context which allows to select the constraint (annotation type) to which the next operations shall apply.
Author
Yoann Rodiere

Method Summary

Modifier and TypeMethod and Description
public <
The annotation type to select.
A extends Annotation
>
ConstraintDefinitionContext<A>

Returns:

A creational context representing the selected constraint.
constraintDefinition
(Class<A>
The annotation type to select. This type must be an @interface annotated with jakarta.validation.Constraint.
annotationType
)

Selects the constraint (i.e. annotation type) to which the next operations shall apply.

Method Detail

constraintDefinitionback to summary
public <A extends Annotation> ConstraintDefinitionContext<A> constraintDefinition(Class<A> annotationType)

Selects the constraint (i.e. annotation type) to which the next operations shall apply. A given constraint may only be configured once.

Parameters
<A>
The annotation type to select.
annotationType:Class<A>

The annotation type to select. This type must be an @interface annotated with jakarta.validation.Constraint.

Returns:ConstraintDefinitionContext<A>

A creational context representing the selected constraint.