|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.mhhe.clrs2e.BinomialHeap.Node
Inner class for a node within a binomial heap.
Field Summary | |
BinomialHeap.Node |
child
This node's leftmost child, or null if this
node has no children. |
int |
degree
The number of children that this node has. |
BinomialHeap.Handle |
handle
A handle to this node. |
com.mhhe.clrs2e.DynamicSetElement |
object
The object stored in this node. |
BinomialHeap.Node |
p
This node's parent, or null if this node is a
root. |
BinomialHeap.Node |
sibling
This node's right sibling, or null if this
node has no right sibling. |
Constructor Summary | |
BinomialHeap.Node(com.mhhe.clrs2e.DynamicSetElement e)
Creates a new node. |
Method Summary | |
java.lang.String |
toString()
Returns the String representation of this
node's object. |
java.lang.String |
walk(int depth)
Returns the String representation of the
subtree rooted at this node, based on the objects in the
nodes. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public com.mhhe.clrs2e.DynamicSetElement object
public BinomialHeap.Node p
null
if this node is a
root.
public BinomialHeap.Node child
null
if this
node has no children.
public BinomialHeap.Node sibling
null
if this
node has no right sibling.
public int degree
public BinomialHeap.Handle handle
Constructor Detail |
public BinomialHeap.Node(com.mhhe.clrs2e.DynamicSetElement e)
e
- The dynamic set element to store in the node.Method Detail |
public java.lang.String toString()
String
representation of this
node's object.
toString
in class java.lang.Object
public java.lang.String walk(int depth)
String
representation of the
subtree rooted at this node, based on the objects in the
nodes. It represents the depth of each node by two spaces
per depth preceding the String
representation
of the node.
depth
- Depth of this node.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |