|
JAPI 0.9.0 Yet another Java API API Documentation |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.japi.util.EnumerationIterator<T>
public class EnumerationIterator<T>
Combined Iterator/Iterable proxy for enumerations. Instances are not reusable.
| Constructor Summary | |
|---|---|
EnumerationIterator(Enumeration<T> enumeration)
Create an Iterable based on an Enumeration, useful for foreach-loops. |
|
| Method Summary | |
|---|---|
boolean |
hasNext()
Returns true if the iteration has more elements. |
Iterator<T> |
iterator()
Returns an iterator over a set of elements of type T. |
T |
next()
Returns the next element in the iteration. |
void |
remove()
Removes from the underlying collection the last element returned by the iterator (optional operation). |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public EnumerationIterator(Enumeration<T> enumeration)
enumeration - Enumeration to iterate over| Method Detail |
|---|
public Iterator<T> iterator()
iterator in interface Iterable<T>public boolean hasNext()
hasNext in interface Iterator<T>
public T next()
throws NoSuchElementException
Iterator.hasNext() method returns false will
return each element in the underlying collection exactly once.
next in interface Iterator<T>NoSuchElementException - iteration has no more elements.public void remove()
remove in interface Iterator<T>
|
JAPI Yet another Java API API Documentation |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||