|
DP3
|
Useful string manipulation methods and classes. More...
Classes | |
| class | Compare |
Functor to compare two strings. Strings can be compared case sensitive (NORMAL) and case insensitive (NOCASE). More... | |
Functions | |
| std::vector< std::string > | tokenize (const std::string &str, const std::string &delims) |
Useful string manipulation methods and classes.
| std::vector<std::string> dp3::common::stringtools::tokenize | ( | const std::string & | str, |
| const std::string & | delims | ||
| ) |
Tokenize the string str using any character in delim as a separation character. The result does not contain empty strings; consecutive delimiter occurrences count as a single delimiter. Any delimiter occurrences at the beginning or end of str are ignored.
For example:
would yield the following vector of strings:
/// tokens[0] = "aa" /// tokens[1] = "bb" ///