java.util.Collection<K>, java.lang.Iterable<K>, Size64BooleanBigList, ByteBigList, CharBigList, DoubleBigList, FloatBigList, IntBigList, LongBigList, ObjectBigList<K>, ReferenceBigList<K>, ShortBigListAbstractBooleanBigList, AbstractBooleanBigList.BooleanSubList, AbstractByteBigList, AbstractByteBigList.ByteSubList, AbstractCharBigList, AbstractCharBigList.CharSubList, AbstractDoubleBigList, AbstractDoubleBigList.DoubleSubList, AbstractFloatBigList, AbstractFloatBigList.FloatSubList, AbstractIntBigList, AbstractIntBigList.IntSubList, AbstractLongBigList, AbstractLongBigList.LongSubList, AbstractObjectBigList, AbstractObjectBigList.ObjectSubList, AbstractReferenceBigList, AbstractReferenceBigList.ReferenceSubList, AbstractShortBigList, AbstractShortBigList.ShortSubList, BooleanBigArrayBigList, BooleanBigLists.EmptyBigList, BooleanBigLists.ListBigList, BooleanBigLists.Singleton, BooleanBigLists.SynchronizedBigList, BooleanBigLists.UnmodifiableBigList, ByteBigArrayBigList, ByteBigLists.EmptyBigList, ByteBigLists.ListBigList, ByteBigLists.Singleton, ByteBigLists.SynchronizedBigList, ByteBigLists.UnmodifiableBigList, CharBigArrayBigList, CharBigLists.EmptyBigList, CharBigLists.ListBigList, CharBigLists.Singleton, CharBigLists.SynchronizedBigList, CharBigLists.UnmodifiableBigList, DoubleBigArrayBigList, DoubleBigLists.EmptyBigList, DoubleBigLists.ListBigList, DoubleBigLists.Singleton, DoubleBigLists.SynchronizedBigList, DoubleBigLists.UnmodifiableBigList, FloatBigArrayBigList, FloatBigLists.EmptyBigList, FloatBigLists.ListBigList, FloatBigLists.Singleton, FloatBigLists.SynchronizedBigList, FloatBigLists.UnmodifiableBigList, IntBigArrayBigList, IntBigLists.EmptyBigList, IntBigLists.ListBigList, IntBigLists.Singleton, IntBigLists.SynchronizedBigList, IntBigLists.UnmodifiableBigList, LongBigArrayBigList, LongBigLists.EmptyBigList, LongBigLists.ListBigList, LongBigLists.Singleton, LongBigLists.SynchronizedBigList, LongBigLists.UnmodifiableBigList, ObjectBigArrayBigList, ObjectBigLists.EmptyBigList, ObjectBigLists.ListBigList, ObjectBigLists.Singleton, ObjectBigLists.SynchronizedBigList, ObjectBigLists.UnmodifiableBigList, ReferenceBigArrayBigList, ReferenceBigLists.EmptyBigList, ReferenceBigLists.ListBigList, ReferenceBigLists.Singleton, ReferenceBigLists.SynchronizedBigList, ReferenceBigLists.UnmodifiableBigList, ShortBigArrayBigList, ShortBigLists.EmptyBigList, ShortBigLists.ListBigList, ShortBigLists.Singleton, ShortBigLists.SynchronizedBigList, ShortBigLists.UnmodifiableBigListpublic interface BigList<K> extends java.util.Collection<K>, Size64
Instances of this class implement the same semantics as that of List: however,
getters and setters use long indices, search methods return long values,
and iterators are of type BigListIterator.
| Modifier and Type | Method | Description |
|---|---|---|
void |
add(long index,
K element) |
Inserts the specified element at the specified position in this big list (optional operation).
|
boolean |
addAll(long index,
java.util.Collection<? extends K> c) |
Inserts all of the elements in the specified collection into this big list at the specified position (optional operation).
|
K |
get(long index) |
Returns the element at the specified position.
|
long |
indexOf(java.lang.Object o) |
Returns the index of the first occurrence of the specified element in this big list, or -1 if this big list does not contain the element.
|
long |
lastIndexOf(java.lang.Object o) |
Returns the index of the last occurrence of the specified element in this big list, or -1 if this big list does not contain the element.
|
BigListIterator<K> |
listIterator() |
Returns a big-list iterator over the elements in this big list.
|
BigListIterator<K> |
listIterator(long index) |
Returns a big-list iterator of the elements in this big list, starting at the specified position in this big list.
|
K |
remove(long index) |
Removes the element at the specified position.
|
K |
set(long index,
K element) |
Replaces the element at the specified position in this big list with the specified element (optional operation).
|
default int |
size() |
Deprecated.
Use
Size64.size64() instead. |
void |
size(long size) |
Sets the size of this big list.
|
BigList<K> |
subList(long from,
long to) |
Returns a big sublist view of this big list.
|
K get(long index)
index - a position in the big list.List.get(int)K remove(long index)
index - a position in the big list.List.remove(int)K set(long index, K element)
index - a position in the big list.element - the element to be stored at the specified position.List.set(int,Object)void add(long index,
K element)
index - a position in the big list.element - an element to be inserted.List.add(int,Object)void size(long size)
If the specified size is smaller than the current size, the last elements are
discarded. Otherwise, they are filled with 0/null/false.
size - the new size.boolean addAll(long index,
java.util.Collection<? extends K> c)
index - index at which to insert the first element from the specified collection.c - collection containing elements to be added to this big list.true if this big list changed as a result of the callList.addAll(int, Collection)long indexOf(java.lang.Object o)
o - the object to search for.List.indexOf(Object)long lastIndexOf(java.lang.Object o)
o - the object to search for.List.lastIndexOf(Object)BigListIterator<K> listIterator()
List.listIterator()BigListIterator<K> listIterator(long index)
index - index of first element to be returned from the big-list iterator.List.listIterator(int)BigList<K> subList(long from, long to)
from - the starting element (inclusive).to - the ending element (exclusive).List.subList(int, int)@Deprecated default int size()
Size64.size64() instead.Integer.MAX_VALUE.
This default implementation follows the definition above, which is compatible
with Collection.size().