clingo
|
An array of literals that can be shared between threads. More...
#include <clause.h>
Public Member Functions | |
const Literal * | begin () const |
Returns a pointer to the beginning of the literal array. More... | |
const Literal * | end () const |
Returns a pointer to the end of the literal array. More... | |
uint32 | size () const |
Returns the number of literals in the array. More... | |
ConstraintType | type () const |
Returns the type of constraint from which the literals originated. More... | |
uint32 | simplify (Solver &s) |
Simplifies the literals w.r.t to the assignment in s. More... | |
void | release () |
SharedLiterals * | share () |
bool | unique () const |
uint32 | refCount () const |
Static Public Member Functions | |
static SharedLiterals * | newShareable (const LitVec &lits, ConstraintType t, uint32 numRefs=1) |
Creates a shareable (ref-counted) object containing the literals in lits. More... | |
static SharedLiterals * | newShareable (const Literal *lits, uint32 size, ConstraintType t, uint32 numRefs=1) |
An array of literals that can be shared between threads.
|
inline |
Returns a pointer to the beginning of the literal array.
|
inline |
Returns a pointer to the end of the literal array.
|
inlinestatic |
Creates a shareable (ref-counted) object containing the literals in lits.
|
static |
|
inline |
void Clasp::SharedLiterals::release | ( | ) |
SharedLiterals * Clasp::SharedLiterals::share | ( | ) |
uint32 Clasp::SharedLiterals::simplify | ( | Solver & | s | ) |
Simplifies the literals w.r.t to the assignment in s.
Returns the number of non-false literals in this object or 0 if the array contains a true literal.
|
inline |
Returns the number of literals in the array.
|
inline |
Returns the type of constraint from which the literals originated.
|
inline |