dlvhex
2.5.0
|
Results that are not streamed but provided to be incrementally requested. More...
#include <include/dlvhex2/ASPSolverManager.h>
Public Types | |
typedef std::list< AnswerSet::Ptr > | Storage |
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. |
Results that are not streamed but provided to be incrementally requested.
Definition at line 191 of file ASPSolverManager.h.
typedef std::list<AnswerSet::Ptr> PreparedResults::Storage |
Definition at line 195 of file ASPSolverManager.h.
PreparedResults::PreparedResults | ( | const Storage & | storage | ) |
Constructor.
storage | Container to add the answer sets to. |
Definition at line 118 of file ASPSolverManager.cpp.
Constructor.
Definition at line 111 of file ASPSolverManager.cpp.
PreparedResults::~PreparedResults | ( | ) | [virtual] |
Destructor.
Definition at line 126 of file ASPSolverManager.cpp.
void PreparedResults::add | ( | AnswerSet::Ptr | as | ) |
Add further result (this must be done before getNextAnswerSet() has been called the first time).
as | Adds 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().
AnswerSet::Ptr PreparedResults::getNextAnswerSet | ( | ) | [virtual] |
Retrieves the next answer set.
Implements ASPSolverManager::Results.
Definition at line 147 of file ASPSolverManager.cpp.
References answersets, current, and resetCurrent.
Storage PreparedResults::answersets [protected] |
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().
bool PreparedResults::resetCurrent [protected] |
True to indicate that answer set enumeration will restart.
Definition at line 217 of file ASPSolverManager.h.
Referenced by add(), and getNextAnswerSet().