org.sourceforge.jxutil
Class MultiIterator
java.lang.Object
|
+--org.sourceforge.jxutil.MultiIterator
- All Implemented Interfaces:
- Iterator
- public final class MultiIterator
- extends Object
- implements Iterator
An iterator implemented over several other iterators.
- Author:
- Keve Müller
Field Summary |
private int |
cur
The current iterator's index in the array of iterators. |
private Iterator[] |
iters
The array of iterators. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
cur
private int cur
- The current iterator's index in the array of iterators.
iters
private final Iterator[] iters
- The array of iterators.
MultiIterator
public MultiIterator(Iterator[] iters)
MultiIterator
public MultiIterator(Iterator one,
Iterator two)
hasNext
public boolean hasNext()
- Specified by:
hasNext
in interface Iterator
next
public Object next()
throws NoSuchElementException
- Specified by:
next
in interface Iterator
NoSuchElementException
remove
public void remove()
- Specified by:
remove
in interface Iterator
Copyright © 2001,2002 Keve Müller, et al.; see LICENSE file for details.