Fawkes API  Fawkes Development Version
fawkes::AStarState Class Referenceabstract

This is the abstract(!) class for an A* State. More...

#include <>>

Public Member Functions

 AStarState ()
 Constructor. More...
 
virtual ~AStarState ()
 Destructor. More...
 
virtual long calculateKey ()=0
 Generates a unique key for this state. More...
 
virtual double estimate ()=0
 Estimate the heuristic cost to the goal. More...
 
virtual bool isGoal ()=0
 Check, wether we reached a goal or not. More...
 
virtual std::vector< AStarState * > generateChildren ()=0
 Generate all successors and put them to this vector. More...
 

Public Attributes

AStarStatefather
 Predecessor. More...
 
double pastCost
 Past cost. More...
 
double totalEstimatedCost
 Total estimated cost. More...
 
long key
 The unique key of this state. More...
 

Detailed Description

This is the abstract(!) class for an A* State.

Author
Stefan Jacobs

Definition at line 36 of file astar_state.h.

Constructor & Destructor Documentation

fawkes::AStarState::AStarState ( )
inline

Constructor.

Definition at line 41 of file astar_state.h.

virtual fawkes::AStarState::~AStarState ( )
inlinevirtual

Destructor.

Definition at line 44 of file astar_state.h.

Member Function Documentation

virtual long fawkes::AStarState::calculateKey ( )
pure virtual

Generates a unique key for this state.

There has to be a unique key for each state (fast closed list -> bottleneck!)

Returns
unique long key
virtual double fawkes::AStarState::estimate ( )
pure virtual

Estimate the heuristic cost to the goal.

Returns
estimated cost as double
virtual std::vector< AStarState * > fawkes::AStarState::generateChildren ( )
pure virtual

Generate all successors and put them to this vector.

Returns
a vector of pointers of AStarState to a successor
virtual bool fawkes::AStarState::isGoal ( )
pure virtual

Check, wether we reached a goal or not.

Returns
true, if this state is a goal, else false

Member Data Documentation

AStarState* fawkes::AStarState::father

Predecessor.

Definition at line 72 of file astar_state.h.

long fawkes::AStarState::key

The unique key of this state.

Definition at line 80 of file astar_state.h.

double fawkes::AStarState::pastCost

Past cost.

Definition at line 75 of file astar_state.h.

double fawkes::AStarState::totalEstimatedCost

Total estimated cost.

Definition at line 77 of file astar_state.h.


The documentation for this class was generated from the following file: