Observer interface to inspect the current ground program.
More...
#include <observe.hh>
|
| Observer ()=default |
| The default constructor.
|
|
| Observer (Observer &&other)=delete |
| Disable move and copy operations.
|
|
virtual | ~Observer ()=default |
| The default destructor.
|
|
void | init_program (bool incremental) |
| Callback for the beginning of the program.
|
|
void | begin_step () |
| Callback for the beginning of a step.
|
|
void | end_step (Base base) |
| Callback for the end of a step.
|
|
void | rule (ProgramAtomSpan head, ProgramLiteralSpan body, bool choice) |
| Callback for a rule.
|
|
void | weight_rule (ProgramAtomSpan head, Weight lower, WeightedLiteralSpan body, bool choice) |
| Callback for a weight rule.
|
|
void | minimize (WeightedLiteralSpan literals, Weight priority) |
| Callback for a minimize constraint.
|
|
void | project (ProgramAtomSpan atoms) |
| Callback for a projection directive.
|
|
void | external (ProgramAtom atom, ExternalType type) |
| Callback for an external statement.
|
|
void | assume (ProgramLiteralSpan literals) |
| Callback for an assumption directive.
|
|
void | heuristic (ProgramAtom atom, HeuristicType type, int bias, unsigned priority, ProgramLiteralSpan condition) |
|
void | edge (int node_u, int node_v, ProgramLiteralSpan condition) |
| Callback for an edge statement.
|
|
Observer interface to inspect the current ground program.
◆ assume()
Callback for an assumption directive.
- Parameters
-
literals | the literals to assume |
◆ edge()
Callback for an edge statement.
- Parameters
-
node_u | the first node of the edge |
node_v | the second node of the edge |
condition | the condition under which the edge is active |
◆ external()
Callback for an external statement.
- Parameters
-
atom | the external atom |
type | the type of the external statement |
◆ heuristic()
- Parameters
-
atom | the atom to apply the heuristic to |
type | the type of the heuristic modification |
bias | the bias of the heuristic modification |
priority | the priority of the heuristic modification |
condition | the condition when to apply the heuristic modification |
◆ init_program()
void Clingo::Observer::init_program |
( |
bool |
incremental | ) |
|
|
inline |
Callback for the beginning of the program.
- Parameters
-
incremental | whether the program is incremental |
◆ minimize()
Callback for a minimize constraint.
- Parameters
-
literals | the weighted literals to minimize |
priority | the priority of the minimize constraint |
◆ project()
Callback for a projection directive.
- Parameters
-
atoms | the atoms to project on |
◆ rule()
Callback for a rule.
- Parameters
-
head | the head of the rule |
body | the body of the rule |
choice | whether the head is a choice or a disjunction |
◆ weight_rule()
Callback for a weight rule.
- Parameters
-
head | the head of the weight rule |
lower | the lower bound of the weight rule |
body | the weighted body of the weight rule |
choice | whether the head is a choice or a disjunction |
The documentation for this class was generated from the following file: