|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--jade.util.leap.EmptyIterator
Singleton Iterator for an empty collection. The usage of the singleton-pattern for this simple object allows just to save some memory.
Method Summary | |
static Iterator |
getInstance()
Returns the singleton EmptyIterator object. |
boolean |
hasNext()
Checks whether the iterator can scan further. |
java.lang.Object |
next()
Retrieves the next element in the collection scanned by this iterator. |
void |
remove()
Remove the element pointed to by this iterator from the collection. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static Iterator getInstance()
public boolean hasNext()
hasNext
in interface java.util.Iterator
false
.public java.lang.Object next()
next
in interface java.util.Iterator
java.util.NoSuchElementException
- Always, because the underlying
collection is always empty.public void remove()
remove
in interface java.util.Iterator
java.lang.RuntimeException
- Always, because the underlying
collection is always empty.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |