This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "csv.h" | |
inline | |
std::vector<std::string> split_csv_line(const std::string& str) { | |
char seperator = ','; | |
std::vector<std::string> results; | |
std::string::size_type start = str.find_first_not_of(' '); | |
std::string::size_type sep = str.find(seperator); | |
while (sep != std::string::npos) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
inline | |
std::vector<std::string> getFilesList(std::string dirpath){ | |
DIR *dir = opendir(dirpath.c_str()); | |
if (dir == NULL) | |
{ | |
std::cout << "opendir error" << std::endl; | |
} | |
std::vector<std::string> all_path; | |
struct dirent *entry; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class ExecuteOnExit{ | |
public: | |
ExecuteOnExit() = default; | |
// movable | |
ExecuteOnExit(ExecuteOnExit&& ) = default; | |
ExecuteOnExit& operator=(ExecuteOnExit&& ) = default; | |
// non copyable | |
ExecuteOnExit(const ExecuteOnExit& e) = delete; |
NewerOlder