Clingo
|
Object to provide access to the backend. More...
#include <solver.hh>
Public Member Functions | |
auto | program () -> Clasp::Asp::LogicProgram & |
Get the logic program. | |
auto | theory () -> Output::TheoryData & |
Get the theory. | |
auto | store () -> SymbolStore & |
The symbol store. | |
auto | add_atom (Symbol atom) -> prg_lit_t |
Add a literal for the given symbol. | |
void | close () |
Close the handle. | |
virtual | ~BackendHandle ()=default |
Destroy the handle. | |
Object to provide access to the backend.
This backend is intended to be used in the C API to extend the ground program representation.
Logically, adding a block of rules via the backend can be seen like a call to ground. In fact, ground is called with an empty part list when the handle is destroyed to run the required finalization logic (grounding currently does not involve dedicated initialization).
Note that symbols added via the backend are not added to the domains of the grounder. This has to be done using add_atom().
Add a literal for the given symbol.
Returns literals of existing symbolic atoms are introduces a new one.
atom | the symbol |
|
inline |
Close the handle.
This functions must be called before continuing to use the associated solver.
|
inline |
Get the logic program.
|
inline |
The symbol store.
|
inline |
Get the theory.