6 #ifndef _INCLUDE_TESTBENCH_FileDataLoader_H_
7 #define _INCLUDE_TESTBENCH_FileDataLoader_H_
12 using namespace INTELLI;
43 void spilt(
const std::string s,
const std::string &c, vector<std::string> &v) {
44 std::string::size_type pos1, pos2;
47 while (std::string::npos != pos2) {
48 v.push_back(s.substr(pos1, pos2 - pos1));
50 pos1 = pos2 + c.size();
51 pos2 = s.find(c, pos1);
53 if (pos1 != s.length())
54 v.push_back(s.substr(pos1));
63 std::vector<TrackTuplePtr> loadDataFromCsv(std::string fname,
64 std::string separator =
",",
65 std::string newLine =
"\n");
68 vector<TrackTuplePtr> sTuple, rTuple;
91 virtual vector<TrackTuplePtr> getTupleVectorS();
97 virtual vector<TrackTuplePtr> getTupleVectorR();
113 #define newFileDataLoader std::make_shared<OoOJoin::FileDataLoader>
The abstract class of dataloader.
Definition: AbstractDataLoader.h:39
The dataloader which loads data from external csv file.
Definition: FileDataLoader.h:40
virtual bool setModConfig(ConfigMapPtr cfg)
Set the modification config map related to this loader.
Definition: FileDataLoader.h:83
std::shared_ptr< class FileDataLoader > FileDataLoaderPtr
The class to describe a shared pointer to FileDataLoader.
Definition: FileDataLoader.h:107
std::shared_ptr< ConfigMap > ConfigMapPtr
The class to describe a shared pointer to ConfigMap.
Definition: ConfigMap.hpp:356
Definition: OperatorTable.cpp:7