Payload - The payload type.public interface BidirectionalIterator<Payload> extends Iterator<Payload>
BidirectionalIterator is an Iterator that can move in two
directions.| Modifier and Type | Method and Description |
|---|---|
boolean |
hasPrevious()
Returns whether this
BidirectionalIterator has a previous
element. |
Payload |
previous()
Returns the previous element.
|
void |
remove()
Removes the last returned (either by
Iterator.next()
or by previous()) payload value from the
underlying data structure. |
forEachRemaining, hasNext, nextboolean hasPrevious()
BidirectionalIterator has a previous
element.BidirectionalIterator has a previous
element.Payload previous() throws NoSuchElementException
NoSuchElementException - If this BidirectionalIterator has no previous
element.void remove()
throws UnsupportedOperationException,
IllegalStateException
Iterator.next()
or by previous()) payload value from the
underlying data structure.remove in interface Iterator<Payload>UnsupportedOperationException - If this BidirectionalIterator doesn't support
element removal.IllegalStateException - If neither Iterator.next() nor
previous() has been called
or if remove() has already
been called after the last call to
Iterator.next() or
previous().Copyright © 2015–2017 Markenwerk – Gesellschaft für markenbildende Maßnahmen mbH. All rights reserved.