public class UnionIterator<E> extends LookAheadIterator<E>
Constructor and Description |
---|
UnionIterator(Iterable<? extends E>... args)
Creates a new UnionIterator that returns the bag union of the results of a number of Iterators.
|
UnionIterator(Iterable<? extends Iterable<? extends E>> args) |
Modifier and Type | Method and Description |
---|---|
protected E |
getNextElement()
Gets the next element.
|
protected void |
handleClose()
Called by
AbstractCloseableIterator.close() when it is called for the first time. |
handleAlreadyClosed, hasNext, next, remove
close, isClosed
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEachRemaining
public UnionIterator(Iterable<? extends E>... args)
args
- The Iterators containing the elements to iterate over.protected E getNextElement()
LookAheadIterator
getNextElement
in class LookAheadIterator<E>
protected void handleClose() throws IOException
AbstractCloseableIterator
AbstractCloseableIterator.close()
when it is called for the first time. This method is only called once on each iteration.
By default, this method does nothing.handleClose
in class LookAheadIterator<E>
IOException
Copyright © 2015-2022 Eclipse Foundation. All Rights Reserved.