9 #ifndef RTCTK_COMPONENTFRAMEWORK_STATEMACHINEEVENTIF_HPP
10 #define RTCTK_COMPONENTFRAMEWORK_STATEMACHINEEVENTIF_HPP
12 #include <mal/utility/future.hpp>
24 virtual void PostEvent(std::shared_ptr<rad::AnyEvent> e) = 0;
26 template<
typename EventType>
28 auto ev = std::make_shared<EventType>();
29 auto f = ev->GetPayload().GetReplyFuture();
34 template<
typename EventType,
typename PayloadType>
35 ::elt::mal::future<std::string>
InjectEvent(PayloadType& payload) {
36 auto ev = std::make_shared<EventType>(payload);
37 auto f = ev->GetPayload().GetReplyFuture();