34 std::set<std::string> ret;
35 int prev = 0, next = 0;
36 next = s.find(delimiter,prev);
37 while(next != std::string::npos)
39 ret.insert(s.substr(prev , next - prev));
41 next = s.find(delimiter,prev);
43 ret.insert(s.substr(prev , s.size() - prev));
54 int n = s.find_last_of(
'/');
55 return s.substr(n + 1, s.size() - n - 1);
66 int n = s.find_last_of(
'/');
67 return s.substr(0, n);
The main namespace for STDR GUI XML parser.
std::string extractFilename(std::string s)
Extracts the filename from an absolute path.
std::string extractDirname(std::string s)
Extracts the directory from an absolute path. It does the same functionality as libgen's dirname but ...
std::set< std::string > explodeString(std::string s, char delimiter)
Explodes a string based on a delimiter.