Template Class state_guard_condition1

Inheritance Relationships

Base Type

Class Documentation

template<class SM, class Event, bool (SM::* Func)(const Event*)>
class state_guard_condition1 : public rcppsw::patterns::fsm::state_guard

Condition to determine if a state’s main action should be executed.

Template Parameters:
  • SM – A state machine class.

  • Event – A state function event data type.

  • Func – A state machine member function pointer that takes ONE argument

Public Functions

~state_guard_condition1(void) override = default
inline virtual bool invoke_guard_condition(base_fsm *sm, const event_data *data) const override

Called by the state machine engine to execute a guard condition action. If guard condition evaluates to TRUE the state action is executed. If FALSE, no state transition is performed.

Parameters:

sm – A state machine instance.

Returns:

Returns TRUE if no guard condition or the guard condition evaluates to TRUE.