clingo
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups
Public Member Functions | Static Public Attributes | List of all members
Clasp::Asp::RuleState Class Reference

Used during rule simplification. More...

#include <logic_program_types.h>

Collaboration diagram for Clasp::Asp::RuleState:
Collaboration graph

Public Member Functions

 RuleState ()
 
bool inHead (PrgEdge t) const
 Does t.node() appear in the head of the active rule? More...
 
bool inBody (Literal p) const
 Does p appear in the body of the active rule? More...
 
bool isSet (Var v, uint8 f) const
 
void addToHead (Var v)
 Mark v as a head of the active rule. More...
 
void addToHead (PrgEdge t)
 
void addToBody (Literal p)
 Mark p as a literal contained in the active rule. More...
 
void set (Var v, uint8 f)
 
void clear (Var v, uint8 f)
 
void clear (Var v)
 
void clearHead (PrgEdge t)
 
void clearBody (Literal p)
 
void clearAll ()
 
bool allMarked (const VarVec &vec, uint8 f) const
 

Static Public Attributes

static const uint8 pos_flag = 0x1u
 
static const uint8 neg_flag = 0x2u
 
static const uint8 head_flag = 0x1u << 2u
 
static const uint8 choice_flag = 0x1u << 3u
 
static const uint8 disj_flag = 0x1u << 4u
 
static const uint8 any_flag = 0xFFu
 

Detailed Description

Used during rule simplification.

Constructor & Destructor Documentation

Clasp::Asp::RuleState::RuleState ( )
inline

Member Function Documentation

void Clasp::Asp::RuleState::addToBody ( Literal  p)
inline

Mark p as a literal contained in the active rule.

Here is the call graph for this function:

void Clasp::Asp::RuleState::addToHead ( Var  v)
inline

Mark v as a head of the active rule.

Here is the call graph for this function:

void Clasp::Asp::RuleState::addToHead ( PrgEdge  t)
inline

Here is the call graph for this function:

bool Clasp::Asp::RuleState::allMarked ( const VarVec vec,
uint8  f 
) const
inline

Here is the call graph for this function:

void Clasp::Asp::RuleState::clear ( Var  v,
uint8  f 
)
inline
void Clasp::Asp::RuleState::clear ( Var  v)
inline

Here is the call graph for this function:

void Clasp::Asp::RuleState::clearAll ( )
inline
void Clasp::Asp::RuleState::clearBody ( Literal  p)
inline

Here is the call graph for this function:

void Clasp::Asp::RuleState::clearHead ( PrgEdge  t)
inline

Here is the call graph for this function:

bool Clasp::Asp::RuleState::inBody ( Literal  p) const
inline

Does p appear in the body of the active rule?

Here is the call graph for this function:

bool Clasp::Asp::RuleState::inHead ( PrgEdge  t) const
inline

Does t.node() appear in the head of the active rule?

Here is the call graph for this function:

bool Clasp::Asp::RuleState::isSet ( Var  v,
uint8  f 
) const
inline
void Clasp::Asp::RuleState::set ( Var  v,
uint8  f 
)
inline

Member Data Documentation

const uint8 Clasp::Asp::RuleState::any_flag = 0xFFu
static
const uint8 Clasp::Asp::RuleState::choice_flag = 0x1u << 3u
static
const uint8 Clasp::Asp::RuleState::disj_flag = 0x1u << 4u
static
const uint8 Clasp::Asp::RuleState::head_flag = 0x1u << 2u
static
const uint8 Clasp::Asp::RuleState::neg_flag = 0x2u
static
const uint8 Clasp::Asp::RuleState::pos_flag = 0x1u
static

The documentation for this class was generated from the following file: