24#include <boost/statechart/event.hpp>
34class ISMaccStateMachine;
36namespace state_reactors
71 template <
typename EventType>
74 template <
typename EventType>
78 template <
typename T,
typename TClass>
90 template <
typename TEv>
93 template <
typename TEv>
99 rclcpp::Node::SharedPtr &
getNode();
106 template <
typename TEvent>
110 auto tid = &(
typeid(TEvent));
116 if (eventCallbacks_.count(tid))
void initialize(ISmaccState *ownerState)
virtual void onEventNotified(const std::type_info *eventType)
StateReactor & operator=(const StateReactor &)=delete
virtual void onInitialized()
void notifyEvent(TEvent *ev)
friend ISmaccStateMachine
StateReactor(StateReactor &&)=delete
StateReactor & operator=(StateReactor &&)=delete
std::function< void()> postEventFn
rclcpp::Node::SharedPtr & getNode()
void createEventCallback(void(TClass::*callback)(T *), TClass *object)
rclcpp::Logger getLogger()
std::vector< const std::type_info * > eventTypes
StateReactor(const StateReactor &)=delete
std::map< const std::type_info *, std::function< void(void *)> > eventCallbacks_
virtual bool triggers()=0