|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectPolyLine.RealizerNode
public class RealizerNode
A class representing each node in the realizer.
Represents a node of the realizer, which is a vertex of a graph.Copyright: Copyright (c) 2008
Company: Bangladesh University of engineering and technology
Field Summary | |
---|---|
(package private) int[] |
childMax
The id of the child having maximum layer value |
(package private) java.util.LinkedList<java.lang.Integer> |
childT0List
Linked list of the id of the child of this node in Tree_0 |
(package private) int |
id
Identity value of the node |
(package private) boolean |
isLeafT0
if true then this node is a leaf in Tree_0 else not |
(package private) int |
layer
Layer value of this node |
(package private) int[] |
parent
array of the id's of the its parent of this node. |
(package private) int |
x
Abscissa or x-coodinate value of this node |
(package private) int |
xL
id of the node which is left most leaf in the subtree who have this node as root |
(package private) int |
xR
id of the node which is right most leaf in the subtree who have this node as root |
Constructor Summary | |
---|---|
RealizerNode(int id)
Constructor of the node . |
Method Summary | |
---|---|
void |
addChildT0(int id)
Adds the id into the linked list childT0List |
(package private) int |
getChildMax(int treeId)
Returns the maximum layer node of this node in tree treeId |
int |
getChildT0()
Returns the top id in the list but doesn't remove from the list |
int |
getId()
Returns id of this node |
(package private) int |
getLayer()
Returns the layer value of this node |
(package private) int |
getParent(int treeId)
Returns the parent of this node in tree treeId |
int |
getX()
Returns Abscissa of this node |
int |
getXL()
Returns the id of the left most leaf id of its subtree. |
int |
getXR()
Returns the id of the right most leaf id of its subtree. |
boolean |
isLeafT0()
Return whether this node is leaf of tree_0 |
boolean |
isRoot(int treeId)
Checks whether this node is the root of any particular tree. |
int |
popChildT0()
Returns the top id in the list and removes from the list |
(package private) void |
setChildMax(int nodeId,
int treeId)
Sets nodeId as its the maximum layer node in tree_treeId of this node |
(package private) void |
setLayer(int value)
Sets this.layer to the value . |
void |
setLeafT0()
Sets that this node is a leaf of Tree_0 |
(package private) void |
setParent(int nodeId,
int treeId)
Sets nodeId as parent in tree_treeId of this node |
(package private) void |
setX(int value)
Sets the abscissa of this node |
void |
setXL(int val)
Sets this.xL= val |
void |
setXR(int val)
Sets this.xR= val |
java.lang.String |
toString()
Returns the string value of the object Format: id childTo childMax in Tree 0,1,2 layer x xL xR isLeaf |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
int id
int[] parent
int[] childMax
The id of the child having maximum layer value
childMax[0]-> id of the child of this node having maximum layer in Tree_0
int layer
int x
int xL
int xR
java.util.LinkedList<java.lang.Integer> childT0List
boolean isLeafT0
Constructor Detail |
---|
public RealizerNode(int id)
id
- id value of this nodeMethod Detail |
---|
public void setXL(int val)
val
- integer valuepublic void setXR(int val)
val
- integer valuepublic int getXL()
public int getXR()
public int getX()
public int getId()
public boolean isRoot(int treeId)
treeId
- integer value in ={0,1,2}
public void addChildT0(int id)
id
- the id of any node to be added to the listpublic int getChildT0()
public int popChildT0()
public void setLeafT0()
public boolean isLeafT0()
void setChildMax(int nodeId, int treeId)
nodeId
- id value of any nodetreeId
- value in ={0,1,2}void setParent(int nodeId, int treeId)
nodeId
- id value of any nodetreeId
- value in ={0,1,2}int getParent(int treeId)
treeId
- the id of the tree who's parent in the tree.
int getChildMax(int treeId)
treeId
- the id of the tree who's child in the tree.
void setLayer(int value)
value
- integer value of the node id.int getLayer()
void setX(int value)
value
- integer value to be set as the abscissapublic java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |