com.phoenixst.plexus.examples
public class CompleteTree extends AbstractIntegerNodeGraph
Graph which is a complete tree.
Since: 1.0
Version: $Revision: 1.32 $
| Constructor Summary | |
|---|---|
| CompleteTree(int height, int numChildren)
Creates a new CompleteTree. | |
| Method Summary | |
|---|---|
| protected Graph.Edge | createEdge(int tailIndex, int headIndex) |
| protected Collection | createEdgeCollection() |
| protected Traverser | createTraverser(int nodeIndex) |
| int | degree(Object node)
Returns the degree of node, defined as the number
of edges incident on node. |
| int | getHeight()
Gets the height of this CompleteTree. |
| int | getNumChildren()
Gets the number of children of each internal node in this
CompleteTree. |
| String | toString() |
CompleteTree. A tree of height 0
is just a single root node (numChildren is ignored in this
case).node, defined as the number
of edges incident on node.CompleteTree.CompleteTree.