// SimpleDatasetMerger.h #ifndef dset__SimpleDatasetMerger_H #define dset__SimpleDatasetMerger_H // David Adams // April 2004 // // This dataset merger inserts the datasets into a simple // compound dataset. // // All compound datasets returned as results are stored in // the current default dataset repository. #include "dataset_util/Text.h" #include "dataset_split/DatasetMerger.h" namespace dset { class SimpleCompoundDataset; class SimpleDatasetMerger : public DatasetMerger { private: //data SimpleCompoundDataset* m_pdst; SimpleCompoundDataset* m_pdst_last; bool m_open; public: // constructors and destructor. // Constructor. SimpleDatasetMerger(); // Destructor. ~SimpleDatasetMerger(); public: // inherited functions // Validity. bool is_valid() const; // Closed. bool is_open() const; // Append a dataset. int append(const Dataset& dst); // Return the result. // This should not be blocking--if the result will require a long // time to calculate, then this method should quickly return a // (consistent) partial result. DatasetMergeResult result(); // Close. int close(); // Output stream. std::ostream& ostr(std::ostream& str) const; }; } // end namespace dset #endif