public class ImmutableList<E> extends AbstractList<E> implements RandomAccess
modCount| Modifier | Constructor and Description |
|---|---|
protected |
ImmutableList(Collection<? extends E> elements) |
protected |
ImmutableList(E... elements) |
| Modifier and Type | Method and Description |
|---|---|
void |
clear() |
E |
get(int index) |
Iterator<E> |
iterator() |
ListIterator<E> |
listIterator(int index) |
static <E> ImmutableList<E> |
newInstance(Collection<? extends E> elements) |
static <E> ImmutableList<E> |
newInstance(E... elements) |
boolean |
remove(Object o) |
boolean |
removeAll(Collection<?> clctn) |
boolean |
retainAll(Collection<?> c) |
int |
size() |
add, add, addAll, equals, hashCode, indexOf, lastIndexOf, listIterator, remove, removeRange, set, subListaddAll, contains, containsAll, isEmpty, toArray, toArray, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitaddAll, contains, containsAll, isEmpty, replaceAll, sort, spliterator, toArray, toArrayparallelStream, removeIf, streamprotected ImmutableList(E... elements)
protected ImmutableList(Collection<? extends E> elements)
public static <E> ImmutableList<E> newInstance(E... elements)
public static <E> ImmutableList<E> newInstance(Collection<? extends E> elements)
public E get(int index)
public int size()
size in interface Collection<E>size in interface List<E>size in class AbstractCollection<E>public boolean remove(Object o)
remove in interface Collection<E>remove in interface List<E>remove in class AbstractCollection<E>public boolean removeAll(Collection<?> clctn)
removeAll in interface Collection<E>removeAll in interface List<E>removeAll in class AbstractCollection<E>public void clear()
clear in interface Collection<E>clear in interface List<E>clear in class AbstractList<E>public boolean retainAll(Collection<?> c)
retainAll in interface Collection<E>retainAll in interface List<E>retainAll in class AbstractCollection<E>public ListIterator<E> listIterator(int index)
listIterator in interface List<E>listIterator in class AbstractList<E>Copyright © 2006–2017 The Apache Software Foundation. All rights reserved.