dlvhex  2.5.0
PreparedResults Class Reference

Results that are not streamed but provided to be incrementally requested. More...

#include <include/dlvhex2/ASPSolverManager.h>

Inheritance diagram for PreparedResults:
Collaboration diagram for PreparedResults:

Public Types

typedef std::list< AnswerSet::PtrStorage

Public Member Functions

 PreparedResults (const Storage &storage)
 Constructor.
 PreparedResults ()
 Constructor.
virtual ~PreparedResults ()
 Destructor.
void add (AnswerSet::Ptr as)
 Add further result (this must be done before getNextAnswerSet() has been called the first time).
virtual AnswerSet::Ptr getNextAnswerSet ()
 Retrieves the next answer set.

Protected Attributes

Storage answersets
 Answer set container.
bool resetCurrent
 True to indicate that answer set enumeration will restart.
Storage::const_iterator current
 Points to the next answer set to return.

Detailed Description

Results that are not streamed but provided to be incrementally requested.

Definition at line 191 of file ASPSolverManager.h.


Member Typedef Documentation

Definition at line 195 of file ASPSolverManager.h.


Constructor & Destructor Documentation

Constructor.

Parameters:
storageContainer to add the answer sets to.

Definition at line 118 of file ASPSolverManager.cpp.

Constructor.

Definition at line 111 of file ASPSolverManager.cpp.

Destructor.

Definition at line 126 of file ASPSolverManager.cpp.


Member Function Documentation

Add further result (this must be done before getNextAnswerSet() has been called the first time).

Parameters:
asAdds an answer set to the storage, see PreparedResults::PreparedResults(const Storage& storage).

Definition at line 133 of file ASPSolverManager.cpp.

References answersets, current, and resetCurrent.

Referenced by WellfoundedModelGenerator::generateNextModel(), and PlainModelGenerator::generateNextModel().

Retrieves the next answer set.

Returns:
Next answer set.

Implements ASPSolverManager::Results.

Definition at line 147 of file ASPSolverManager.cpp.

References answersets, current, and resetCurrent.


Field Documentation

Answer set container.

Definition at line 215 of file ASPSolverManager.h.

Referenced by add(), and getNextAnswerSet().

Storage::const_iterator PreparedResults::current [protected]

Points to the next answer set to return.

Definition at line 219 of file ASPSolverManager.h.

Referenced by add(), and getNextAnswerSet().

True to indicate that answer set enumeration will restart.

Definition at line 217 of file ASPSolverManager.h.

Referenced by add(), and getNextAnswerSet().


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