• Home
  • Raw
  • Download

Lines Matching full:str

55     static inline CString RepalceAll(CString str, const CString &oldValue,  in RepalceAll()  argument
59 return str; in RepalceAll()
62 while ((pos = str.find(oldValue, pos)) != CString::npos) { in RepalceAll()
63 str.replace(pos, oldValue.length(), newValue); in RepalceAll()
66 return str; in RepalceAll()
79 std::string str(charData, dataLen); in Utf8ToString()
80 return str; in Utf8ToString()
86 std::string str(charData, dataLen); in Utf8ToU16String()
87 …tring u16str = std::wstring_convert<std::codecvt_utf8_utf16<char16_t>, char16_t>{}.from_bytes(str); in Utf8ToU16String()
96 static inline std::wstring StringToWstring(const std::string &str) in StringToWstring() argument
98 return std::wstring_convert<std::codecvt_utf8<wchar_t>, wchar_t>{}.from_bytes(str); in StringToWstring()
106 static inline std::u16string StringToU16string(const std::string &str) in StringToU16string() argument
108 return std::wstring_convert<std::codecvt_utf8_utf16<char16_t>, char16_t>{}.from_bytes(str); in StringToU16string()
129 static inline std::string ToUpper(const std::u16string &str) in ToUpper() argument
131 std::u16string tmpStr = str; in ToUpper()
140 static inline std::string ToLocaleUpper(const std::u16string &str, const icu::Locale &locale) in ToLocaleUpper() argument
142 std::u16string tmpStr = str; in ToLocaleUpper()
151 static inline std::string ToLower(const std::u16string &str) in ToLower() argument
153 std::u16string tmpStr = str; in ToLower()
162 static inline std::string ToLocaleLower(const std::u16string &str, const icu::Locale &locale) in ToLocaleLower() argument
164 std::u16string tmpStr = str; in ToLocaleLower()
240 std::string str(data.begin(), data.end()); in Utf8ToU32String()
241 …::u32string u32str = std::wstring_convert<std::codecvt_utf8<char32_t>, char32_t>{}.from_bytes(str); in Utf8ToU32String()
347 … static std::vector<std::string> SplitString(const std::string &str, const std::string &delimiter) in SplitString() argument
351 std::size_t pos = str.find_first_of(delimiter, strIndex); in SplitString()
352 while ((pos < str.size()) && (pos > strIndex)) { in SplitString()
353 std::string subStr = str.substr(strIndex, pos - strIndex); in SplitString()
356 strIndex = str.find_first_not_of(delimiter, strIndex); in SplitString()
357 pos = str.find_first_of(delimiter, strIndex); in SplitString()
360 std::string subStr = str.substr(strIndex, pos - strIndex); in SplitString()
368 static bool EndsWith(const std::string &str, const std::string &suffix) in EndsWith() argument
370 if (str.length() < suffix.length()) { in EndsWith()
373 std::string subStr = str.substr(str.length() - suffix.length(), str.length()); in EndsWith()
388 static bool StringStartWith(const CString& str, const CString& startStr) in StringStartWith() argument
391 return ((str.length() >= startStrLen) && (str.compare(0, startStrLen, startStr) == 0)); in StringStartWith()
394 static bool StringEndWith(const CString& str, const CString& endStr) in StringEndWith() argument
397 size_t len = str.length(); in StringEndWith()
398 return ((len >= endStrLen) && (str.compare(len - endStrLen, endStrLen, endStr) == 0)); in StringEndWith()
401 …static void SplitString(const CString& str, CVector<CString>& out, size_t startPos, size_t times =…
406 while ((pos = str.find(c, left)) != CString::npos) {
410 out.emplace_back(str.substr(left, pos - left));
415 if ((times == 0 || index < times) && left < str.length()) {
416 out.emplace_back(str.substr(left));