23 #ifndef PLUGINS_PDDL_AST_H_
24 #define PLUGINS_PDDL_AST_H_
26 #include <boost/fusion/include/adapt_struct.hpp>
27 #include <boost/fusion/include/std_pair.hpp>
28 #include <boost/spirit/include/qi.hpp>
32 namespace pddl_parser {
33 namespace qi = boost::spirit::qi;
34 namespace ascii = boost::spirit::ascii;
36 typedef std::pair<std::string, std::string> pair_type;
37 typedef std::vector<pair_type> pairs_type;
39 typedef std::vector<std::string> type_list;
40 typedef std::pair<type_list, std::string> pair_multi_const;
41 typedef std::vector<pair_multi_const> pairs_multi_consts;
43 typedef std::pair<std::string, std::string> string_pair_type;
44 typedef std::vector<string_pair_type> string_pairs_type;
45 typedef std::pair<std::string, string_pairs_type> predicate_type;
47 using Atom = std::string;
51 using Expression = boost::variant<Atom, Predicate>;
A structured representation of a PDDL action.
Expression cond_breakup
Used by the STN generator to determine conditional break points in the STN.
string_pairs_type action_params
A typed list of action parameters.
std::string name
The name of the action.
Expression effect
The effect of an action.
Expression temp_breakup
Used by the STN generator to determine temporal break points in the STN.
int duration
The action duration in temporal domains.
Expression precondition
The precondition of an action.
A structured representation of a PDDL domain.
std::vector< Action > actions
A list of actions defined in the domain.
std::string name
The name of the domain.
pairs_multi_consts constants
A typed list of constants defined in the domain.
pairs_type types
A list of types with their super types.
std::vector< predicate_type > predicates
A list of predicate names in the domain, including the types of their arguments.
std::vector< std::string > requirements
A list of PDDL features required by the domain.
A PDDL formula (either part of a precondition or an effect(.
std::vector< Expression > arguments
The arguments of the predicate or the subformulae of the compound formula.
A structured representation of a PDDL problem.
std::string name
The name of the problem.
pairs_multi_consts objects
A typed list of objects in the domain.
Expression goal
The goal of the problem.
std::vector< Expression > init
A list of facts that are initially true.
std::string domain_name
The name of the domain this problem belongs to.