4 using namespace __gnu_cxx;
6 const Literals Action::_empty;
8 Action::Action(std::string name,const Preconditions& preconditions, std::string executable,const EffectsMap& effects){
10 _executable = executable;
11 _preconditions = preconditions;
15 Action::Action(const Action& action){
17 _preconditions = action._preconditions;
18 _effects = action._effects;
21 const Literals& Action::effects(int value) const{
22 EffectsMap::const_iterator effects = _effects.find(value);
23 if (effects != _effects.end())
24 return effects->second;
28 const Preconditions& Action::preconditions() const{
29 return _preconditions;
32 int Action::execute() const{
33 cout << "Executing: " << _executable << endl;
37 const string& Action::name() const{