#include <FSMTransition.h>
Inheritance diagram for FSM::CFSMTransition::
Public Methods | |
CFSMAction * | AddAction (const char *className) |
CFSMAction * | GetAction (int index) const |
bool | DeleteAction (CFSMAction *action) |
Action_List::const_iterator | GetActionsBegin () const |
Use (*iterator) to get the pointer to the action. More... | |
Action_List::const_iterator | GetActionsEnd () const |
CFSMCondition * | AddCondition (const char *className="TestVariable") |
CFSMCondition * | GetCondition (int index) const |
bool | DeleteCondition (CFSMCondition *condition) |
Condition_List::const_iterator | GetConditionsBegin () const |
Use (*iterator) to get the pointer to the condition. More... | |
Condition_List::const_iterator | GetConditionsEnd () const |
CFSMState * | GetFromState () const |
const char * | GetOnEvent () const |
void | SetOnEvent (const char *event="ANY") |
CFiniteStateMachine * | GetFSM () const |
const char * | GetNameOfClass () const |
The class name is set by FiniteStateMachine::Create(). More... | |
virtual bool | SetParameter (const char *paramName, const char *paramValue) |
Protected Methods | |
void | SetFromState (const char *stateName) |
virtual bool | Check (bool &result, const char *event, void *a, void *b) |
the answer is in result!!! More... | |
virtual bool | Execute (const char *event, void *a, void *b) |
Called if the transition match. More... | |
virtual bool | Activate () |
Called when the state is activated. More... | |
virtual bool | Deactivate () |
Called when the state is deactivated Calls Deactivate() of conditions (e.g. More... | |
CFSMTransition () | |
virtual | ~CFSMTransition () |
void | SetFSM (CFiniteStateMachine *ptr) |
void | SetClassName (const char *name) |
virtual bool | SaveParameters (CFSMSaver *out) const |
Called by the saver. More... | |
virtual void | DeleteThis ()=0 |
"Destructor" Simple call delete this. More... | |
Private Attributes | |
Action_List | m_Actions |
Condition_List | m_Conditions |
string | m_FromState |
string | m_ToState |
string | m_Event |
Friends | |
class | CFSMState |
class | CFiniteStateMachine |
Definition at line 81 of file FSMTransition.h.
|
Definition at line 37 of file FSMTransition.cpp. |
|
Definition at line 43 of file FSMTransition.cpp. References m_Actions, m_Conditions, m_Event, and m_FromState. |
|
Called when the state is activated. Calls Activate() of conditions (e.g. to start a timer) Definition at line 286 of file FSMTransition.cpp. References iRethrow. |
|
Definition at line 64 of file FSMTransition.cpp. References iRethrow. |
|
Definition at line 135 of file FSMTransition.cpp. References iRethrow. |
|
the answer is in result!!!
Definition at line 236 of file FSMTransition.cpp. |
|
Called when the state is deactivated Calls Deactivate() of conditions (e.g. to stop a timer) Definition at line 301 of file FSMTransition.cpp. References iRethrow, and m_Conditions. |
|
Definition at line 100 of file FSMTransition.cpp. |
|
Definition at line 171 of file FSMTransition.cpp. References CRITICAL, iThrow(), and m_Conditions. |
|
"Destructor" Simple call delete this. This is needed because of the memory management in shared libraries. Provide a static method "Create" in derived classes that returns a new instance of that class and use DeleteThis to destroy it. The constructor and destructor shuld be protected. Reimplemented in FSM::CFSMActionSetVariable, FSM::CFSMActionIncrVariable, FSM::CFSMConditionTestVariable, FSM::CFSMState, FSM::CFSMSimpleTransition, FSM::CFSMPushTransition, and FSM::CFSMPopTransition. |
|
Called if the transition match. Execute actions. Reimplemented in FSM::CFSMSimpleTransition, FSM::CFSMPushTransition, and FSM::CFSMPopTransition. Definition at line 263 of file FSMTransition.cpp. |
|
Definition at line 79 of file FSMTransition.cpp. |
|
Use (*iterator) to get the pointer to the action. Use ++iterator to get the next iterator.
Definition at line 122 of file FSMTransition.cpp. References m_Actions. |
|
Definition at line 127 of file FSMTransition.cpp. References m_Actions. |
|
Definition at line 150 of file FSMTransition.cpp. References CRITICAL, iThrow(), and m_Conditions. |
|
Use (*iterator) to get the pointer to the condition. Use ++iterator to get the next iterator.
Definition at line 193 of file FSMTransition.cpp. References m_Conditions. |
|
Definition at line 198 of file FSMTransition.cpp. References m_Conditions. |
|
Definition at line 216 of file FSMTransition.cpp. References CFSMState, FSM::CFSMObject::GetFSM(), iRethrow, and m_FromState. Referenced by FSM::CFSMSimpleTransition::GetToState(). |
|
Definition at line 56 of file FSMObject.cpp. References FSM::CFSMObject::myStateMachine. Referenced by FSM::CFSMState::AddLeaveAction(), FSM::CFSMState::AddSimpleTransition(), FSM::CFSMConditionTestVariable::CheckCondition(), FSM::CFSMPopTransition::Execute(), FSM::CFSMPushTransition::Execute(), FSM::CFSMSimpleTransition::Execute(), GetFromState(), and FSM::CFSMSimpleTransition::GetToState(). |
|
The class name is set by FiniteStateMachine::Create(). So do not make Create methods public. Definition at line 66 of file FSMObject.cpp. References FSM::CFSMObject::ClassName. Referenced by FSM::CFSMState::Activate(), FSM::CFSMConditionTestVariable::CheckCondition(), FSM::CFSMState::Deactivate(), FSM::CFSMSimpleTransition::SetParameter(), FSM::CFSMConditionTestVariable::SetParameter(), FSM::CFSMActionIncrVariable::SetParameter(), and FSM::CFSMActionSetVariable::SetParameter(). |
|
Definition at line 227 of file FSMTransition.cpp. References m_Event. |
|
Called by the saver. Do not call directly. Overload and call out->SaveParameter() for each parameter. Reimplemented in FSM::CFSMActionSetVariable, FSM::CFSMActionIncrVariable, FSM::CFSMConditionTestVariable, and FSM::CFSMSimpleTransition. Definition at line 80 of file FSMObject.cpp. |
|
Definition at line 61 of file FSMObject.cpp. References FSM::CFSMObject::ClassName. |
|
Definition at line 206 of file FSMTransition.cpp. |
|
Definition at line 51 of file FSMObject.cpp. |
|
Definition at line 211 of file FSMTransition.cpp. References m_Event. |
|
Reimplemented in FSM::CFSMActionSetVariable, FSM::CFSMActionIncrVariable, FSM::CFSMConditionTestVariable, and FSM::CFSMSimpleTransition. Definition at line 71 of file FSMObject.cpp. |
|
Reimplemented from FSM::CFSMObject. Reimplemented in FSM::CFSMSimpleTransition, FSM::CFSMPushTransition, and FSM::CFSMPopTransition. Definition at line 85 of file FSMTransition.h. |
|
Reimplemented in FSM::CFSMSimpleTransition, FSM::CFSMPushTransition, and FSM::CFSMPopTransition. Definition at line 84 of file FSMTransition.h. Referenced by GetFromState(). |
|
Definition at line 159 of file FSMTransition.h. Referenced by DeleteAction(), Execute(), GetAction(), GetActionsBegin(), GetActionsEnd(), and ~CFSMTransition(). |
|
Definition at line 160 of file FSMTransition.h. Referenced by Deactivate(), DeleteCondition(), GetCondition(), GetConditionsBegin(), GetConditionsEnd(), and ~CFSMTransition(). |
|
Definition at line 163 of file FSMTransition.h. Referenced by GetOnEvent(), SetOnEvent(), and ~CFSMTransition(). |
|
Definition at line 161 of file FSMTransition.h. Referenced by GetFromState(), and ~CFSMTransition(). |
|
Reimplemented in FSM::CFSMSimpleTransition. Definition at line 162 of file FSMTransition.h. |