Fawkes API
Fawkes Development Version
|
21 #include "action_executor_dispatcher.h"
23 #include <core/exception.h>
24 #include <golog++/model/activity.h>
42 std::shared_ptr<ActionExecutor>
45 for (
auto &executor : action_executors_) {
46 if (executor->can_execute_activity(activity)) {
50 throw Exception(std::string(
"No known executor for " + activity->mapped_name()).c_str());
59 action_executors_.push_back(executor);
void add_aspect(const char *name)
Add an aspect to a thread.
void init_GologppDispatcherAspect(gpp::ActionExecutorDispatcher *dispatcher)
Init GologppDispatcherAspect.
GologppDispatcherAspect()
Constructor.
Dispatch an activity to a number of registered executors by checking all registered executors subsequ...
gpp::ActionExecutorDispatcher * gologpp_dispatcher
A pointer to the dispatcher that the aspect provides.
std::shared_ptr< ActionExecutor > get_executor(std::shared_ptr< gologpp::Activity >)
Determine the executor for a given activity.
void finalize_GologppDispatcherAspect()
Finalize the GologppDispatcherAspect.
Fawkes library namespace.
void register_executor(std::shared_ptr< ActionExecutor > executor)
Register a new executor.
Base class for exceptions in Fawkes.