27template <
typename EventType>
33template <
typename EventType>
39template <
typename TEv>
46 auto *
ev =
new TEv();
51template <
typename TEv>
57template <
typename T,
typename TClass>
79namespace introspection
81template <
typename TEv>
85 functor.fn = [
this](std::shared_ptr<smacc2::StateReactor>
sr)
88 nh_->get_logger(),
"[%s] State Reactor adding input event: %s",
90 sr->addInputEvent<
TEv>();
102template <
typename TEv>
106 functor.fn = [
this](std::shared_ptr<smacc2::StateReactor>
sr)
109 nh_->get_logger(),
"[%s] State Reactor setting output event: %s",
111 sr->setOutputEvent<
TEv>();
virtual ISmaccStateMachine & getStateMachine()=0
void postEvent(const EventType &ev)
std::function< void()> postEventFn
void createEventCallback(void(TClass::*callback)(T *), TClass *object)
rclcpp::Logger getLogger()
std::vector< const std::type_info * > eventTypes
std::map< const std::type_info *, std::function< void(void *)> > eventCallbacks_
std::vector< StateReactorCallbackFunctor > callbacks_
rclcpp::Node::SharedPtr nh_
std::shared_ptr< smacc2::introspection::SmaccStateReactorInfo > srInfo_
static TypeInfo::Ptr getFromStdTypeInfo(const std::type_info &tid)