I need to maintain a parameter into the state local storage. This
parameter is initially contained in the event that causes the transition to
the target state. I give hereafter a small illustrative example.
typename sc = boost::statechart;
class EvTest : public sc::event<EvTest>
{
public:
EvTest(std::size_t val) : value(val) {}
std::size_t getValue() const { return this->value; }
private:
std::size_t value;
};
class MyStateMachine;
class StSource;
class StTarget;
class StSource : public sc::simple_state