|
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.DefinitionUtil
public abstract class DefinitionUtil
Definition utility methods
Constructor Summary | |
---|---|
DefinitionUtil()
|
Method Summary | |
---|---|
static Collection<? extends ChildDefinition<?>> |
getAllChildren(DefinitionGroup group)
Get all children of a definition group. |
static Collection<? extends PropertyDefinition> |
getAllProperties(DefinitionGroup group)
Get all properties of a definition group. |
static Cardinality |
getCardinality(ChildDefinition<?> child)
Get the cardinality of a child definition. |
static ChildDefinition<?> |
getChild(ChildDefinition<?> definition,
QName name)
Returns the child definition of definition with the given name. |
static ChildDefinition<?> |
getChild(ChildDefinition<?> definition,
QName name,
boolean allowIgnoreNamespace)
Returns the child definition of definition with the given name. |
static ChildDefinition<?> |
getChild(Definition<?> definition,
QName name)
Returns the child definition of definition with the given name. |
static ChildDefinition<?> |
redeclareChild(ChildDefinition<?> child,
DefinitionGroup newParent)
Create a proxy for the given child with another declaring group |
static ChildDefinition<?> |
reparentChild(ChildDefinition<?> child,
TypeDefinition newParent)
Create a proxy for the given child with another parent |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DefinitionUtil()
Method Detail |
---|
public static ChildDefinition<?> reparentChild(ChildDefinition<?> child, TypeDefinition newParent)
child
- the childnewParent
- the new parent type
public static ChildDefinition<?> redeclareChild(ChildDefinition<?> child, DefinitionGroup newParent)
child
- the childnewParent
- the new declaring group
public static Collection<? extends ChildDefinition<?>> getAllChildren(DefinitionGroup group)
TypeDefinition
also
the inherited children will be returned.
group
- the definition group
public static Collection<? extends PropertyDefinition> getAllProperties(DefinitionGroup group)
TypeDefinition
also
the inherited children will be returned. If there are children that are
groups, their properties are also added.
group
- the definition group
public static Cardinality getCardinality(ChildDefinition<?> child)
child
- the child definition
public static ChildDefinition<?> getChild(Definition<?> definition, QName name)
definition
- the definitionname
- the name of the child
null
if it doesn't exist
IllegalStateException
- if the given definition isn't group nor
property definitionpublic static ChildDefinition<?> getChild(ChildDefinition<?> definition, QName name)
definition
- the definitionname
- the name of the child
null
if it doesn't exist
IllegalStateException
- if the given definition isn't group nor
property definitionpublic static ChildDefinition<?> getChild(ChildDefinition<?> definition, QName name, boolean allowIgnoreNamespace)
definition
- the definitionname
- the name of the childallowIgnoreNamespace
- specifies if when the child with the exact
name is not present, a child with a similar local name should
be returned
null
IllegalStateException
- if the given definition isn't group nor
property definition
|
Humboldt Alignment Editor 2.5.0 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |