|
template<typename... Args> |
static std::string | Format (const std::string &fmt, Args &&... args) |
| Get a formatted string similar to sprintf. More...
|
|
template<typename... Args> |
static std::wstring | Format (const std::wstring &fmt, Args &&... args) |
|
static std::string | FormatV (PRINTF_FORMAT_STRING const char *fmt, va_list args) |
|
static std::wstring | FormatV (PRINTF_FORMAT_STRING const wchar_t *fmt, va_list args) |
|
static void | ToUpper (std::string &str) |
|
static void | ToUpper (std::wstring &str) |
|
static void | ToLower (std::string &str) |
|
static void | ToLower (std::wstring &str) |
|
static void | ToCapitalize (std::string &str) |
|
static void | ToCapitalize (std::wstring &str) |
|
static bool | EqualsNoCase (const std::string &str1, const std::string &str2) |
|
static bool | EqualsNoCase (const std::string &str1, const char *s2) |
|
static bool | EqualsNoCase (const char *s1, const char *s2) |
|
static int | CompareNoCase (const std::string &str1, const std::string &str2) |
|
static int | CompareNoCase (const char *s1, const char *s2) |
|
static int | ReturnDigits (const std::string &str) |
|
static std::string | Left (const std::string &str, size_t count) |
|
static std::string | Mid (const std::string &str, size_t first, size_t count=std::string::npos) |
|
static std::string | Right (const std::string &str, size_t count) |
|
static std::string & | Trim (std::string &str) |
|
static std::string & | Trim (std::string &str, const char *const chars) |
|
static std::string & | TrimLeft (std::string &str) |
|
static std::string & | TrimLeft (std::string &str, const char *const chars) |
|
static std::string & | TrimRight (std::string &str) |
|
static std::string & | TrimRight (std::string &str, const char *const chars) |
|
static std::string & | RemoveDuplicatedSpacesAndTabs (std::string &str) |
|
static int | Replace (std::string &str, char oldChar, char newChar) |
|
static int | Replace (std::string &str, const std::string &oldStr, const std::string &newStr) |
|
static int | Replace (std::wstring &str, const std::wstring &oldStr, const std::wstring &newStr) |
|
static bool | StartsWith (const std::string &str1, const std::string &str2) |
|
static bool | StartsWith (const std::string &str1, const char *s2) |
|
static bool | StartsWith (const char *s1, const char *s2) |
|
static bool | StartsWithNoCase (const std::string &str1, const std::string &str2) |
|
static bool | StartsWithNoCase (const std::string &str1, const char *s2) |
|
static bool | StartsWithNoCase (const char *s1, const char *s2) |
|
static bool | EndsWith (const std::string &str1, const std::string &str2) |
|
static bool | EndsWith (const std::string &str1, const char *s2) |
|
static bool | EndsWithNoCase (const std::string &str1, const std::string &str2) |
|
static bool | EndsWithNoCase (const std::string &str1, const char *s2) |
|
template<typename CONTAINER > |
static std::string | Join (const CONTAINER &strings, const std::string &delimiter) |
|
static std::vector< std::string > | Split (const std::string &input, const std::string &delimiter, unsigned int iMaxStrings=0) |
| Splits the given input string using the given delimiter into separate strings. More...
|
|
static std::vector< std::string > | Split (const std::string &input, const char delimiter, size_t iMaxStrings=0) |
|
static std::vector< std::string > | Split (const std::string &input, const std::vector< std::string > &delimiters) |
|
template<typename OutputIt > |
static OutputIt | SplitTo (OutputIt d_first, const std::string &input, const std::string &delimiter, unsigned int iMaxStrings=0) |
| Splits the given input string using the given delimiter into separate strings. More...
|
|
template<typename OutputIt > |
static OutputIt | SplitTo (OutputIt d_first, const std::string &input, const char delimiter, size_t iMaxStrings=0) |
|
template<typename OutputIt > |
static OutputIt | SplitTo (OutputIt d_first, const std::string &input, const std::vector< std::string > &delimiters) |
|
static std::vector< std::string > | SplitMulti (const std::vector< std::string > &input, const std::vector< std::string > &delimiters, unsigned int iMaxStrings=0) |
| Splits the given input strings using the given delimiters into further separate strings. More...
|
|
static int | FindNumber (const std::string &strInput, const std::string &strFind) |
|
static int64_t | AlphaNumericCompare (const wchar_t *left, const wchar_t *right) |
|
static long | TimeStringToSeconds (const std::string &timeString) |
|
static void | RemoveCRLF (std::string &strLine) |
|
static size_t | utf8_strlen (const char *s) |
| utf8 version of strlen - skips any non-starting bytes in the count, thus returning the number of utf8 characters More...
|
|
static std::string | SecondsToTimeString (long seconds, TIME_FORMAT format=TIME_FORMAT_GUESS) |
| convert a time in seconds to a string based on the given time format More...
|
|
static bool | IsNaturalNumber (const std::string &str) |
| check whether a string is a natural number. Matches [ \t]*[0-9]+[ \t]* More...
|
|
static bool | IsInteger (const std::string &str) |
| check whether a string is an integer. Matches [ \t]*[-]*[0-9]+[ \t]* More...
|
|
static bool | isasciidigit (char chr) |
|
static bool | isasciixdigit (char chr) |
|
static int | asciidigitvalue (char chr) |
|
static int | asciixdigitvalue (char chr) |
|
static bool | isasciiuppercaseletter (char chr) |
|
static bool | isasciilowercaseletter (char chr) |
|
static bool | isasciialphanum (char chr) |
|
static std::string | SizeToString (int64_t size) |
|
static size_t | FindWords (const char *str, const char *wordLowerCase) |
|
static int | FindEndBracket (const std::string &str, char opener, char closer, int startPos=0) |
|
static int | DateStringToYYYYMMDD (const std::string &dateString) |
|
static void | WordToDigits (std::string &word) |
|
static std::string | CreateUUID () |
|
static bool | ValidateUUID (const std::string &uuid) |
|
static double | CompareFuzzy (const std::string &left, const std::string &right) |
|
static int | FindBestMatch (const std::string &str, const std::vector< std::string > &strings, double &matchscore) |
|
static bool | ContainsKeyword (const std::string &str, const std::vector< std::string > &keywords) |
|
static std::string | BinaryStringToString (const std::string &in) |
| Convert the string of binary chars to the actual string. More...
|
|
static std::string | ToHexadecimal (const std::string &in) |
|
template<typename T > |
static std::string | FormatNumber (T num) |
| Format the string with locale separators. More...
|
|
static std::string | Paramify (const std::string ¶m) |
| Escapes the given string to be able to be used as a parameter. More...
|
|
static std::vector< std::string > | Tokenize (const std::string &input, const std::string &delimiters) |
| Split a string by the specified delimiters. Splits a string using one or more delimiting characters, ignoring empty tokens. Differs from Split() in two ways: More...
|
|
static void | Tokenize (const std::string &input, std::vector< std::string > &tokens, const std::string &delimiters) |
|
static std::vector< std::string > | Tokenize (const std::string &input, const char delimiter) |
|
static void | Tokenize (const std::string &input, std::vector< std::string > &tokens, const char delimiter) |
|
static uint64_t | ToUint64 (std::string str, uint64_t fallback) noexcept |
|
static std::string | FormatFileSize (uint64_t bytes) |
|