Class AbstractLinkedList.LinkedSubList
- java.lang.Object
-
- java.util.AbstractCollection<E>
-
- java.util.AbstractList
-
- org.apache.commons.collections.list.AbstractLinkedList.LinkedSubList
-
- All Implemented Interfaces:
Iterable
,Collection
,List
- Enclosing class:
- AbstractLinkedList
protected static class AbstractLinkedList.LinkedSubList extends AbstractList
The sublist implementation for AbstractLinkedList.
-
-
Field Summary
-
Fields inherited from class java.util.AbstractList
modCount
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
LinkedSubList(AbstractLinkedList parent, int fromIndex, int toIndex)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(int index, Object obj)
boolean
addAll(int index, Collection coll)
boolean
addAll(Collection coll)
protected void
checkModCount()
void
clear()
Object
get(int index)
Iterator
iterator()
ListIterator
listIterator(int index)
protected void
rangeCheck(int index, int beyond)
Object
remove(int index)
Object
set(int index, Object obj)
int
size()
List
subList(int fromIndexInclusive, int toIndexExclusive)
-
Methods inherited from class java.util.AbstractList
add, equals, hashCode, indexOf, lastIndexOf, listIterator, removeRange
-
Methods inherited from class java.util.AbstractCollection
contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
-
Methods inherited from interface java.util.List
contains, containsAll, isEmpty, remove, removeAll, replaceAll, retainAll, sort, spliterator, toArray, toArray
-
-
-
-
Constructor Detail
-
LinkedSubList
protected LinkedSubList(AbstractLinkedList parent, int fromIndex, int toIndex)
-
-
Method Detail
-
size
public int size()
- Specified by:
size
in interfaceCollection
- Specified by:
size
in interfaceList
- Specified by:
size
in classAbstractCollection
-
get
public Object get(int index)
- Specified by:
get
in interfaceList
- Specified by:
get
in classAbstractList
-
add
public void add(int index, Object obj)
- Specified by:
add
in interfaceList
- Overrides:
add
in classAbstractList
-
remove
public Object remove(int index)
- Specified by:
remove
in interfaceList
- Overrides:
remove
in classAbstractList
-
addAll
public boolean addAll(Collection coll)
- Specified by:
addAll
in interfaceCollection
- Specified by:
addAll
in interfaceList
- Overrides:
addAll
in classAbstractCollection
-
addAll
public boolean addAll(int index, Collection coll)
- Specified by:
addAll
in interfaceList
- Overrides:
addAll
in classAbstractList
-
set
public Object set(int index, Object obj)
- Specified by:
set
in interfaceList
- Overrides:
set
in classAbstractList
-
clear
public void clear()
- Specified by:
clear
in interfaceCollection
- Specified by:
clear
in interfaceList
- Overrides:
clear
in classAbstractList
-
iterator
public Iterator iterator()
- Specified by:
iterator
in interfaceCollection
- Specified by:
iterator
in interfaceIterable
- Specified by:
iterator
in interfaceList
- Overrides:
iterator
in classAbstractList
-
listIterator
public ListIterator listIterator(int index)
- Specified by:
listIterator
in interfaceList
- Overrides:
listIterator
in classAbstractList
-
subList
public List subList(int fromIndexInclusive, int toIndexExclusive)
- Specified by:
subList
in interfaceList
- Overrides:
subList
in classAbstractList
-
rangeCheck
protected void rangeCheck(int index, int beyond)
-
checkModCount
protected void checkModCount()
-
-