Package com.google.common.collect
Class Lists.ReverseList<T>
java.lang.Object
java.util.AbstractCollection<E>
java.util.AbstractList<T>
com.google.common.collect.Lists.ReverseList<T>
- All Implemented Interfaces:
Iterable<T>,Collection<T>,List<T>
- Direct Known Subclasses:
Lists.RandomAccessReverseList
- Enclosing class:
- Lists
-
Field Summary
FieldsFields inherited from class java.util.AbstractList
modCount -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidclear()get(int index) iterator()listIterator(int index) remove(int index) protected voidremoveRange(int fromIndex, int toIndex) private intreverseIndex(int index) private intreversePosition(int index) intsize()subList(int fromIndex, int toIndex) Methods inherited from class java.util.AbstractList
add, addAll, equals, hashCode, indexOf, lastIndexOf, listIteratorMethods inherited from class java.util.AbstractCollection
addAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface java.util.List
addAll, contains, containsAll, isEmpty, remove, removeAll, replaceAll, retainAll, sort, spliterator, toArray, toArray
-
Field Details
-
forwardList
-
-
Constructor Details
-
ReverseList
-
-
Method Details
-
getForwardList
-
reverseIndex
private int reverseIndex(int index) -
reversePosition
private int reversePosition(int index) -
add
-
clear
public void clear()- Specified by:
clearin interfaceCollection<T>- Specified by:
clearin interfaceList<T>- Overrides:
clearin classAbstractList<T>
-
remove
-
removeRange
protected void removeRange(int fromIndex, int toIndex) - Overrides:
removeRangein classAbstractList<T>
-
set
-
get
-
size
public int size()- Specified by:
sizein interfaceCollection<T>- Specified by:
sizein interfaceList<T>- Specified by:
sizein classAbstractCollection<T>
-
subList
-
iterator
-
listIterator
- Specified by:
listIteratorin interfaceList<T>- Overrides:
listIteratorin classAbstractList<T>
-