|
Oracle Fusion Middleware Java API Reference for Oracle WebCenter Portal 11g Release 1 (11.1.1.6.0) E15995-05 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.webcenter.search.util.ConditionalIterator<T>
public abstract class ConditionalIterator<T>
A generic utility decorator abstract base class of Iterator that allows subclasses to decide when an element can be included in the resulting Iterator.
Constructor Summary | |
---|---|
ConditionalIterator(java.util.Iterator<T> source) Constructs a ConditionalIterator with a source Iterator of type T. |
Method Summary | |
---|---|
boolean |
hasNext() Whether there are more elements to be fetched from this Iterator. |
protected abstract boolean |
isAllowed(T element) Subclasses implement this method to determine if an element is allowed to be returned. |
T |
next() Fetches the next element in the Iterator that matches the condition implemented by subclasses' isAllowed method. |
void |
remove() Removes the currently selected element in the Iterator. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ConditionalIterator(java.util.Iterator<T> source)
source
- an Iterator of type T to test conditions onMethod Detail |
---|
public boolean hasNext()
hasNext
in interface java.util.Iterator<T>
public void remove()
remove
in interface java.util.Iterator<T>
public T next()
next
in interface java.util.Iterator<T>
protected abstract boolean isAllowed(T element)
element
- Iterator element being tested for allowal
|
Oracle Fusion Middleware Java API Reference for Oracle WebCenter Portal 11g Release 1 (11.1.1.6.0) E15995-05 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |