|
Hemisson Tjerk Kostelijk & Anne Schuth <-- BACK TO CLASSES |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectNode
Constructor Summary | |
Node()
The no-arg constructor only declares the coordinates. |
|
Node(int _iX,
int _iY)
Instantiates the coordinates of the Node. |
|
Node(int _iX,
int _iY,
int _iTop,
int _iRight,
int _iBottom,
int _iLeft)
The full contructor, instantiates the coordinate and wall booleans on the four side's of the coordinate |
|
Node(Node _nNode)
|
|
Node(Point _pPoint)
Instantiates the coordinates of the Node. |
|
Node(Point _pPoint,
int _iTop,
int _iRight,
int _iBottom,
int _iLeft)
The full contructor, instantiates the coordinate and wall booleans on the four side's of the coordinate |
Method Summary | |
boolean |
allBordersKnown()
|
int |
bordersFalseCount()
|
int |
bordersUnknownCount()
|
int |
borderValue(int _iDirection)
Checks wheter a border exist at a given loaction |
int |
getBottom()
|
double |
getF()
|
int |
getG()
|
int |
getH()
|
int |
getLeft()
|
Node |
getParent()
|
int |
getRight()
|
int |
getTop()
|
int |
getX()
|
int |
getY()
|
boolean |
isPointEqual(Node _nNode)
Checks wheter two Nodes have the same Coordinate |
void |
setBorder(int _iDirection,
int _iValue)
Sets the Wall yes or no at Top of gridcoordinate |
void |
setBottom(int _iBottom)
Sets the Wall yes or no at Bottom of gridcoordinate |
void |
setG(int _iG)
Sets the g(n) value |
void |
setH(int _iH)
Sets the h(n) value |
void |
setLeft(int _iLeft)
Sets the Wall yes or no at Left of gridcoordinate |
void |
setParent(Node _nNode)
Sets the parent Node value |
void |
setRight(int _iRight)
Sets the Wall yes or no at Right of gridcoordinate |
void |
setTop(int _iTop)
Sets the Wall yes or no at Top of gridcoordinate |
void |
setX(int _iX)
Sets the X coordinate |
void |
setY(int _iY)
Sets the Y coordinate |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Node()
public Node(Node _nNode)
public Node(Point _pPoint)
_pPoint
- location of the gridcoordinatepublic Node(int _iX, int _iY)
_iX
- the X value of the coordinate_iY
- the Y value of the coordinatepublic Node(Point _pPoint, int _iTop, int _iRight, int _iBottom, int _iLeft)
_pPoint
- location of the gridcoordinate_iTop
- Wall yes or no at Top of gridcoordinate_iRight
- Wall yes or no at Right of gridcoordinate_iBottom
- Wall yes or no at Bottom of gridcoordinate_iLeft
- Wall yes or no at Left of gridcoordinatepublic Node(int _iX, int _iY, int _iTop, int _iRight, int _iBottom, int _iLeft)
_iX
- the X value of the coordinate_iY
- the Y value of the coordinate_iTop
- Wall yes or no at Top of gridcoordinate_iRight
- Wall yes or no at Right of gridcoordinate_iBottom
- Wall yes or no at Bottom of gridcoordinate_iLeft
- Wall yes or no at Left of gridcoordinateMethod Detail |
public boolean isPointEqual(Node _nNode)
_nNode
- The Node that the current Node is compared with
public int borderValue(int _iDirection)
_iDirection
- The direction we are looking at (1=top,2=right,3=left,4=left)
public boolean allBordersKnown()
public int bordersUnknownCount()
public int bordersFalseCount()
public int getX()
public int getY()
public int getH()
public int getG()
public double getF()
public int getTop()
public int getRight()
public int getBottom()
public int getLeft()
public Node getParent()
public void setX(int _iX)
_iX
- the X value of the coordinatepublic void setY(int _iY)
_iY
- the Y value of the coordinatepublic void setBorder(int _iDirection, int _iValue)
public void setTop(int _iTop)
_iTop
- Wall yes or no at Top of gridcoordinatepublic void setRight(int _iRight)
_iRight
- Wall yes or no at Right of gr_iTopidcoordinatepublic void setBottom(int _iBottom)
_iBottom
- Wall yes or no at Bottom of gridcoordinatepublic void setLeft(int _iLeft)
_iLeft
- Wall yes or no at Left of gridcoordinatepublic void setG(int _iG)
_iG
- g(n)public void setH(int _iH)
_iH
- h(n)public void setParent(Node _nNode)
public java.lang.String toString()
|
Hemisson Tjerk Kostelijk & Anne Schuth <-- BACK TO CLASSES |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |