public interface BeanMetaData<T> extends Validatable
Modifier and Type | Method and Description |
---|---|
boolean |
defaultGroupSequenceIsRedefined() |
Class<T> |
getBeanClass() |
BeanDescriptor |
getBeanDescriptor() |
List<Class<? super T>> |
getClassHierarchy() |
List<Class<?>> |
getDefaultGroupSequence(T beanState)
Get the composition of the default group sequence.
|
Iterator<Sequence> |
getDefaultValidationSequence(T beanState)
Returns an iterator over the default validation group sequence as configured through
@GroupSequence /@DefaultGroupSequenceProvider . |
Set<MetaConstraint<?>> |
getDirectMetaConstraints() |
Set<MetaConstraint<?>> |
getMetaConstraints() |
Optional<ExecutableMetaData> |
getMetaDataFor(Executable executable)
Returns the constraint-related metadata for the given executable of the
class represented by this bean metadata.
|
PropertyMetaData |
getMetaDataFor(String propertyName)
Returns constraint-related meta data for the given property of this bean.
|
boolean |
hasConstraints()
Returns
true if the bean class for this bean meta data has any constraints at all, false otherwise. |
getCascadables, hasCascadables
boolean hasConstraints()
true
if the bean class for this bean meta data has any constraints at all, false
otherwise.true
if the bean class for this bean meta data has any constraints at all, false
otherwise.BeanDescriptor getBeanDescriptor()
ElementDescriptor
describing the bean this meta data applies for.PropertyMetaData getMetaDataFor(String propertyName)
propertyName
- The property name.IllegalArgumentException
- In case no property with the given name exists.List<Class<?>> getDefaultGroupSequence(T beanState)
If the bean state is given in parameter and the bean metadata has a default group sequence provider then the dynamic default group sequence composition is returned. In the other cases the default group sequence redefinition specified by BV is used.
beanState
- the bean state.Iterator<Sequence> getDefaultValidationSequence(T beanState)
@GroupSequence
/@DefaultGroupSequenceProvider
.
If this bean type does not re-declare the default validation group sequence,
ValidationOrder.DEFAULT_SEQUENCE
will be returned.boolean defaultGroupSequenceIsRedefined()
true
if the entity redefines the default group sequence, false
otherwise.Set<MetaConstraint<?>> getMetaConstraints()
MetaConstraint
instances encapsulating the information of all the constraints
defined on the bean. This collection includes constraints from super classes as wellSet<MetaConstraint<?>> getDirectMetaConstraints()
MetaConstraint
instances encapsulating the information of all the constraints
defined on the bean directly (including constraints defined on implemented interfaces). It does not
contain constraints from super classes or interfaces implemented by super classesOptional<ExecutableMetaData> getMetaDataFor(Executable executable) throws IllegalArgumentException
executable
- The executable of interest.IllegalArgumentException
- In case the method cannot be found in the bean.Copyright © 2021 JBoss by Red Hat. All rights reserved.