1 #ifndef __RELATIONINSTANCE_H__ 2 #define __RELATIONINSTANCE_H__ 6 #include "Expression.h" 24 explicit Fact(std::string _module, std::string a_relation, std::vector<Value *> *a_params,
bool _t =
true,
bool _f =
false);
34 explicit Fact(std::string _module, std::string a_relation,
Expression *a_params,
bool _t =
true,
bool _f =
false);
50 std::string
print(
bool type =
true)
const;
90 void set_set(std::vector<Value *> *_v);
95 std::vector<Value *> *
get_set();
121 void valuate_fact(std::map<std::string, Value*> binding);
138 std::string print_params(
bool type =
true)
const;
141 std::string relation;
142 std::vector<Value *> *params;
145 bool delete_bel_params;
146 std::vector<Value *> *
set;
150 bool operator<(
const Fact &a,
const Fact &b);
std::string get_relation() const
getter for fact relation name
Definition: Fact.cc:179
bool is_bel_free_query()
setter for info whether BEL params should be deleted on destruction
Definition: Fact.cc:296
type
Enumeration type for four-valued logic.
Definition: Types.h:45
class that implements a fact
Definition: Fact.h:14
std::vector< std::string > get_variable_names() const
getter for names of variables
Definition: Fact.cc:265
void set_module(std::string _m)
setter for fact module name
Definition: Fact.cc:175
Definition: Expression.h:10
std::string print(bool type=true) const
returns string with domain information
Definition: Fact.cc:115
bool is_set_query()
ask for being a subset query
Definition: Fact.cc:232
bool operator==(Fact &r)
overloaded operator used to comparing facts
Definition: Fact.cc:72
Fact(std::string _module, std::string a_relation, std::vector< Value *> *a_params, bool _t=true, bool _f=false)
constructor that sets fact data
Definition: Fact.cc:12
void should_delete_bel_params(bool value)
setter for info whether BEL params should be deleted on destruction
Definition: Fact.cc:286
Definition: Application.cc:37
std::string get_module() const
getter for fact module name
Definition: Fact.cc:171
void set_bel_free_query(bool value)
setter for info whether BEL params should be deleted on destruction
Definition: Fact.cc:291
Inter4ql::logic_type::type get_value() const
getter for fact logical value
Definition: Fact.cc:159
void set_set(std::vector< Value *> *_v)
setter for set of types ('in {...}' statement)
Definition: Fact.cc:183
void valuate_fact(std::map< std::string, Value *> binding)
exchanges variables into values
Definition: Fact.cc:281
std::vector< Value * > * get_set()
getter for set of types ('in {...}' statement)
Definition: Fact.cc:187
std::vector< Value * > * get_params() const
getter for fact parameters
Definition: Fact.cc:167
void set_value(logic_type::type _v)
setter for fact logical value
Definition: Fact.cc:155
std::string get_set_string()
Definition: Fact.cc:191
Expression * get_bel_params() const
getter for BEL body
Definition: Fact.cc:163
~Fact()
destructor
Definition: Fact.cc:52