|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.elkoserver.util.ExcludingIterator<V>
public abstract class ExcludingIterator<V>
Iterator over a collection that excludes a distinguished element.
| Constructor Summary | |
|---|---|
ExcludingIterator(Iterator<V> base)
Constructor. |
|
| Method Summary | |
|---|---|
boolean |
hasNext()
Returns true if the iteration has more elements. |
abstract boolean |
isExcluded(V element)
Test if a given element should be excluded from the iteration. |
V |
next()
Returns the next element in the iteration. |
void |
remove()
This operation is not supported. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ExcludingIterator(Iterator<V> base)
base - The underlying iterator.exclusion - The distinguished element to exclude.| Method Detail |
|---|
public abstract boolean isExcluded(V element)
element - The element to be tested.
public boolean hasNext()
next() would return an element rather than
throwing an exception.)
hasNext in interface Iterator<V>public V next()
next in interface Iterator<V>NoSuchElementException - iteration has no more elements.public void remove()
remove in interface Iterator<V>UnsupportedOperationException - always.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||