Replace first occurrence of substring in specified string with specified value.
You can find more information in comments below.
/**
Replace first occurrence of substring "search" in string "str" on substring "replace"
@param[in, out] str String where to search and replace
@param search Searching string
@param replace String to replace with
*/
void ReplaceDirect(String &str, const String &search, const String &replace);
/**
Replace first occurrence of substring "search" in ANSI string "str" on substring "replace"
@param[in, out] str String where to search and replace
@param search Searching string
@param replace String to replace with
*/
void ReplaceDirect(AnsiString &str, const AnsiString &search, const AnsiString &replace);
/**
Replace first occurrence of substring "pair.first" in string "str" on substring "pair.second"
@param[in, out] str String where to search and replace
@param pair Search and replace parts
*/
void ReplaceDirect(String &str, const StringKeyValue &pair);
/**
Replace first occurrence of substring "pair.first" in ANSI string "str" on substring "pair.second"
@param[in, out] str String where to search and replace
@param pair Search and replace parts
*/
void ReplaceDirect(AnsiString &str, const AnsiStringKeyValue &pair);
Namespace: | nitisa |
Include: | Nitisa/Core/Strings.h |