MCPcopy Create free account
hub / github.com/ObEngine/ObEngine / split

Function split

extlibs/elzip/src/elzip_fs_fallback.cpp:38–48  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

36}
37
38std::vector<std::string> split(const std::string &str, const std::string &delimiters) {
39 std::vector<std::string> tokens;
40 std::string::size_type lastPos = str.find_first_not_of(delimiters, 0);
41 std::string::size_type pos = str.find_first_of(delimiters, lastPos);
42 while (std::string::npos != pos || std::string::npos != lastPos) {
43 tokens.push_back(str.substr(lastPos, pos - lastPos));
44 lastPos = str.find_first_not_of(delimiters, pos);
45 pos = str.find_first_of(delimiters, lastPos);
46 }
47 return tokens;
48}
49
50std::vector<std::string> listDirInDir(std::string path) {
51 tinydir_dir dir;

Callers 1

extractZipFunction · 0.70

Calls 2

substrMethod · 0.80
push_backMethod · 0.45

Tested by

no test coverage detected