org.hibernate.validator.metadata
Class ConstraintDescriptorImpl<T extends Annotation>

java.lang.Object
  extended by org.hibernate.validator.metadata.ConstraintDescriptorImpl<T>
All Implemented Interfaces:
Serializable, javax.validation.metadata.ConstraintDescriptor<T>

public class ConstraintDescriptorImpl<T extends Annotation>
extends Object
implements javax.validation.metadata.ConstraintDescriptor<T>, Serializable

Describe a single constraint (including it's composing constraints).

Author:
Emmanuel Bernard, Hardy Ferentschik
See Also:
Serialized Form

Constructor Summary
ConstraintDescriptorImpl(T annotation, ConstraintHelper constraintHelper, Class<?> implicitGroup, ElementType type, ConstraintOrigin definedOn)
           
ConstraintDescriptorImpl(T annotation, ConstraintHelper constraintHelper, ElementType type, ConstraintOrigin definedOn)
           
 
Method Summary
 T getAnnotation()
           
 Map<String,Object> getAttributes()
           
 Set<javax.validation.metadata.ConstraintDescriptor<?>> getComposingConstraints()
           
 List<Class<? extends javax.validation.ConstraintValidator<T,?>>> getConstraintValidatorClasses()
           
 ConstraintOrigin getDefinedOn()
           
 ElementType getElementType()
           
 Set<Class<?>> getGroups()
           
 Set<Class<? extends javax.validation.Payload>> getPayload()
           
 boolean isReportAsSingleViolation()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ConstraintDescriptorImpl

public ConstraintDescriptorImpl(T annotation,
                                ConstraintHelper constraintHelper,
                                Class<?> implicitGroup,
                                ElementType type,
                                ConstraintOrigin definedOn)

ConstraintDescriptorImpl

public ConstraintDescriptorImpl(T annotation,
                                ConstraintHelper constraintHelper,
                                ElementType type,
                                ConstraintOrigin definedOn)
Method Detail

getAnnotation

public T getAnnotation()
Specified by:
getAnnotation in interface javax.validation.metadata.ConstraintDescriptor<T extends Annotation>

getGroups

public Set<Class<?>> getGroups()
Specified by:
getGroups in interface javax.validation.metadata.ConstraintDescriptor<T extends Annotation>

getPayload

public Set<Class<? extends javax.validation.Payload>> getPayload()
Specified by:
getPayload in interface javax.validation.metadata.ConstraintDescriptor<T extends Annotation>

getConstraintValidatorClasses

public List<Class<? extends javax.validation.ConstraintValidator<T,?>>> getConstraintValidatorClasses()
Specified by:
getConstraintValidatorClasses in interface javax.validation.metadata.ConstraintDescriptor<T extends Annotation>

getAttributes

public Map<String,Object> getAttributes()
Specified by:
getAttributes in interface javax.validation.metadata.ConstraintDescriptor<T extends Annotation>

getComposingConstraints

public Set<javax.validation.metadata.ConstraintDescriptor<?>> getComposingConstraints()
Specified by:
getComposingConstraints in interface javax.validation.metadata.ConstraintDescriptor<T extends Annotation>

isReportAsSingleViolation

public boolean isReportAsSingleViolation()
Specified by:
isReportAsSingleViolation in interface javax.validation.metadata.ConstraintDescriptor<T extends Annotation>

getElementType

public ElementType getElementType()

getDefinedOn

public ConstraintOrigin getDefinedOn()

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2011 Oracle Corporation. All Rights Reserved.