Class IndexedList<E>
java.lang.Object
org.eclipse.net4j.util.collection.IndexedList<E>
- Type Parameters:
E- the element type
- All Implemented Interfaces:
Iterable<E>,Collection<E>,List<E>,SequencedCollection<E>
- Direct Known Subclasses:
IndexedList.ArrayBacked
A list implementation that supports indexed access to its elements.
- Since:
- 3.0
- Author:
- Eike Stepper
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classProvides an array-backed indexed list. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidbooleanbooleanaddAll(int index, Collection<? extends E> c) booleanaddAll(Collection<? extends E> c) voidclear()booleanbooleancontainsAll(Collection<?> c) abstract Eget(int index) intbooleanisEmpty()iterator()intlistIterator(int index) remove(int index) booleanbooleanremoveAll(Collection<?> c) booleanretainAll(Collection<?> c) abstract intsize()subList(int fromIndex, int toIndex) Object[]toArray()<T> T[]toArray(T[] a) toString()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface java.util.List
addFirst, addLast, equals, getFirst, getLast, hashCode, removeFirst, removeLast, replaceAll, reversed, sort, spliterator
-
Constructor Details
-
IndexedList
public IndexedList()
-
-
Method Details
-
get
-
size
public abstract int size() -
isEmpty
public boolean isEmpty() -
contains
-
containsAll
- Specified by:
containsAllin interfaceCollection<E>- Specified by:
containsAllin interfaceList<E>
-
indexOf
-
lastIndexOf
- Specified by:
lastIndexOfin interfaceList<E>
-
iterator
-
listIterator
- Specified by:
listIteratorin interfaceList<E>
-
listIterator
- Specified by:
listIteratorin interfaceList<E>
-
subList
-
toArray
-
toArray
public <T> T[] toArray(T[] a) -
add
-
remove
-
addAll
-
addAll
-
removeAll
-
retainAll
-
clear
public void clear() -
set
-
add
-
remove
-
toString
-