javax.validation.metadata
Interface ElementDescriptor

All Known Subinterfaces:
BeanDescriptor, PropertyDescriptor

public interface ElementDescriptor

Describes a validated element (class, field or property).


Nested Class Summary
static interface ElementDescriptor.ConstraintFinder
          Declare restrictions on retrieved constraints.
 
Method Summary
 ElementDescriptor.ConstraintFinder findConstraints()
          Find constraints and potentially restricts them to certain criteria.
 java.util.Set<ConstraintDescriptor<?>> getConstraintDescriptors()
          Return all constraint descriptors for this element in the class hierarchy or an empty Set if none are present.
 java.lang.Class<?> getElementClass()
           
 boolean hasConstraints()
          Return true if at least one constraint declaration is present for this element in the class hierarchy, false otherwise.
 

Method Detail

hasConstraints

boolean hasConstraints()
Return true if at least one constraint declaration is present for this element in the class hierarchy, false otherwise.


getElementClass

java.lang.Class<?> getElementClass()
Returns:
Statically defined returned type.

getConstraintDescriptors

java.util.Set<ConstraintDescriptor<?>> getConstraintDescriptors()
Return all constraint descriptors for this element in the class hierarchy or an empty Set if none are present.

Returns:
Set of constraint descriptors for this element

findConstraints

ElementDescriptor.ConstraintFinder findConstraints()
Find constraints and potentially restricts them to certain criteria.

Returns:
ConstraintFinder object.