Class PrismContainerArrayList<T extends Containerable>
- java.lang.Object
-
- java.util.AbstractCollection<E>
-
- java.util.AbstractList<T>
-
- com.evolveum.midpoint.prism.impl.xjc.PrismContainerArrayList<T>
-
- All Implemented Interfaces:
PrismList
,Serializable
,Iterable<T>
,Collection<T>
,List<T>
- Direct Known Subclasses:
ContainerablePrismBinding.ContainerableList
public abstract class PrismContainerArrayList<T extends Containerable> extends AbstractList<T> implements Serializable, PrismList
- Author:
- lazyman Changed to extend AbstractList instead of ArrayList, as some functionality of ArrayList (e.g. its optimized Itr class) does not work with class (PrismContainerArrayList), as of Java7. TODO: account for concurrent structural modifications using modCount property
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class java.util.AbstractList
modCount
-
-
Constructor Summary
Constructors Constructor Description PrismContainerArrayList()
PrismContainerArrayList(PrismContainer<T> container)
PrismContainerArrayList(PrismContainer<T> container, PrismContainerValue<?> parent)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description boolean
add(T t)
boolean
addAll(Collection<? extends T> ts)
protected abstract T
createItem(PrismContainerValue value)
protected T
createItemInternal(PrismContainerValue value)
T
get(int i)
protected abstract PrismContainerValue
getValueFrom(T t)
boolean
isEmpty()
T
remove(int i)
boolean
remove(Object o)
boolean
removeAll(Collection<?> objects)
int
size()
-
Methods inherited from class java.util.AbstractList
add, addAll, clear, equals, hashCode, indexOf, iterator, lastIndexOf, listIterator, listIterator, removeRange, set, subList
-
Methods inherited from class java.util.AbstractCollection
contains, containsAll, retainAll, toArray, toArray, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
-
Methods inherited from interface java.util.List
contains, containsAll, replaceAll, retainAll, sort, spliterator, toArray, toArray
-
-
-
-
Constructor Detail
-
PrismContainerArrayList
public PrismContainerArrayList()
-
PrismContainerArrayList
public PrismContainerArrayList(PrismContainer<T> container)
-
PrismContainerArrayList
public PrismContainerArrayList(PrismContainer<T> container, PrismContainerValue<?> parent)
-
-
Method Detail
-
getValueFrom
protected abstract PrismContainerValue getValueFrom(T t)
-
createItemInternal
protected T createItemInternal(PrismContainerValue value)
-
createItem
protected abstract T createItem(PrismContainerValue value)
-
get
public T get(int i)
- Specified by:
get
in interfaceList<T extends Containerable>
- Specified by:
get
in classAbstractList<T extends Containerable>
-
size
public int size()
- Specified by:
size
in interfaceCollection<T extends Containerable>
- Specified by:
size
in interfaceList<T extends Containerable>
- Specified by:
size
in classAbstractCollection<T extends Containerable>
-
remove
public T remove(int i)
- Specified by:
remove
in interfaceList<T extends Containerable>
- Overrides:
remove
in classAbstractList<T extends Containerable>
-
removeAll
public boolean removeAll(Collection<?> objects)
- Specified by:
removeAll
in interfaceCollection<T extends Containerable>
- Specified by:
removeAll
in interfaceList<T extends Containerable>
- Overrides:
removeAll
in classAbstractCollection<T extends Containerable>
-
remove
public boolean remove(Object o)
- Specified by:
remove
in interfaceCollection<T extends Containerable>
- Specified by:
remove
in interfaceList<T extends Containerable>
- Overrides:
remove
in classAbstractCollection<T extends Containerable>
-
add
public boolean add(T t)
- Specified by:
add
in interfaceCollection<T extends Containerable>
- Specified by:
add
in interfaceList<T extends Containerable>
- Overrides:
add
in classAbstractList<T extends Containerable>
-
addAll
public boolean addAll(Collection<? extends T> ts)
- Specified by:
addAll
in interfaceCollection<T extends Containerable>
- Specified by:
addAll
in interfaceList<T extends Containerable>
- Overrides:
addAll
in classAbstractCollection<T extends Containerable>
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty
in interfaceCollection<T extends Containerable>
- Specified by:
isEmpty
in interfaceList<T extends Containerable>
- Overrides:
isEmpty
in classAbstractCollection<T extends Containerable>
-
-