'javax.validation.constraints' package provides number of annotations to do validations on data.
Below table summarizes the annotations provided by JSR-380 specification.
Annotation |
Description |
The annotated element must be false. |
|
Defines several |
|
The annotated element must be true. |
|
Defines several |
|
The annotated element must be a number whose value must be lower or equal to the specified maximum. |
|
Defines several |
|
The annotated element must be a number whose value must be higher or equal to the specified minimum. |
|
Defines several |
|
The annotated element must be a
number within accepted range Supported types are: |
|
Defines several |
|
The string has to be a well-formed email address. |
|
Defines several |
|
The annotated element must be an instant, date or time in the future. |
|
Defines several |
|
The annotated element must be an instant, date or time in the present or in the future. |
|
Defines several |
|
The annotated element must be a number whose value must be lower or equal to the specified maximum. |
|
Defines several |
|
The annotated element must be a number whose value must be higher or equal to the specified minimum. |
|
Defines several |
|
The annotated element must be a strictly negative number (i.e. |
|
Defines several |
|
The annotated element must be a negative number or 0. |
|
Defines several |
|
The annotated element must not
be |
|
Defines several |
|
The annotated element must not
be |
|
Defines several |
|
The annotated element must not
be |
|
Defines several |
|
The annotated element must be |
|
Defines several |
|
The annotated element must be an instant, date or time in the past. |
|
Defines several |
|
The annotated element must be an instant, date or time in the past or in the present. |
|
Defines several |
|
The annotated |
|
Defines several |
|
The annotated element must be a strictly positive number (i.e. |
|
Defines several |
|
The annotated element must be a positive number or 0. |
|
Defines several |
|
The annotated element size must be between the specified boundaries (included). |
|
Defines several |
Previous Next Home
No comments:
Post a Comment