|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--edu.umd.cs.fuzzyTree.DataNode
Encapsulates the information that is in a node in an XML document. A node has a label and data. A preorder index is also assigned, which is the value assigned to the node in a preorder traversal of the tree.
Field Summary | |
private java.lang.String |
data
|
DisplayNode |
displayNode
Reference to the display node corresponding to this DataNode . |
private int |
graphIndex
Index of this node in the DataGraph |
(package private) int |
isomorphismIndex
Index assigned for comparing whether two nodes are isomorphic to one another |
private java.lang.String |
label
|
(package private) int |
parentGraphIndex
Index of this node's parent in the DataGraph |
(package private) int |
preorderIndex
Index of the node in a preorder traversal of the tree |
(package private) int |
rankInClass
This node's rank in its equivalance class. |
(package private) int |
score
The node's score, which is a measure of its desirability of being in the display tree |
(package private) int |
treeSize
Size of this node (1) + size of node's subtree (a leaf has size 1). |
Constructor Summary | |
DataNode(java.lang.String label,
java.lang.String data,
int graphIndex)
Constructs a DataNode with the given label, data, and index into the
data graph. |
Method Summary | |
java.lang.String |
getData()
Returns the node's data |
int |
getGraphIndex()
Returns this node's index into the DataGraph |
java.lang.String |
getLabel()
Returns the node's label |
DataNode |
getParent(DataGraph dataGraph)
Returns this node's parent, using its parentGraphIndex and the dataGraph . |
void |
setParentGraphIndex(int parent)
Set the index of this node's parent into the DataGraph. |
java.lang.String |
toString()
Returns a string representation of the data node, which includes preorder index, label, data, and score. |
Methods inherited from class java.lang.Object |
|
Field Detail |
private java.lang.String label
private java.lang.String data
private int graphIndex
int parentGraphIndex
int preorderIndex
public DisplayNode displayNode
DataNode
. Value may be
null, in which case the node is not displayed in the display tree. If non-null,
displayNode.dataNode == this
.int isomorphismIndex
int treeSize
int rankInClass
int score
Constructor Detail |
public DataNode(java.lang.String label, java.lang.String data, int graphIndex)
DataNode
with the given label, data, and index into the
data graph.Method Detail |
public int getGraphIndex()
public java.lang.String getLabel()
public java.lang.String getData()
public java.lang.String toString()
toString
in class java.lang.Object
public void setParentGraphIndex(int parent)
public DataNode getParent(DataGraph dataGraph)
parentGraphIndex
and the dataGraph
.
Null is returned if this node is the root.
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |