java.util.Iterator
, java.util.ListIterator
, OrderedIterator
protected static class AbstractLinkedList.LinkedSubListIterator extends AbstractLinkedList.LinkedListIterator
Modifier and Type | Field | Description |
---|---|---|
protected AbstractLinkedList.LinkedSubList |
sub |
The parent list
|
current, expectedModCount, next, nextIndex, parent
Modifier | Constructor | Description |
---|---|---|
protected |
LinkedSubListIterator(AbstractLinkedList.LinkedSubList sub,
int startIndex) |
Modifier and Type | Method | Description |
---|---|---|
void |
add(java.lang.Object obj) |
|
boolean |
hasNext() |
|
boolean |
hasPrevious() |
Checks to see if there is a previous element that can be iterated to.
|
int |
nextIndex() |
|
void |
remove() |
checkModCount, getLastNodeReturned, next, previous, previousIndex, set
protected final AbstractLinkedList.LinkedSubList sub
protected LinkedSubListIterator(AbstractLinkedList.LinkedSubList sub, int startIndex)
public boolean hasNext()
hasNext
in interface java.util.Iterator
hasNext
in interface java.util.ListIterator
hasNext
in class AbstractLinkedList.LinkedListIterator
public boolean hasPrevious()
OrderedIterator
hasPrevious
in interface java.util.ListIterator
hasPrevious
in interface OrderedIterator
hasPrevious
in class AbstractLinkedList.LinkedListIterator
true
if the iterator has a previous elementpublic int nextIndex()
nextIndex
in interface java.util.ListIterator
nextIndex
in class AbstractLinkedList.LinkedListIterator
public void add(java.lang.Object obj)
add
in interface java.util.ListIterator
add
in class AbstractLinkedList.LinkedListIterator
public void remove()
remove
in interface java.util.Iterator
remove
in interface java.util.ListIterator
remove
in class AbstractLinkedList.LinkedListIterator
Copyright © 2001-2017 Apache Software Foundation. All Rights Reserved.