#include <Reasoner.h>
Public Member Functions | |
ActionSet | availableActions () const throw () |
std::vector< AnswerSet > | computeAllPlans (const std::vector< actasp::AspRule > &goal, double suboptimality) const throw (std::logic_error) |
AnswerSet | computeOptimalPlan (const std::vector< actasp::AspRule > &goal, bool filterActions, double suboptimality, bool minimum) const throw (std::logic_error) |
AnswerSet | computePlan (const std::vector< actasp::AspRule > &goal) const throw (std::logic_error) |
virtual PartialPolicy * | computePolicy (const std::vector< actasp::AspRule > &goal, double suboptimality) const throw (std::logic_error) |
AnswerSet | currentStateQuery (const std::vector< actasp::AspRule > &query) const throw () |
bool | isPlanValid (const AnswerSet &plan, const std::vector< actasp::AspRule > &goal) const throw () |
std::list< std::list< AspAtom > > | query (const std::string &queryString, unsigned int timestep) const throw () |
Reasoner (QueryGenerator *actualReasoner, unsigned int max_n, const ActionSet &allActions) | |
void | resetCurrentState () throw () |
void | setCurrentState (const std::set< actasp::AspFluent > &newState) throw () |
void | setMaxTimeStep (unsigned int max_n) throw () |
bool | updateFluents (const std::vector< actasp::AspFluent > &observations) throw () |
virtual | ~Reasoner () |
Protected Member Functions | |
void | computePolicyHelper (const std::vector< actasp::AspRule > &goal, double suboptimality, PartialPolicy *p) const throw (std::logic_error) |
Protected Attributes | |
ActionSet | allActions |
QueryGenerator * | clingo |
unsigned int | max_n |
Definition at line 14 of file Reasoner.h.
actasp::Reasoner::Reasoner | ( | QueryGenerator * | actualReasoner, |
unsigned int | max_n, | ||
const ActionSet & | allActions | ||
) |
Definition at line 22 of file Reasoner.cpp.
virtual actasp::Reasoner::~Reasoner | ( | ) | [inline, virtual] |
Definition at line 44 of file Reasoner.h.
ActionSet actasp::Reasoner::availableActions | ( | ) | const throw () [virtual] |
Implements actasp::AspKR.
Reimplemented in actasp::FilteringReasoner.
Definition at line 25 of file Reasoner.cpp.
std::vector< AnswerSet > actasp::Reasoner::computeAllPlans | ( | const std::vector< actasp::AspRule > & | goal, |
double | suboptimality | ||
) | const throw (std::logic_error) [virtual] |
Implements actasp::MultiPlanner.
Reimplemented in actasp::FilteringReasoner.
Definition at line 138 of file Reasoner.cpp.
AnswerSet actasp::Reasoner::computeOptimalPlan | ( | const std::vector< actasp::AspRule > & | goal, |
bool | filterActions, | ||
double | suboptimality, | ||
bool | minimum | ||
) | const throw (std::logic_error) |
Definition at line 203 of file Reasoner.cpp.
AnswerSet actasp::Reasoner::computePlan | ( | const std::vector< actasp::AspRule > & | goal | ) | const throw (std::logic_error) [virtual] |
Implements actasp::Planner.
Reimplemented in actasp::FilteringReasoner.
Definition at line 100 of file Reasoner.cpp.
PartialPolicy * actasp::Reasoner::computePolicy | ( | const std::vector< actasp::AspRule > & | goal, |
double | suboptimality | ||
) | const throw (std::logic_error) [virtual] |
Implements actasp::MultiPlanner.
Reimplemented in actasp::FilteringReasoner.
Definition at line 258 of file Reasoner.cpp.
void actasp::Reasoner::computePolicyHelper | ( | const std::vector< actasp::AspRule > & | goal, |
double | suboptimality, | ||
PartialPolicy * | p | ||
) | const throw (std::logic_error) [protected] |
Definition at line 266 of file Reasoner.cpp.
AnswerSet actasp::Reasoner::currentStateQuery | ( | const std::vector< actasp::AspRule > & | query | ) | const throw () [virtual] |
Implements actasp::AspKR.
Reimplemented in actasp::FilteringReasoner.
Definition at line 38 of file Reasoner.cpp.
bool actasp::Reasoner::isPlanValid | ( | const AnswerSet & | plan, |
const std::vector< actasp::AspRule > & | goal | ||
) | const throw () [virtual] |
Implements actasp::AspKR.
Reimplemented in actasp::FilteringReasoner.
Definition at line 87 of file Reasoner.cpp.
std::list< std::list< AspAtom > > actasp::Reasoner::query | ( | const std::string & | queryString, |
unsigned int | timestep | ||
) | const throw () [virtual] |
Implements actasp::AspKR.
Reimplemented in actasp::FilteringReasoner.
Definition at line 343 of file Reasoner.cpp.
void actasp::Reasoner::resetCurrentState | ( | ) | throw () [virtual] |
Implements actasp::AspKR.
Reimplemented in actasp::FilteringReasoner.
Definition at line 92 of file Reasoner.cpp.
void actasp::Reasoner::setCurrentState | ( | const std::set< actasp::AspFluent > & | newState | ) | throw () |
Definition at line 96 of file Reasoner.cpp.
void actasp::Reasoner::setMaxTimeStep | ( | unsigned int | max_n | ) | throw () [inline] |
Definition at line 40 of file Reasoner.h.
bool actasp::Reasoner::updateFluents | ( | const std::vector< actasp::AspFluent > & | observations | ) | throw () [virtual] |
Implements actasp::AspKR.
Reimplemented in actasp::FilteringReasoner.
Definition at line 59 of file Reasoner.cpp.
ActionSet actasp::Reasoner::allActions [protected] |
Definition at line 49 of file Reasoner.h.
QueryGenerator* actasp::Reasoner::clingo [protected] |
Reimplemented in actasp::FilteringReasoner.
Definition at line 47 of file Reasoner.h.
unsigned int actasp::Reasoner::max_n [protected] |
Definition at line 48 of file Reasoner.h.