public class ChildElementCollectionImpl<T extends ModelElementInstance> extends Object implements ChildElementCollection<T>
This collection is a view on an the children of a Model Element.
| Modifier and Type | Field and Description |
|---|---|
protected Class<T> |
childElementTypeClass |
protected int |
maxOccurs
the maximum count of child elements in the collection.
|
| Constructor and Description |
|---|
ChildElementCollectionImpl(Class<T> childElementTypeClass,
ModelElementTypeImpl parentElementType) |
| Modifier and Type | Method and Description |
|---|---|
Collection<T> |
get(ModelElementInstance element)
returns a
Collection containing all or a subset of the child elements of
a ModelElementInstance. |
ModelElementType |
getChildElementType(Model model)
Get the model element type of the elements contained in this collection.
|
Class<T> |
getChildElementTypeClass()
Get the class of the elements contained in this collection.
|
int |
getMaxOccurs()
Indicates the max element count of a collection.
|
int |
getMinOccurs()
Indicates the minimal element count of a collection.
|
ModelElementType |
getParentElementType()
Get the model element type of the element owns the collection
|
boolean |
isImmutable()
Indicates whether the collection is immutable.
|
void |
setImmutable() |
void |
setMaxOccurs(int maxOccurs) |
void |
setMinOccurs(int minOccurs) |
void |
setMutable(boolean isMutable) |
protected final Class<T extends ModelElementInstance> childElementTypeClass
protected int maxOccurs
public ChildElementCollectionImpl(Class<T> childElementTypeClass, ModelElementTypeImpl parentElementType)
public void setImmutable()
public void setMutable(boolean isMutable)
public boolean isImmutable()
ChildElementCollectionCollection.add(Object) or Collection.remove(Object)
will throw an UnsupportedOperationException.isImmutable in interface ChildElementCollection<T extends ModelElementInstance>public int getMinOccurs()
ChildElementCollectiongetMinOccurs in interface ChildElementCollection<T extends ModelElementInstance>public void setMinOccurs(int minOccurs)
public int getMaxOccurs()
ChildElementCollectiongetMaxOccurs in interface ChildElementCollection<T extends ModelElementInstance>public ModelElementType getChildElementType(Model model)
ChildElementCollectiongetChildElementType in interface ChildElementCollection<T extends ModelElementInstance>model - the model of the elementModelElementTypepublic Class<T> getChildElementTypeClass()
ChildElementCollectiongetChildElementTypeClass in interface ChildElementCollection<T extends ModelElementInstance>public ModelElementType getParentElementType()
ChildElementCollectiongetParentElementType in interface ChildElementCollection<T extends ModelElementInstance>public void setMaxOccurs(int maxOccurs)
public Collection<T> get(ModelElementInstance element)
ChildElementCollectionCollection containing all or a subset of the child elements of
a ModelElementInstance.get in interface ChildElementCollection<T extends ModelElementInstance>Copyright © 2014–2020 camunda services GmbH. All rights reserved.