Reinforcement Learning Toolbox 2.0
last updated:
General
Documentation
Manual
Tutorial
Class Reference
Master Thesis
Examples
Related Papers
Downloads
Links
News
mailto:webmaster
Main Page     Class Hierarchy   Compound List   File List   Compound Members   File Members

CPrimitiveActionStateChange Class Reference

This class represents an primitive action which gets executed until a specific (mostly discrete) state changes. More...

#include <chierarchicbehaviours.h>

Inheritance diagram for CPrimitiveActionStateChange:

CExtendedAction CMultiStepAction CAction List of all members.


Public Member Functions

  CPrimitiveActionStateChange (CPrimitiveAction *action, CStateProperties *stateToChange)
virtual CAction getNextHierarchyLevel (CStateCollection *state, CActionDataSet *actionDataSet=NULL)
  Always returns primitiveAction.

virtual bool  isFinished (CStateCollection *oldState, CStateCollection *newState)
void  setStateToChange (CStateProperties *stateToChange)


Protected Attributes

CStateProperties stateToChange
  The Properties of the state which has to change.

CPrimitiveAction primitiveAction

Detailed Description

This class represents an primitive action which gets executed until a specific (mostly discrete) state changes.

This extended action subclass executes a primitive action until a specified state changes. This can be useful for example in gridworlds with local states. The state which has to change is given by "stateToChange" an will be most time a discrete state (continuous states or features normally always change). The isFinished method returns as long false as the 2 states (oldState and newState) are the same.


Constructor & Destructor Documentation

CPrimitiveActionStateChange::CPrimitiveActionStateChange CPrimitiveAction action,
CStateProperties stateToChange
 

Member Function Documentation

virtual CAction* CPrimitiveActionStateChange::getNextHierarchyLevel CStateCollection state,
CActionDataSet actionDataSet = NULL
[virtual]
 

Always returns primitiveAction.

Implements CExtendedAction.

virtual bool CPrimitiveActionStateChange::isFinished CStateCollection oldState,
CStateCollection newState
[virtual]
 

This method is normally used by a hierarchical controller to determine wether the action has finished or not. The finsished method may depend only on the current state transition, so you get the old state and the new state as parameters. The controller sets the finished flag according to isFinished, so other Listeners only have to look at this flag. This method must be implemented by all (non-abstract) sub-classes.

Implements CMultiStepAction.

void CPrimitiveActionStateChange::setStateToChange CStateProperties stateToChange  ) 
 

Member Data Documentation

CPrimitiveAction* CPrimitiveActionStateChange::primitiveAction [protected]
 
CStateProperties* CPrimitiveActionStateChange::stateToChange [protected]
 

The Properties of the state which has to change.


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