|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.partnersoft.data.EmptyIterator<T>
public class EmptyIterator<T>
An Iterator for nothing.
Use EmptyIterator whenever you want a non-null, but empty, Iterator. It has no state so feel free to use the standardInstance() and avoid creating a new copy.
Copyright 2003-2006 Partner Software, Inc.
| Constructor Summary | |
|---|---|
EmptyIterator()
Creates an EmptyIterator. |
|
| Method Summary | |
|---|---|
boolean |
hasNext()
Always returns false. |
T |
next()
Always throws NoSuchElementException. |
void |
remove()
Always throws UnsupportedOperationException. |
static EmptyIterator |
standardInstance()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public EmptyIterator()
standardInstance() instead.
| Method Detail |
|---|
public static EmptyIterator standardInstance()
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 | ||||||||