Package com.nomagic.magicdraw.uml2.util
Class ModifiableDerivedUnionEObjectEList<E>
java.lang.Object
java.util.AbstractCollection<E>
java.util.AbstractList<E>
java.util.AbstractSequentialList<E>
org.eclipse.emf.ecore.util.AbstractSequentialInternalEList<E>
org.eclipse.uml2.common.util.DerivedEObjectEList<E>
org.eclipse.uml2.common.util.DerivedUnionEObjectEList<E>
com.nomagic.magicdraw.uml2.util.ModifiableDerivedUnionEObjectEList<E>
- All Implemented Interfaces:
Iterable<E>,Collection<E>,List<E>,org.eclipse.emf.common.util.EList<E>,org.eclipse.emf.ecore.EStructuralFeature.Setting,org.eclipse.emf.ecore.util.InternalEList<E>,org.eclipse.emf.ecore.util.InternalEList.Unsettable<E>
public class ModifiableDerivedUnionEObjectEList<E>
extends org.eclipse.uml2.common.util.DerivedUnionEObjectEList<E>
A derived list representing a union of all the elements from its source
features. This list is ideal for implementing derived union features.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionclassNon resolvingDerivedUnionEObjectEStoreEListiterator.classResolvingDerivedUnionEObjectEStoreEListiterator.classEmptyDerivedUnionEObjectEStoreEListiterator. -
Field Summary
Fields inherited from class org.eclipse.uml2.common.util.DerivedEObjectEList
dataClass, featureID, owner, sourceFeatureIDsFields inherited from class java.util.AbstractList
modCount -
Constructor Summary
ConstructorsConstructorDescriptionModifiableDerivedUnionEObjectEList(Class<?> dataClass, org.eclipse.emf.ecore.InternalEObject owner, int featureID, int[] sourceFeatureIDs) Creates and initializes a newDerivedUnionEObjectEStoreEListfrom specified parameters. -
Method Summary
Modifier and TypeMethodDescriptionbooleanAppends the specified element to the end of this list (optional operation).booleanThe method is copied from supper and fixed casting to Collection instead of List.booleanisEmpty()move(int newPosition, int oldPosition) Move is not supported however the method returns value at old index.voidDoes nothing.protected ListIterator<E>protected ListIterator<E>protected ListIterator<E>booleansnapshot()Methods inherited from class org.eclipse.uml2.common.util.DerivedUnionEObjectEList
basicList, isIncludedMethods inherited from class org.eclipse.uml2.common.util.DerivedEObjectEList
add, addAll, addAllUnique, addUnique, basicListIterator, createNotification, derive, dispatchNotification, doAddAllUnique, get, getEObject, getEStructuralFeature, getEStructuralFeature, isIncluded, isNotificationRequired, isSet, listIterator, listIterator, remove, set, set, setUnique, size, unset, validateMethods inherited from class org.eclipse.emf.ecore.util.AbstractSequentialInternalEList
addAllUnique, addUnique, basicAdd, basicContains, basicContainsAll, basicGet, basicIndexOf, basicIterator, basicLastIndexOf, basicListIterator, basicRemove, basicToArray, basicToArrayMethods inherited from class java.util.AbstractSequentialList
get, iteratorMethods inherited from class java.util.AbstractList
clear, equals, hashCode, indexOf, lastIndexOf, listIterator, removeRange, subListMethods inherited from class java.util.AbstractCollection
addAll, containsAll, removeAll, retainAll, toArray, toArray, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface org.eclipse.emf.ecore.util.InternalEList
addAllUnique, addUnique, basicAdd, basicContains, basicContainsAll, basicGet, basicIndexOf, basicIterator, basicLastIndexOf, basicListIterator, basicRemove, basicToArray, basicToArrayMethods inherited from interface java.util.List
addAll, clear, containsAll, equals, get, hashCode, indexOf, iterator, lastIndexOf, listIterator, removeAll, replaceAll, retainAll, sort, spliterator, subList, toArray, toArray
-
Constructor Details
-
ModifiableDerivedUnionEObjectEList
public ModifiableDerivedUnionEObjectEList(Class<?> dataClass, org.eclipse.emf.ecore.InternalEObject owner, int featureID, int[] sourceFeatureIDs) Creates and initializes a newDerivedUnionEObjectEStoreEListfrom specified parameters.- Parameters:
dataClass- class of objects which will be stored in the collection.owner- owner of the collection.featureID- feature which value this list represents ID.sourceFeatureIDs- identifiers of features that compose values of this list.
-
-
Method Details
-
add
Appends the specified element to the end of this list (optional operation).Lists that support this operation may place limitations on what elements may be added to this list. In particular, some lists will refuse to add null elements, and others will impose restrictions on the type of elements that may be added. List classes should clearly specify in their documentation any restrictions on what elements may be added.
This implementation calls
add(size(), e).Note that this implementation throws an
UnsupportedOperationExceptionunlessadd(int, E)is overridden.- Specified by:
addin interfaceCollection<E>- Specified by:
addin interfaceList<E>- Overrides:
addin classAbstractList<E>- Parameters:
e- element to be appended to this list- Returns:
true(as specified byCollection.add(E))- Throws:
UnsupportedOperationException- if theaddoperation is not supported by this listClassCastException- if the class of the specified element prevents it from being added to this listNullPointerException- if the specified element is null and this list does not permit null elementsIllegalArgumentException- if some property of this element prevents it from being added to this list
-
move
Move is not supported however the method returns value at old index. -
move
Does nothing. Move is not supported. -
remove
- Specified by:
removein interfaceCollection<E>- Specified by:
removein interfaceList<E>- Overrides:
removein classAbstractCollection<E>
-
contains
The method is copied from supper and fixed casting to Collection instead of List. -
newListIterator
- Overrides:
newListIteratorin classorg.eclipse.uml2.common.util.DerivedEObjectEList<E>
-
newResolvingListIterator
- Overrides:
newResolvingListIteratorin classorg.eclipse.uml2.common.util.DerivedEObjectEList<E>
-
newEmptyListIterator
- Overrides:
newEmptyListIteratorin classorg.eclipse.uml2.common.util.DerivedEObjectEList<E>
-
isEmpty
public boolean isEmpty() -
snapshot
-