Public Member Functions | |
A_Star_Node (Node realNode, double f, int counter) | |
A_Star_Node (Node realNode, int counter) | |
void | reset (int counter) |
int | getCounter () |
boolean | isInClosedList () |
void | setInClosedList (boolean state) |
boolean | isInOpenList () |
void | setInOpenList (boolean state) |
double | getF () |
void | setF (double f) |
double | getG () |
void | setG (double g) |
A_Star_Node | getPredecessor () |
void | setPredecessor (A_Star_Node predecessor) |
Node | getRealNode () |
int | compareTo (Object other) |
A node specific for the computation in an A*-algorithm.
|
inline |
Instantiates a new A_Star_Node from a node existing on the map.
realNode | the real node from the map associated with this A*-specific node |
f | the initial value for the approximate distance/time/penalty... to the target |
counter | a value to determine if this node is valid for the current routing calculation |
|
inline |
Instantiates a new A_Star_Node from a node existing on the map. The f value is set to 0.
realNode | the real node from the map associated with this A*-specific node |
counter | a value to determine if this node is valid for the current routing calculation |
|
inline |
Function needed to implement the Comparable
interface. This allows automatic sorting of this node in a SortedSet
like a TreeSet
based on it's f-value.
other | object to compare this node with |
0
if other
is the same, 1
if this is greater than other
and -1
if this is less than other
|
inline |
Returns the current value for the counter
|
inline |
Gets the f value (=approximated distance/time/penalty... from this point to the target).
|
inline |
Gets the g value (=distance/time/penalty... from this point to the beginning).
|
inline |
Gets the predecessor of this node.
|
inline |
Gets the "real" node in the map associated with this A*-specific node.
|
inline |
Returns if this node is in the ClosedList.
true
if node is already in ClosedList, else false
|
inline |
Returns if this node is in the OpenList.
true
if node is already in OpenList, else false
|
inline |
Resets the values of the node to the default values so that it can be reused. If the node is already valid for the current routing run, nothing is done.
counter | a value to determine if this node is valid for the current routing calculation |
|
inline |
Sets the f value (=approximated distance/time/penalty... from this point to the target).
f | the new f value |
|
inline |
Sets the g value (=distance/time/penalty... from this point to the beginning).
g | the new g value |
|
inline |
Sets if this node is in the ClosedList or not.
state | true if this node shall be in the ClosedList, else false |
|
inline |
Sets if this node is in the OpenList or not.
state | true if this node shall be in the OpenList, else false |
|
inline |
Sets the predecessor of this node.
predecessor | the new predecessor |