public class BeanDescriptorImpl<T> extends ElementDescriptorImpl implements BeanDescriptor, TypeDescriptor
ElementDescriptor.ConstraintFinder
Constructor and Description |
---|
BeanDescriptorImpl(Class<T> beanClass,
Set<ConstraintDescriptorImpl<?>> classLevelConstraints,
Map<String,PropertyDescriptor> properties,
Map<String,MethodDescriptor> methods,
boolean defaultGroupSequenceRedefined,
List<Class<?>> defaultGroupSequence) |
Modifier and Type | Method and Description |
---|---|
BeanDescriptor |
getBeanDescriptor()
Returns a descriptor for the bean related constraints of this type.
|
Set<MethodDescriptor> |
getConstrainedMethods()
Returns a set with the constrained methods of this type.
|
Set<PropertyDescriptor> |
getConstrainedProperties() |
MethodDescriptor |
getConstraintsForMethod(String methodName,
Class<?>... parameterTypes)
Returns a descriptor for the specified method.
|
PropertyDescriptor |
getConstraintsForProperty(String propertyName) |
boolean |
isBeanConstrained() |
boolean |
isTypeConstrained()
Whether this type has any class-, property- (field or getter style) or
method-level constraints or not.
|
asDescriptors, findConstraints, getConstraintDescriptors, getElementClass, hasConstraints, isCascaded
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
findConstraints, getConstraintDescriptors, getElementClass, hasConstraints
public BeanDescriptorImpl(Class<T> beanClass, Set<ConstraintDescriptorImpl<?>> classLevelConstraints, Map<String,PropertyDescriptor> properties, Map<String,MethodDescriptor> methods, boolean defaultGroupSequenceRedefined, List<Class<?>> defaultGroupSequence)
public final boolean isBeanConstrained()
isBeanConstrained
in interface BeanDescriptor
public final PropertyDescriptor getConstraintsForProperty(String propertyName)
getConstraintsForProperty
in interface BeanDescriptor
public final Set<PropertyDescriptor> getConstrainedProperties()
getConstrainedProperties
in interface BeanDescriptor
public boolean isTypeConstrained()
TypeDescriptor
Valid
annotation,Valid
annotation,Valid
annotationisTypeConstrained
in interface TypeDescriptor
True
, if this type has any constraints,
false
public Set<MethodDescriptor> getConstrainedMethods()
TypeDescriptor
getConstrainedMethods
in interface TypeDescriptor
public MethodDescriptor getConstraintsForMethod(String methodName, Class<?>... parameterTypes)
TypeDescriptor
getConstraintsForMethod
in interface TypeDescriptor
methodName
- The name of the method to retrieve a descriptor for.parameterTypes
- The types of the parameters of the method to retrieve a
descriptor for, in the order as they are defined in the method
signature.null, if no method
with the given name and parameter types is declared on the type represented
by this descriptor or its super types.
public BeanDescriptor getBeanDescriptor()
TypeDescriptor
getBeanDescriptor
in interface TypeDescriptor
Copyright © 2007-2014 Red Hat Middleware, LLC. All Rights Reserved