public class ConstraintDescriptorImpl<T extends Annotation> extends Object implements ConstraintDescriptor<T>, Serializable
Constructor and Description |
---|
ConstraintDescriptorImpl(T annotation,
ConstraintHelper constraintHelper,
Class<?> implicitGroup,
ElementType type,
ConstraintOrigin definedOn) |
ConstraintDescriptorImpl(T annotation,
ConstraintHelper constraintHelper,
ElementType type,
ConstraintOrigin definedOn) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
T |
getAnnotation()
Returns the annotation describing the constraint declaration.
|
Map<String,Object> |
getAttributes()
Returns a map containing the annotation attribute names as keys and the
annotation attribute values as value.
|
Set<ConstraintDescriptor<?>> |
getComposingConstraints()
Return a set of composing
ConstraintDescriptor s where each
descriptor describes a composing constraint. |
CompositionType |
getCompositionType() |
List<Class<? extends ConstraintValidator<T,?>>> |
getConstraintValidatorClasses()
List of the constraint validation implementation classes.
|
ConstraintOrigin |
getDefinedOn() |
ElementType |
getElementType() |
Set<Class<?>> |
getGroups()
The set of groups the constraint is applied on.
|
Set<Class<? extends Payload>> |
getPayload()
The set of payload the constraint hosts.
|
int |
hashCode() |
boolean |
isReportAsSingleViolation() |
void |
setCompositionType(CompositionType compositionType) |
String |
toString() |
public ConstraintDescriptorImpl(T annotation, ConstraintHelper constraintHelper, Class<?> implicitGroup, ElementType type, ConstraintOrigin definedOn)
public ConstraintDescriptorImpl(T annotation, ConstraintHelper constraintHelper, ElementType type, ConstraintOrigin definedOn)
public T getAnnotation()
ConstraintDescriptor
getAnnotation
in interface ConstraintDescriptor<T extends Annotation>
public Set<Class<?>> getGroups()
ConstraintDescriptor
Default
group is returned.getGroups
in interface ConstraintDescriptor<T extends Annotation>
public Set<Class<? extends Payload>> getPayload()
ConstraintDescriptor
getPayload
in interface ConstraintDescriptor<T extends Annotation>
public List<Class<? extends ConstraintValidator<T,?>>> getConstraintValidatorClasses()
ConstraintDescriptor
getConstraintValidatorClasses
in interface ConstraintDescriptor<T extends Annotation>
public Map<String,Object> getAttributes()
ConstraintDescriptor
getAttributes
in interface ConstraintDescriptor<T extends Annotation>
public Set<ConstraintDescriptor<?>> getComposingConstraints()
ConstraintDescriptor
ConstraintDescriptor
s where each
descriptor describes a composing constraint. ConstraintDescriptor
instances of composing constraints reflect overridden attribute values in
ConstraintDescriptor.getAttributes()
and ConstraintDescriptor.getAnnotation()
.getComposingConstraints
in interface ConstraintDescriptor<T extends Annotation>
ConstraintDescriptor objects or an empty set
in case there are no composing constraints.
public boolean isReportAsSingleViolation()
isReportAsSingleViolation
in interface ConstraintDescriptor<T extends Annotation>
@ReportAsSingleViolation
public ElementType getElementType()
public ConstraintOrigin getDefinedOn()
public void setCompositionType(CompositionType compositionType)
compositionType
- the compositionType to setpublic CompositionType getCompositionType()
Copyright © 2018 JBoss by Red Hat. All rights reserved.