Top Description Inners Methods
org.hibernate.validator.constraints.time

public @Interface DurationMax

extends Annotation
Annotations
@Documented
@Constraint
validatedBy:
@Target:METHOD, FIELD, ANNOTATION_TYPE, CONSTRUCTOR, PARAMETER, TYPE_USE
@Retention:RUNTIME
@Repeatable:List
@ReportAsSingleViolation
@Incubating
Static Imports
java.lang.annotation.ElementType.ANNOTATION_TYPE, .ElementType.CONSTRUCTOR, .ElementType.FIELD, .ElementType.METHOD, .ElementType.PARAMETER, .ElementType.TYPE_USE, .RetentionPolicy.RUNTIME

The annotated Duration element must be shorter than or equal to the one constructed as a sum of DurationMax#nanos(), DurationMax#millis(), DurationMax#seconds(), DurationMax#minutes(), DurationMax#hours(), DurationMax#days().
Author
Marko Bekhta

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static @interface
DurationMax.List

Defines several @DurationMax annotations on the same element.

Method Summary

Modifier and TypeMethod and Description
public long
days()

public Class<?>[]
public long
public boolean

Returns:

true if the value must be smaller or equal to the specified maximum, false if the value must be smaller
inclusive
()

Specifies whether the specified maximum is inclusive or exclusive.

public String
public long
public long
public long
public Class<? extends Payload>[]
public long
Inherited from java.lang.annotation.Annotation:
annotationTypeequalshashCodetoString

Method Detail

daysback to summary
public long days()
groupsback to summary
public Class<?>[] groups()
hoursback to summary
public long hours()
inclusiveback to summary
public boolean inclusive()

Specifies whether the specified maximum is inclusive or exclusive. By default, it is inclusive.

Returns:boolean

true if the value must be smaller or equal to the specified maximum, false if the value must be smaller

messageback to summary
public String message()
millisback to summary
public long millis()
minutesback to summary
public long minutes()
nanosback to summary
public long nanos()
payloadback to summary
public Class<? extends Payload>[] payload()
secondsback to summary
public long seconds()
org.hibernate.validator.constraints.time back to summary

public @Interface DurationMax.List

extends Annotation
Annotations
@Target:METHOD, FIELD, ANNOTATION_TYPE, CONSTRUCTOR, PARAMETER, TYPE_USE
@Retention:RUNTIME
@Documented

Defines several @DurationMax annotations on the same element.

Method Summary

Modifier and TypeMethod and Description
public DurationMax[]
Inherited from java.lang.annotation.Annotation:
annotationTypeequalshashCodetoString

Method Detail

valueback to summary
public DurationMax[] value()