7#ifndef __HDI_CORE_STRINGS__
8#define __HDI_CORE_STRINGS__
20 typedef std::vector<std::string> StringVector;
31 uint32_t
substrCount(
const std::string& str_,
const std::string& substr_);
43 bool split(
const std::string& str_,
const std::string& delim_, StringVector& elements__);
53 std::string
trim(
const std::string& str_);
86 std::string
replaceAll(
const std::string& subject_,
const std::string& search_,
const std::string& replace_);
UTF8String utf16ToUTF8(const UTF16String &str_)
Converts the given UTF-16 string to a UTF-8 string.
std::string replaceAll(const std::string &subject_, const std::string &search_, const std::string &replace_)
Replaces all instances of a search string, in a subject string, with a given replacement.
uint32_t substrCount(const std::string &str_, const std::string &substr_)
Gets the number of times a substring occurs in a given string.
UTF32String utf16ToUTF32(const UTF16String &str_)
Converts the given UTF-16 string to a UTF-32 string.
UTF32String utf8ToUTF32(const UTF8String &str_)
Converts the given UTF-8 string to a UTF-32 string.
UTF16String utf8ToUTF16(const UTF8String &str_)
Converts the given UTF-8 string to a UTF-16 string.
UTF8String utf32ToUTF8(const UTF32String &str_)
Converts the given UTF-32 string to a UTF-8 string.
UTF16String utf32ToUTF16(const UTF32String &str_)
Converts the given UTF-32 string to a UTF-16 string.
bool split(const std::string &str_, const std::string &delim_, StringVector &elements__)
Tokenizes a string by a given substring delimiter.
std::string lowercase(const std::string &str_)
Lowercases an entire string, returning a duplicate.
std::string trim(const std::string &str_)
Trims the whitespace from both ends of a string, returning a duplicate.
std::string uppercase(const std::string &str_)
Uppercases an entire string, returning a duplicate.
Header file for a wide variety of necessary typedefs, enums, and forwards declarations.
std::basic_string< UTF32Char > UTF32String
Typedef of std::basic_string<UTF32Char> as UTF32String.
Definition: hdicoreTypes.h:105
std::basic_string< UTF16Char > UTF16String
Typedef of std::basic_string<UTF16Char> as UTF16String.
Definition: hdicoreTypes.h:95
std::string UTF8String
Typedef of std::string as UTF8String.
Definition: hdicoreTypes.h:78