Go to the documentation of this file.00001
00002 #ifndef actasp_Clingo3_h__guard
00003 #define actasp_Clingo3_h__guard
00004
00005 #include <actasp/QueryGenerator.h>
00006
00007 namespace actasp {
00008
00009 struct Clingo3 : public QueryGenerator {
00010
00011 Clingo3(const std::string& incrementalVar,
00012 const std::string& queryDir,
00013 const std::string& domainDir,
00014 const ActionSet& actions,
00015 unsigned int max_time = 0
00016 ) throw();
00017
00018 std::list<actasp::AnswerSet> minimalPlanQuery(const std::vector<actasp::AspRule>& goalRules,
00019 bool filterActions,
00020 unsigned int max_plan_length,
00021 unsigned int answerset_number) const throw();
00022
00023 std::list<actasp::AnswerSet> lengthRangePlanQuery(const std::vector<actasp::AspRule>& goalRules,
00024 bool filterActions,
00025 unsigned int min_plan_length,
00026 unsigned int max_plan_length,
00027 unsigned int answerset_number) const throw();
00028
00029 std::list<actasp::AnswerSet> monitorQuery(const std::vector<actasp::AspRule>& goalRules,
00030 const AnswerSet& plan) const throw();
00031
00032
00033 AnswerSet currentStateQuery(const std::vector<actasp::AspRule>& query) const throw();
00034
00035 void setCurrentState(const std::set<actasp::AspFluent>& newState);
00036
00037
00038 std::list<actasp::AnswerSet> genericQuery(const std::vector<actasp::AspRule>& query,
00039 unsigned int timestep,
00040 const std::string& fileName,
00041 unsigned int answerSetsNumber) const throw();
00042
00043 std::list< std::list<AspAtom> > genericQuery(const std::string& query,
00044 unsigned int timestep,
00045 const std::string& fileName,
00046 unsigned int answerSetsNumber) const throw();
00047
00048 private:
00049
00050 std::list<actasp::AnswerSet> genericQuery(const std::string& query,
00051 unsigned int initialTimeStep,
00052 unsigned int finalTimeStep,
00053 const std::string& fileName,
00054 unsigned int answerSetsNumber) const throw();
00055
00056 std::string makeQuery(const std::string& query,
00057 unsigned int initialTimeStep,
00058 unsigned int finalTimeStep,
00059 const std::string& fileName,
00060 unsigned int answerSetsNumber) const throw();
00061
00062 std::string generatePlanQuery(std::vector<actasp::AspRule> goalRules,
00063 bool filterActions) const throw();
00064
00065 std::string incrementalVar;
00066 std::string actionFilter;
00067 unsigned int max_time;
00068 std::string queryDir;
00069 std::string domainDir;
00070
00071
00072 };
00073
00074 }
00075
00076 #endif