|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.forester.phylogeny.iterators.LevelOrderTreeIterator
public class LevelOrderTreeIterator
Constructor Summary | |
---|---|
LevelOrderTreeIterator(Phylogeny phylogeny)
Creates a new LevelOrderTreeIterator for iterating over all the nodes of Phylogeny phylogeny |
|
LevelOrderTreeIterator(PhylogenyNode node)
Creates a new LevelOrderTreeIterator for iterating over all the child nodes of PhylogenyNode node (including node itself). |
Method Summary | |
---|---|
boolean |
hasNext()
Returns true is this iterator has at least one more element, false otherwise. |
PhylogenyNode |
next()
Returns the next PhylogenyNode. |
void |
remove()
Not supported. |
void |
reset()
Resets the iterator. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LevelOrderTreeIterator(Phylogeny phylogeny) throws IllegalArgumentException
phylogeny
- the Phylogeny to iterate over
IllegalArgumentException
- if phylogeny is emptypublic LevelOrderTreeIterator(PhylogenyNode node)
node
- the parent of the nodes to iterate overMethod Detail |
---|
public boolean hasNext()
hasNext
in interface Iterator<PhylogenyNode>
hasNext
in interface PhylogenyNodeIterator
public PhylogenyNode next() throws NoSuchElementException
next
in interface Iterator<PhylogenyNode>
next
in interface PhylogenyNodeIterator
NoSuchElementException
- if iteration is completepublic void remove()
remove
in interface Iterator<PhylogenyNode>
public void reset()
reset
in interface PhylogenyNodeIterator
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |