Assignment Search Framework
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Pages
SingleGoalTest< state_t > Class Template Reference
Inheritance diagram for SingleGoalTest< state_t >:

Public Member Functions

 SingleGoalTest (const state_t &g)
 
virtual ~SingleGoalTest ()
 
virtual bool isGoal (const state_t &state) const
 
virtual void setGoal (const state_t &g)
 
state_t getCurrentGoal () const
 
- Public Member Functions inherited from GoalTestFunction< state_t >
 GoalTestFunction ()
 
virtual ~GoalTestFunction ()
 

Protected Attributes

state_t goal
 The stored goal state. More...
 

Detailed Description

template<class state_t>
class SingleGoalTest< state_t >

Defines a goal test function when there is a single goal state.

Constructor & Destructor Documentation

template<class state_t >
SingleGoalTest< state_t >::SingleGoalTest ( const state_t &  g)

Constructs a goal test function where there is a given single goal state.

Parameters
gThe goal state.
template<class state_t >
SingleGoalTest< state_t >::~SingleGoalTest ( )
virtual

Destructor for a single goal test function. Destructor is empty.

Member Function Documentation

template<class state_t >
state_t SingleGoalTest< state_t >::getCurrentGoal ( ) const

Returns the current goal state.

Returns
The current goal state.
template<class state_t >
bool SingleGoalTest< state_t >::isGoal ( const state_t &  state) const
virtual

Performs the goal test on the given state.

Parameters
stateThe state to test.
Returns
If the given state is a goal state.

Implements GoalTestFunction< state_t >.

template<class state_t >
void SingleGoalTest< state_t >::setGoal ( const state_t &  g)
virtual

Resets the goal state to a new given state.

Parameters
gThe new goal state.

Member Data Documentation

template<class state_t >
state_t SingleGoalTest< state_t >::goal
protected

The stored goal state.


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