public abstract class AbstractConstrainedElement extends Object implements ConstrainedElement
ConstrainedElement
implementations.ConstrainedElement.ConstrainedElementKind
Modifier and Type | Field and Description |
---|---|
protected Set<MetaConstraint<?>> |
constraints |
protected Map<Class<?>,Class<?>> |
groupConversions |
protected boolean |
isCascading |
protected ConstraintLocation |
location |
protected ConfigurationSource |
source |
protected UnwrapMode |
unwrapMode |
Constructor and Description |
---|
AbstractConstrainedElement(ConfigurationSource source,
ConstrainedElement.ConstrainedElementKind kind,
ConstraintLocation location,
Set<MetaConstraint<?>> constraints,
Map<Class<?>,Class<?>> groupConversions,
boolean isCascading,
UnwrapMode unwrapMode) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
Set<MetaConstraint<?>> |
getConstraints()
Returns a set containing the constraints specified for this constrained
element.
|
Map<Class<?>,Class<?>> |
getGroupConversions()
Returns a map with the group conversions for this constrained element, as
e.g.
|
ConstrainedElement.ConstrainedElementKind |
getKind()
Returns the kind of this constrained element.
|
ConstraintLocation |
getLocation()
Returns the location of this constrained element.
|
int |
hashCode() |
boolean |
isCascading()
Whether cascading validation for the represented element shall be
performed or not.
|
boolean |
isConstrained()
Whether this element is constrained or not.
|
Iterator<MetaConstraint<?>> |
iterator() |
String |
toString() |
UnwrapMode |
unwrapMode()
Determines how to handle unwrapping of validated values.
|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
forEach, spliterator
protected final ConfigurationSource source
protected final ConstraintLocation location
protected final Set<MetaConstraint<?>> constraints
protected final boolean isCascading
protected final UnwrapMode unwrapMode
public AbstractConstrainedElement(ConfigurationSource source, ConstrainedElement.ConstrainedElementKind kind, ConstraintLocation location, Set<MetaConstraint<?>> constraints, Map<Class<?>,Class<?>> groupConversions, boolean isCascading, UnwrapMode unwrapMode)
public ConstrainedElement.ConstrainedElementKind getKind()
ConstrainedElement
getKind
in interface ConstrainedElement
public ConstraintLocation getLocation()
ConstrainedElement
getLocation
in interface ConstrainedElement
public Iterator<MetaConstraint<?>> iterator()
iterator
in interface Iterable<MetaConstraint<?>>
public Set<MetaConstraint<?>> getConstraints()
ConstrainedElement
getConstraints
in interface ConstrainedElement
null
.public Map<Class<?>,Class<?>> getGroupConversions()
ConstrainedElement
@ConvertGroup
annotation.getGroupConversions
in interface ConstrainedElement
null
.public boolean isCascading()
ConstrainedElement
isCascading
in interface ConstrainedElement
True
, if cascading validation for the represented
element shall be performed, false
otherwise.public boolean isConstrained()
ConstrainedElement
isConstrained
in interface ConstrainedElement
True
, if this element is constrained,
false
otherwise.public UnwrapMode unwrapMode()
ConstrainedElement
ValidatedValueUnwrapper
s. It can also be explcitly configured
using UnwrapValidatedValue
.unwrapMode
in interface ConstrainedElement
UnwrapValidatedValue
,
ValidatedValueUnwrapper
Copyright © 2017 JBoss by Red Hat. All rights reserved.