public class ReturnValueMetaData extends AbstractConstraintMetaData implements Validatable, Cascadable
Constructor and Description |
---|
ReturnValueMetaData(Type type,
Set<MetaConstraint<?>> constraints,
Set<MetaConstraint<?>> typeArgumentsConstraints,
boolean isCascading,
Map<Class<?>,Class<?>> groupConversions,
UnwrapMode unwrapMode) |
Modifier and Type | Method and Description |
---|---|
ReturnValueDescriptor |
asDescriptor(boolean defaultGroupSequenceRedefined,
List<Class<?>> defaultGroupSequence)
Returns this meta data object's corresponding representation in the
descriptor model.
|
Class<?> |
convertGroup(Class<?> originalGroup)
Converts the given validation group as per the group conversion
configuration for this element (as e.g.
|
Iterable<Cascadable> |
getCascadables()
Returns the cascaded elements of this validatable, e.g.
|
Type |
getCascadableType()
Returns the data type of this cascadable, e.g.
|
ElementType |
getElementType()
Returns the element type of the cascadable.
|
Set<GroupConversionDescriptor> |
getGroupConversionDescriptors()
Returns a set with
GroupConversionDescriptor s representing the
group conversions of this cascadable. |
Set<MetaConstraint<?>> |
getTypeArgumentsConstraints()
Returns the type arguments constraints for this cascadable.
|
Object |
getValue(Object parent)
Returns the value of this cacadable from the given parent.
|
asDescriptors, equals, getConstraints, getKind, getName, getType, hashCode, isCascading, isConstrained, iterator, toString, unwrapMode
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getKind, getName, unwrapMode
forEach, spliterator
public ReturnValueMetaData(Type type, Set<MetaConstraint<?>> constraints, Set<MetaConstraint<?>> typeArgumentsConstraints, boolean isCascading, Map<Class<?>,Class<?>> groupConversions, UnwrapMode unwrapMode)
public Iterable<Cascadable> getCascadables()
Validatable
@Valid
.getCascadables
in interface Validatable
public Class<?> convertGroup(Class<?> originalGroup)
Cascadable
@ConvertGroup
.convertGroup
in interface Cascadable
originalGroup
- The group to convert.public Set<GroupConversionDescriptor> getGroupConversionDescriptors()
Cascadable
GroupConversionDescriptor
s representing the
group conversions of this cascadable.getGroupConversionDescriptors
in interface Cascadable
null
.public ElementType getElementType()
Cascadable
getElementType
in interface Cascadable
public Set<MetaConstraint<?>> getTypeArgumentsConstraints()
Cascadable
getTypeArgumentsConstraints
in interface Cascadable
public ReturnValueDescriptor asDescriptor(boolean defaultGroupSequenceRedefined, List<Class<?>> defaultGroupSequence)
ConstraintMetaData
asDescriptor
in interface ConstraintMetaData
defaultGroupSequenceRedefined
- Whether the bean hosting the represented element has a
redefined default group sequence or not.defaultGroupSequence
- The default group sequence of the bean hosting the represented
element.ElementDescriptor
.public Object getValue(Object parent)
Cascadable
getValue
in interface Cascadable
public Type getCascadableType()
Cascadable
getCascadableType
in interface Cascadable
Copyright © 2017 JBoss by Red Hat. All rights reserved.