[statechart] Can events carry data?

Is there any provision for "event-local" storage? I'd like to create events that carry data (e.g., timestamp, source, etc.) to be used by reactions and transitions to update state-local storage. I didn't see anything like this in the documentation. Bad idea? Major drawbacks? If it wouldn't be a problem, how might I go about doing it? Regards, Dick Bridges

BRIDGES Dick wrote:
Is there any provision for "event-local" storage? I'd like to create events that carry data (e.g., timestamp, source, etc.) to be used by reactions and transitions to update state-local storage.
I didn't see anything like this in the documentation. Bad idea? Major drawbacks? If it wouldn't be a problem, how might I go about doing it?
struct MyEvent : public boost::statechart::event<MyEvent> { int myData; double myOtherData; MyClass myOtherOtherData; };
participants (2)
-
BRIDGES Dick
-
Peter Petrov