public static class ObjectLists.SynchronizedRandomAccessList<K> extends ObjectLists.SynchronizedList<K> implements java.util.RandomAccess, java.io.Serializable
| Modifier and Type | Field and Description |
|---|---|
protected ObjectCollection<K> |
collection |
protected java.lang.Object |
sync |
list| Modifier | Constructor and Description |
|---|---|
protected |
SynchronizedRandomAccessList(ObjectList<K> l) |
protected |
SynchronizedRandomAccessList(ObjectList<K> l,
java.lang.Object sync) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(K k) |
boolean |
addAll(java.util.Collection<? extends K> c) |
void |
clear() |
boolean |
contains(java.lang.Object k) |
boolean |
containsAll(java.util.Collection<?> c) |
void |
forEach(java.util.function.Consumer<? super K> action) |
boolean |
isEmpty() |
java.util.stream.Stream<K> |
parallelStream() |
boolean |
remove(java.lang.Object k) |
boolean |
removeAll(java.util.Collection<?> c) |
boolean |
retainAll(java.util.Collection<?> c) |
int |
size() |
it.unimi.dsi.fastutil.objects.ObjectSpliterator<K> |
spliterator()
Returns a type-specific spliterator on the elements of this collection.
|
java.util.stream.Stream<K> |
stream() |
ObjectList<K> |
subList(int from,
int to)
Returns a type-specific view of the portion of this list from the index
from, inclusive, to the index to, exclusive. |
java.lang.Object[] |
toArray() |
<T> T[] |
toArray(T[] a) |
java.lang.String |
toString() |
add, addAll, addElements, addElements, compareTo, equals, get, getElements, hashCode, indexOf, iterator, lastIndexOf, listIterator, listIterator, remove, removeElements, removeIf, replaceAll, set, setElements, setElements, setElements, size, sort, unstableSortclone, finalize, getClass, notify, notifyAll, wait, wait, waitaddAll, addAll, of, of, of, of, of, spliteratorprotected final ObjectCollection<K> collection
protected final java.lang.Object sync
protected SynchronizedRandomAccessList(ObjectList<K> l, java.lang.Object sync)
protected SynchronizedRandomAccessList(ObjectList<K> l)
public ObjectList<K> subList(int from, int to)
ObjectListfrom, inclusive, to the index to, exclusive.subList in interface ObjectList<K>subList in interface java.util.List<K>subList in class ObjectLists.SynchronizedList<K>List.subList(int,int)public boolean add(K k)
add in interface java.util.Collection<K>public boolean contains(java.lang.Object k)
contains in interface java.util.Collection<K>public boolean remove(java.lang.Object k)
remove in interface java.util.Collection<K>public int size()
size in interface java.util.Collection<K>public boolean isEmpty()
isEmpty in interface java.util.Collection<K>public java.lang.Object[] toArray()
toArray in interface java.util.Collection<K>public <T> T[] toArray(T[] a)
toArray in interface java.util.Collection<K>public it.unimi.dsi.fastutil.objects.ObjectSpliterator<K> spliterator()
ObjectCollectionSee Collection.spliterator() for more documentation on the requirements
of the returned spliterator.
spliterator in interface ObjectCollection<K>spliterator in interface ObjectIterable<K>spliterator in interface java.lang.Iterable<K>spliterator in interface java.util.Collection<K>public java.util.stream.Stream<K> stream()
stream in interface java.util.Collection<K>public java.util.stream.Stream<K> parallelStream()
parallelStream in interface java.util.Collection<K>public void forEach(java.util.function.Consumer<? super K> action)
forEach in interface java.lang.Iterable<K>public boolean addAll(java.util.Collection<? extends K> c)
addAll in interface java.util.Collection<K>public boolean containsAll(java.util.Collection<?> c)
containsAll in interface java.util.Collection<K>public boolean removeAll(java.util.Collection<?> c)
removeAll in interface java.util.Collection<K>public boolean retainAll(java.util.Collection<?> c)
retainAll in interface java.util.Collection<K>public void clear()
clear in interface java.util.Collection<K>public java.lang.String toString()
toString in class java.lang.Object