dlvhex  2.5.0
evalheur Namespace Reference

Data Structures

struct  BuildCommand
 Defines which components to collapse and which components to share among units. More...

Typedefs

typedef ComponentGraph::Component Component
typedef
ComponentGraph::ComponentIterator 
ComponentIterator
typedef std::vector< ComponentComponentContainer
typedef std::set< ComponentComponentSet
typedef std::vector< BuildCommandCommandVector

Functions

template<typename ComponentGraphIntOrRest , typename Sequence >
void topologicalSortComponents (const ComponentGraphIntOrRest &cg, Sequence &out)
 Topological sort of all components in graph into vector.
void executeBuildCommands (const CommandVector &commands, EvalGraphBuilder &builder)
 Executes the commands in a vector.

Typedef Documentation

typedef std::vector<BuildCommand> evalheur::CommandVector

Definition at line 68 of file EvalHeuristicShared.h.

Definition at line 50 of file EvalHeuristicShared.h.

typedef std::set<Component> evalheur::ComponentSet

Definition at line 51 of file EvalHeuristicShared.h.


Function Documentation

void evalheur::executeBuildCommands ( const CommandVector &  commands,
EvalGraphBuilder builder 
)

Executes the commands in a vector.

Parameters:
commandsCommands to execute, see BuildCommand.
builderEvalGraphBuilder.

Definition at line 45 of file EvalHeuristicShared.cpp.

References evalheur::BuildCommand::collapse, EvalGraphBuilder::createEvalUnit(), EvalGraphBuilder::getComponentGraph(), LOG, printvector(), and evalheur::BuildCommand::share.

Referenced by EvalHeuristicFromFile::build().

template<typename ComponentGraphIntOrRest , typename Sequence >
void evalheur::topologicalSortComponents ( const ComponentGraphIntOrRest &  cg,
Sequence &  out 
)

Topological sort of all components in graph into vector.

Parameters:
cgEither internal component graph or component graph rest.
outContainer for the result.

Definition at line 77 of file EvalHeuristicShared.h.

Referenced by EvalHeuristicEasy::build(), EvalHeuristicOldDlvhex::build(), EvalHeuristicTrivial::build(), EvalHeuristicFromFile::build(), EvalHeuristicGreedy::build(), and DLVHEX_NAMESPACE_BEGIN::EvalHeuristicFromHEXSourcecode::build().