|
Humboldt Alignment Editor 2.5.0 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecteu.esdihumboldt.hale.common.schema.model.constraint.type.Enumeration<T>
T
- the value type@Immutable public class Enumeration<T>
Constraint that holds allowed values for a type
Constructor Summary | |
---|---|
Enumeration()
Creates a default constraint where no restriction on the allowed values is present. |
|
Enumeration(Collection<? extends T> values,
boolean allowOthers)
Create a constraint that holds allowed values for a type |
Method Summary | |
---|---|
Collection<? extends T> |
getValues()
|
boolean |
isAllowOthers()
|
boolean |
isInheritable()
Determines if the constraint is inheritable, meaning it may be used for a sub-type. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Enumeration()
public Enumeration(Collection<? extends T> values, boolean allowOthers)
values
- the collection of allowed values, ownership of the
collection is transferred to the constraintallowOthers
- if other values are allowedMethod Detail |
---|
public Collection<? extends T> getValues()
null
there is no
such restrictionpublic boolean isAllowOthers()
getValues()
are
allowed for the type, should be ignored if getValues()
returns null
public boolean isInheritable()
TypeConstraint
isInheritable
in interface TypeConstraint
TypeConstraint.isInheritable()
|
Humboldt Alignment Editor 2.5.0 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |