A context object for rewriting.
More...
#include <ast.hh>
A context object for rewriting.
◆ RewriteContext()
Clingo::AST::RewriteContext::RewriteContext |
( |
Library const & |
lib | ) |
|
|
inlineexplicit |
Construct the context.
- Parameters
-
lib | the library to store symbols |
◆ add_param()
void Clingo::AST::RewriteContext::add_param |
( |
std::string_view |
name | ) |
|
|
inline |
Protect a parameter from simplification.
Parameters from const directives and program directives should be projected before rewriting.
- Parameters
-
name | the name of the parameter to protect |
◆ add_theory()
void Clingo::AST::RewriteContext::add_theory |
( |
Node const & |
stm | ) |
|
|
inline |
Add a theory node that is used to rewrite theory atoms in statements.
- Parameters
-
◆ project_anonymous() [1/2]
auto Clingo::AST::RewriteContext::project_anonymous |
( |
| ) |
-> bool |
|
inline |
Check whether projection in negative literals is enabled.
- Returns
- whether projection is enabled
◆ project_anonymous() [2/2]
void Clingo::AST::RewriteContext::project_anonymous |
( |
bool |
value | ) |
|
|
inline |
Enable projection of anonymous variables in negated literals.
This exists mainly for backward compatibility with clingo 5. Program should use the projection *
instead.
- Parameters
-
◆ project_mode() [1/2]
Get the projection mode.
- Returns
- the projection mode
◆ project_mode() [2/2]
void Clingo::AST::RewriteContext::project_mode |
( |
ProjectionMode |
value | ) |
|
|
inline |
Set the projection mode.
- Parameters
-
The documentation for this class was generated from the following file: