|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.floodlightcontroller.util.FilterIterator<T>
public abstract class FilterIterator<T>
An iterator that will filter values from an iterator and return only those values that match the predicate.
| Field Summary | |
|---|---|
protected T |
next
|
protected java.util.Iterator<T> |
subIterator
|
| Constructor Summary | |
|---|---|
FilterIterator(java.util.Iterator<T> subIterator)
Construct a filter iterator from the given sub iterator |
|
| Method Summary | |
|---|---|
boolean |
hasNext()
|
protected abstract boolean |
matches(T value)
Check whether the given value should be returned by the filter |
T |
next()
|
void |
remove()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.util.Iterator<T> subIterator
protected T next
| Constructor Detail |
|---|
public FilterIterator(java.util.Iterator<T> subIterator)
subIterator - the sub iterator over which we'll filter| Method Detail |
|---|
protected abstract boolean matches(T value)
value - the value to check
public boolean hasNext()
hasNext in interface java.util.Iterator<T>public T next()
next in interface java.util.Iterator<T>public void remove()
remove in interface java.util.Iterator<T>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||