dlvhex  2.5.0
GenuineGuessAndCheckModelGeneratorFactory Class Reference

Factory for the GenuineGuessAndCheckModelGenerator. More...

#include <include/dlvhex2/GenuineGuessAndCheckModelGenerator.h>

Inheritance diagram for GenuineGuessAndCheckModelGeneratorFactory:
Collaboration diagram for GenuineGuessAndCheckModelGeneratorFactory:

Public Types

typedef
ComponentGraph::ComponentInfo 
ComponentInfo

Public Member Functions

 GenuineGuessAndCheckModelGeneratorFactory (ProgramCtx &ctx, const ComponentInfo &ci, ASPSolverManager::SoftwareConfigurationPtr externalEvalConfig)
 Constructor.
virtual ~GenuineGuessAndCheckModelGeneratorFactory ()
 Destructor.
virtual void addInconsistencyCauseFromSuccessor (const Nogood *cause)
 Informs the model generator about an inconsistency cause in successor units.
virtual ModelGeneratorPtr createModelGenerator (InterpretationConstPtr input)
 Instantiates a model generator for the component.
virtual std::ostream & print (std::ostream &o) const
 Prints information about the model generator for debugging purposes.
virtual std::ostream & print (std::ostream &o, bool verbose) const
 Prints information about the model generator for debugging purposes.

Protected Attributes

ASPSolverManager::SoftwareConfigurationPtr externalEvalConfig
 Defines the solver to be used for external evaluation.
ProgramCtxctx
 ProgramCtx.
ComponentInfo ci
 ComponentInfo of the component to be solved by the model generators instantiated by this factory.
std::vector< IDouterEatoms
 Outer external atoms of the component.
std::vector< std::pair< Nogood,
int > > 
succNogoods
 Nogoods learned from successor units.

Friends

class GenuineGuessAndCheckModelGenerator

Detailed Description


Member Typedef Documentation


Constructor & Destructor Documentation


Member Function Documentation

Informs the model generator about an inconsistency cause in successor units.

Parameters:
causePointer to a nogood which, if violated and no new atoms are introduced, always makes a successor unit inconsistent. Note: Due to nonmonotonicity the introduction of new atoms might invalidate this cause!

Reimplemented from ModelGeneratorFactoryBase< Interpretation >.

Definition at line 111 of file GenuineGuessAndCheckModelGenerator.cpp.

References ctx, DBGLOG, Nogood::getStringRepresentation(), ProgramCtx::registry(), and succNogoods.

Instantiates a model generator for the component.

Parameters:
inputThe facts to be added before solving.
Returns:
Model generator.

Implements ModelGeneratorFactoryBase< Interpretation >.

Definition at line 121 of file GenuineGuessAndCheckModelGenerator.cpp.

References GenuineGuessAndCheckModelGenerator.

std::ostream & GenuineGuessAndCheckModelGeneratorFactory::print ( std::ostream &  o) const [virtual]

Prints information about the model generator for debugging purposes.

Parameters:
oStream to print to.

Reimplemented from ModelGeneratorFactoryBase< Interpretation >.

Definition at line 128 of file GenuineGuessAndCheckModelGenerator.cpp.

Referenced by GenuineGuessAndCheckModelGeneratorFactory().

std::ostream & GenuineGuessAndCheckModelGeneratorFactory::print ( std::ostream &  o,
bool  verbose 
) const [virtual]

Prints information about the model generator for debugging purposes.

Parameters:
oStream to print to.
verboseProvides more detailed output if true.

Definition at line 135 of file GenuineGuessAndCheckModelGenerator.cpp.

References ctx, FLPModelGeneratorFactoryBase::gidb, FLPModelGeneratorFactoryBase::idb, FLPModelGeneratorFactoryBase::innerEatoms, outerEatoms, Printer::printmany(), ProgramCtx::registry(), FLPModelGeneratorFactoryBase::xidb, FLPModelGeneratorFactoryBase::xidbflpbody, and FLPModelGeneratorFactoryBase::xidbflphead.


Friends And Related Function Documentation

friend class GenuineGuessAndCheckModelGenerator [friend]

Definition at line 350 of file GenuineGuessAndCheckModelGenerator.h.

Referenced by createModelGenerator().


Field Documentation

ComponentInfo of the component to be solved by the model generators instantiated by this factory.

Definition at line 360 of file GenuineGuessAndCheckModelGenerator.h.

Referenced by GenuineGuessAndCheckModelGenerator::GenuineGuessAndCheckModelGenerator(), and GenuineGuessAndCheckModelGenerator::initializeExplanationAtoms().

Defines the solver to be used for external evaluation.

Definition at line 356 of file GenuineGuessAndCheckModelGenerator.h.


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