ActionFactory.h
Go to the documentation of this file.
00001 #ifndef bwi_actexec_ActionFactory_h__guard
00002 #define bwi_actexec_ActionFactory_h__guard
00003 
00004 #include "actasp/actaspfwd.h"
00005 
00006 #include <string>
00007 #include <map>
00008 #include <stdexcept>
00009 
00010 namespace bwi_krexec {
00011 
00012 struct ActionFactory {
00013         
00014         typedef std::map<std::string, actasp::Action*> ActionMap;
00015         
00016         explicit ActionFactory(actasp::Action *act); //both simulation and real world
00017         ActionFactory(actasp::Action *act, bool simulation); //either simulation or real world
00018         
00019         static actasp::Action *byName(const std::string& name) throw (std::runtime_error);
00020         static ActionMap actions();
00021         
00022         static void setSimulation(bool value);
00023         
00024 private:
00025         static bool simulation;
00026         static ActionMap &realActions();
00027         static ActionMap &simulatedActions();
00028         static ActionMap &bothActions();
00029 };
00030 
00031 }
00032 
00033 #endif


bwi_kr_execution
Author(s): Matteo Leonetti, Piyush Khandelwal
autogenerated on Thu Jun 6 2019 17:57:36