|
|
|||||||||||||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||||||||||||
java.lang.Objectde.lmu.ifi.dbs.elki.utilities.BreadthFirstEnumeration<E>
public class BreadthFirstEnumeration<E extends Enumeratable<E>>
Provides a breadth first enumeration over enumeratable objects.
| Field Summary | |
|---|---|
Enumeration<E> |
EMPTY_ENUMERATION
Represents an empty enumeration. |
private Queue<E> |
queue
The queue for the enumeration. |
| Constructor Summary | |
|---|---|
BreadthFirstEnumeration(E root)
Creates a new breadth first enumeration with the specified node as root node. |
|
| Method Summary | |
|---|---|
boolean |
hasMoreElements()
Tests if this enumeration contains more elements. |
E |
nextElement()
Returns the next element of this enumeration if this enumeration object has at least one more element to provide. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public final Enumeration<E extends Enumeratable<E>> EMPTY_ENUMERATION
private Queue<E extends Enumeratable<E>> queue
| Constructor Detail |
|---|
public BreadthFirstEnumeration(E root)
root - the root of the enumeration| Method Detail |
|---|
public boolean hasMoreElements()
hasMoreElements in interface Enumeration<E extends Enumeratable<E>>true if and only if this enumeration object
contains at least one more element to provide; false
otherwise.public E nextElement()
nextElement in interface Enumeration<E extends Enumeratable<E>>NoSuchElementException - if no more elements exist.
|
|
||||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||||