|
static std::string | ConvertIntegerToString (int i) |
| converts integer to std::string More...
|
|
static std::string | ConvertFloatToString (float f) |
| converts float to std::string More...
|
|
static std::string | ConvertDoubleToString (double d) |
| converts double to std::string More...
|
|
static std::string | ConvertBoolToString (bool b) |
| converts boolean to std::string More...
|
|
static bool | ConvertStringToBoolean (std::string inputString) |
| converts std::string to boolean More...
|
|
static int | ConvertStringToInt (std::string inputString) |
| converts std::string to integer More...
|
|
static float | ConvertStringToFloat (std::string inputString) |
| converts std::string to float More...
|
|
static double | ConvertStringToDouble (std::string inputString) |
| converts std::string to double More...
|
|
static std::string | ExtractFileName (std::string inputString) |
| extracts file name from a path string, thus removing all until the last slash Inherently uses position of last slash, so works only for Unix path names More...
|
|
static std::string | ExtractFileNameRoot (std::string inputString) |
| extracts the root filename for a file, so removes path and extension e.g., if a certain path to a file is "/home/UserName/Filedir/SomeFileName_XXXX.txt", this function extracts "SomeFileName_XXXX" More...
|
|
static long int | GetIndexFromFileName (std::string inputString, bool useUnderscoreAsSeparator=true) |
| gets the index from a string We often encounter file names of type "SomeName_XXXX.pnm" where "XXXX" represents a number. This function extracts that number from the file name More...
|
|
static std::string | FindFileNameInListFromIndex (int myIndex, std::vector< std::string > fileList) |
|
static int | FindFirstDot (std::string inputString) |
| finds the position of the first dot in a string More...
|
|
static int | FindLastSlash (std::string inputString) |
| finds the position of the last slash in a string that represents a path Uses macro WIN32 (sometimes it can be _WIN32, CYGWIN32, or _MSC_VER) to determine if slash (unix) or backslash (windows) is to be used. More...
|
|
static int | FindLastUnderscore (std::string inputString) |
|
static int | FindLastMinus (std::string inputString) |
|
static std::string | ExtractFileExtension (std::string inputString, bool includeDot=true) |
| extracts the extension from a filename for a file e.g., if a certain path to a file is "/home/UserName/Filedir/SomeFileName.txt", this function extracts if includeDot true ".txt" and "txt" otherwise More...
|
|
static std::string | ExtractFilePrefix (std::string inputString, bool useUnderscoreAsSeparator=true) |
| extracts the prefix filename for a file, so removes path, extension and file index e.g., if a certain path to a file is "/home/UserName/Filedir/SomeFileName_XXXX.txt", this function extracts "SomeFileName" More...
|
|
static std::string | ExtractPathOfFileName (std::string inputString) |
| extracts the path for a file e.g., if a certain path to a file is "/home/UserName/Filedir/SomeFileName.txt", this function extracts "/home/UserName/Filedir" More...
|
|
static std::string | ExtractFileNameFromPathPlusFileName (std::string inputString) |
| extracts the path for a file e.g., if a certain path to a file is "/home/UserName/Filedir/SomeFileName.txt", this function extracts "SomeFileName.txt" More...
|
|
static std::string | GoOneLevelUpInPathName (std::string inputString) |
|
static std::string | ConstructPathAndFileName (std::string path, std::string preFix, int indexNr, std::string extension) |
| synthesizes a file name from a prefix, a counter and an extension More...
|
|
static std::string | ConstructPathAndFileName (std::string path, std::string preFix, int indexNr1, int indexNr2, std::string extension) |
| composes a file name from a prefix, two counters and an extension More...
|
|
static bool | IsDigit (std::string s, long int &myDigit) |
|
static void | SplitStringInIntegers (const std::string &s, char c, std::vector< int > &v) |
| Splits a delimited string in integers http://www.blog.highub.com/c-plus-plus/c-parse-split-delimited-string/ http://www.cplusplus.com/forum/general/13135/.
|
|
static std::string | GetCurrentTimeAsStringID () |
| creates a string based on current time to build experiment output folders or files using this string
|
|
A class with some handy functions to manipulate STL strings.