![]() |
Murl Engine API
Version 2025.1
|
A string class. More...
#include <murl_string.h>
A string class.
The string class contains an array of byte characters which can store an 8 bit encoded string or an UTF-8 encoded string. The array of characters is zero terminated.
A C string is a pointer to an array of byte characters which is zero-terminated.
This class is based on the NTL String container, see http://www.ultimatepp.org
Public Types | |
| using | ConstIterator = const Char * |
| Definition of the const iterator. | |
Public Member Functions | |
| String () noexcept | |
| Construct an empty string. | |
| String (const String &str) noexcept | |
| Construct using a given string. More... | |
| String (String &&str) noexcept | |
| Construct using a given string. More... | |
| String (const Char *str) | |
| Construct a copy from a given C string. More... | |
| String (const String &str, SInt32 length) | |
| Construct a copy of a given string and length. More... | |
| String (const String &str, SInt32 length, Bool trimTrailingDelimiters) | |
| Construct a copy of a given string and length. More... | |
| String (const Char *str, SInt32 length) | |
| Construct a string from a given C string & length. More... | |
| String (const Char *str, SInt32 length, Bool trimTrailingDelimiters) | |
| Construct a string from a given C string & length. More... | |
| String (const UInt8 *str, SInt32 length) | |
| Construct a copy from a given byte pointer and length. More... | |
| String (const UInt8 *str, SInt32 length, Bool trimTrailingDelimiters) | |
| Construct a string from a given byte pointer and length. More... | |
| String (Char charCode, SInt32 length) | |
| Construct and fill a string with a given character and length. More... | |
| ~String () | |
| Destroy the string. | |
| void | Clear () |
| Clear the string and remove the underlying storage. | |
| void | Shrink () |
| Shrink the string so that the underlying storage is only as large as necessary. | |
| Bool | Reserve (SInt32 count) |
| Reserve additional storage space. More... | |
| Bool | CutAt (SInt32 pos) |
| Cut the string on a given position. More... | |
| String | Trim () const |
| Trim white spaces from left and right. More... | |
| String | TrimLeft () const |
| Trim white spaces from left. More... | |
| String | TrimRight () const |
| Trim white spaces from right. More... | |
| String | ToLowerUTF8 () const |
| Get the lower case string including UTF-8 characters. More... | |
| String | ToUpperUTF8 () const |
| Get the upper case string including UTF-8 characters. More... | |
| SInt32 | GetLengthUTF8 () const |
| Count the number of UTF-8 characters. More... | |
| String | GetUTF8Char (SInt32 pos) const |
| Get a UTF-8 character at a specified position. More... | |
| StringArray | GetUTF8Chars () const |
| Get the UTF-8 characters. More... | |
| WCharArray | GetWChars () const |
| Get the wide-characters. More... | |
| Bool | GetWChars (WCharArray &wcharArray) const |
| Get the wide-characters and success status. More... | |
| UInt16Array | GetUTF16Chars () const |
| Get the UTF-16 characters. More... | |
| Bool | GetUTF16Chars (UInt16Array &utf16Array) const |
| Get the UTF-16 characters and success status. More... | |
| UInt32Array | GetUTF32Chars () const |
| Get the UTF-32 characters. More... | |
| Bool | GetUTF32Chars (UInt32Array &utf32Array) const |
| Get the UTF-32 characters and success status. More... | |
| Bool | SetWChars (const WCharArray &wcharArray) |
| Set UTF-8 characters from a wide-character string. More... | |
| Bool | SetWChars (const WChar *wcharArray) |
| Set UTF-8 characters from a wide-character string pointer. More... | |
| Bool | SetUTF16Chars (const UInt16Array &utf16Array) |
| Set UTF-8 characters from an UTF16 string. More... | |
| Bool | SetUTF16Chars (const UInt16 *utf16Array) |
| Set UTF-8 characters from an UTF16 string pointer. More... | |
| Bool | SetUTF32Chars (const UInt32Array &utf32Array) |
| Set UTF-8 characters from an UTF32 string. More... | |
| Bool | SetUTF32Chars (const UInt32 *utf32Array) |
| Set UTF-8 characters from an UTF32 string pointer. More... | |
| String & | Cat (const StringArray &stringArray) |
| Append all strings from an string array. More... | |
| Bool | RemoveLastUTF8 () |
| Remove the last character from the string including UTF-8. More... | |
| Char | GetChar (SInt32 pos) const |
| Get a character at a specified position. More... | |
| Bool | Set (SInt32 pos, Char charCode) |
| Set a character. More... | |
| void | Set (const String &str) |
| Set to a given string. More... | |
| void | Set (const Char *str, SInt32 length) |
| Set to a given C string and length. More... | |
| void | Set (const Char *str, SInt32 length, Bool trimTrailingDelimiters) |
| Set to a given C string and length. More... | |
| Bool | Insert (SInt32 pos, Char charCode) |
| Insert a character. More... | |
| Bool | Insert (SInt32 pos, const Char *str, SInt32 count) |
| Insert a C string & length. More... | |
| Bool | Insert (SInt32 pos, const String &str) |
| Insert a string. More... | |
| Bool | Insert (SInt32 pos, const Char *str) |
| Insert a C string. More... | |
| Bool | Remove (SInt32 pos, SInt32 count=1) |
| Remove character(s). More... | |
| SInt32 | RemoveChar (Char character) |
| Remove all occurrences of a character. More... | |
| String & | Cat (const Char *str) |
| Append a C string. More... | |
| String & | Cat (const String &str) |
| Append a string. More... | |
| Bool | AppendUtf32 (UInt32 utf32CharCode) |
| Append one UTF-32 character. More... | |
| Bool | AppendUtf32 (UInt32 utf32CharCode, SInt32 count) |
| Append UTF-32 characters. More... | |
| Bool | AppendUtf32 (const UInt32 *utf32str, SInt32 length) |
| Append UTF-32 characters from a given pointer and length. More... | |
| String & | Cat (Char charCode, SInt32 count) |
| Append characters. More... | |
| String & | Cat (const String &str, SInt32 length) |
| Append from a given string and length. More... | |
| String & | Cat (const UInt8 *str, SInt32 length) |
| Append from a given byte pointer and length. More... | |
| String & | Cat () |
| Get a reference of the string. More... | |
| String & | Cat (Char charCode) |
| Append a character. More... | |
| String & | Cat (const Char *str, SInt32 length) |
| Append from a given C string & length. More... | |
| String | Mid (SInt32 from, SInt32 count) const |
| Get a substring copy. More... | |
| String | Mid (const String &startDelimiter, const String &endDelimiter, Bool isStartOptional=true, Bool isEndOptional=true) const |
| Get a substring copy using delimiters. More... | |
| String | Mid (SInt32 from) const |
| Get a substring copy. More... | |
| String | Right (SInt32 count) const |
| Get a substring from the right. More... | |
| String | Left (SInt32 count) const |
| Get a substring from the left. More... | |
| UInt32 | Replace (const Char *find, SInt32 findLen, const Char *replace, SInt32 replaceLen) |
| Find any occurrence of a C string & length and replace each occurrence by a C string & length. More... | |
| UInt32 | Replace (const String &find, const String &replace) |
| Find any occurrence of a string and replace each occurrence by a string. More... | |
| UInt32 | Replace (const Char *find, const Char *replace) |
| Find any occurrence of a C string and replace each occurrence by a C string. More... | |
| UInt32 | Replace (const String &find, const Char *replace) |
| Find any occurrence of a string and replace each occurrence by a C string. More... | |
| UInt32 | Replace (const Char *find, const String &replace) |
| Find any occurrence of a C string and replace each occurrence by a string. More... | |
| String & | Replace (UInt32 offset, UInt32 length, const String &replace) |
| Replaces subsection of this string with other characters. More... | |
| SInt32 | Find (Char charCode, SInt32 from=0) const |
| Find a character. More... | |
| SInt32 | Find (SInt32 length, const Char *str, SInt32 from) const |
| Find a C string & length. More... | |
| SInt32 | Find (const Char *str, SInt32 from=0) const |
| Find a C string. More... | |
| SInt32 | Find (const String &str, SInt32 from=0) const |
| Find a string. More... | |
| SInt32 | ReverseFind (Char charCode, SInt32 from) const |
| Find a character from right to left. More... | |
| SInt32 | ReverseFind (Char charCode) const |
| Find a character from right to left. More... | |
| SInt32 | ReverseFind (SInt32 length, const Char *str, SInt32 from) const |
| Find a C string & length from right to left at position. More... | |
| SInt32 | ReverseFind (const Char *str, SInt32 from) const |
| Find a C string from right to left at position. More... | |
| SInt32 | ReverseFind (const String &str, SInt32 from) const |
| Find a string from right to left at position. More... | |
| SInt32 | ReverseFind (const Char *str) const |
| Find a C string from right to left. More... | |
| SInt32 | ReverseFind (const String &str) const |
| Find a string from right to left. More... | |
| SInt32 | FindFirstOf (SInt32 length, const Char *str, SInt32 from) const |
| Find first character from a character set C string & length. More... | |
| SInt32 | FindFirstOf (const Char *str, SInt32 from=0) const |
| Find first character from a character set C string. More... | |
| SInt32 | FindFirstOf (const String &str, SInt32 from=0) const |
| Find first character from a character set string. More... | |
| SInt32 | FindFirstNotOf (SInt32 length, const Char *str, SInt32 from) const |
| Find the first character not matching any of the characters in a given set. More... | |
| SInt32 | FindFirstNotOf (const Char *str, SInt32 from=0) const |
| Find the first character not matching any of the characters in a given set. More... | |
| SInt32 | FindFirstNotOf (const String &str, SInt32 from=0) const |
| Find the first character not matching any of the characters in a given set. More... | |
| Bool | StartsWith (const Char *str, SInt32 length) const |
| Check if the start matches a C string & length. More... | |
| Bool | StartsWith (const Char *str) const |
| Check if the start matches a C string. More... | |
| Bool | StartsWith (const String &str) const |
| Check if the start matches a string. More... | |
| Bool | EndsWith (const Char *str, SInt32 length) const |
| Check if the end matches a C string & length. More... | |
| Bool | EndsWith (const Char *str) const |
| Check if the end matches a C string. More... | |
| Bool | EndsWith (const String &str) const |
| Check if the end matches a string. More... | |
| SInt32 | Compare (const Char *str) const |
| Compare a C string. More... | |
| SInt32 | Compare (const String &str) const |
| Compare a string. More... | |
| Bool | IsEqual (const Char *str) const |
| Check if a C string is equal. More... | |
| Bool | IsEqual (const String &str) const |
| Check if a string is equal. More... | |
| UInt32 | GetHashValue () const |
| Calculate the string hash value. More... | |
| SInt32 | GetAlloc () const |
| Get the number of allocated bytes for characters, excluding the zero terminator. More... | |
| SInt32 | GetLength () const |
| Get number of byte characters. More... | |
| Bool | IsEmpty () const |
| Check if the string is empty. More... | |
| const String & | ToString () const |
| Get a const reference of the string. More... | |
| const Char * | Begin () const |
| Get the pointer to the first character. More... | |
| const Char * | End () const |
| Get the pointer to the end of the string. More... | |
| const Char * | Last () const |
| Get the pointer to the last character. More... | |
| operator const Char * () const | |
| Conversion operator to C string. More... | |
| operator const UInt8 * () const | |
| Conversion operator to byte pointer. More... | |
| operator const void * () const | |
| Conversion operator to void pointer. More... | |
| Char | operator[] (SInt32 pos) const |
| The array operator. More... | |
| Char | operator* () const |
| Indirection operator. More... | |
| String & | operator= (const Char *str) |
| Assignment operator for C string. More... | |
| String & | operator= (const String &str) |
| Assignment operator for string. More... | |
| String & | operator= (String &&str) noexcept |
| Move operator for string. More... | |
| const String & | operator+= (Char chr) |
| In-place addition operator for a character. More... | |
| const String & | operator+= (const Char *str) |
| In-place addition operator for const C string. More... | |
| const String & | operator+= (const String &str) |
| In-place addition operator for string. More... | |
| const String & | operator+= (UInt64 value) |
| In-place addition operator for UInt64. More... | |
| const String & | operator+= (SInt64 value) |
| In-place addition operator for SInt64. More... | |
| const String & | operator+= (UInt32 value) |
| In-place addition operator for UInt32. More... | |
| const String & | operator+= (SInt32 value) |
| In-place addition operator for SInt32. More... | |
| const String & | operator+= (Double value) |
| In-place addition operator for Double. More... | |
| const String & | operator+= (const Color &value) |
| In-place addition operator for Color. More... | |
| const String & | operator+= (Bool value) |
| In-place addition operator for Bool. More... | |
| const String & | operator+= (const System::Time &value) |
| In-place addition operator for Color. More... | |
| void | Swap (String &other) |
| Exchange the content of the string with a given second one. More... | |
Friends | |
| String | operator+ (const String &lhs, const String &rhs) |
| Addition operator for string and string. More... | |
| String | operator+ (const String &lhs, const Char *rhs) |
| Addition operator for string and C string. More... | |
| String | operator+ (const Char *lhs, const String &rhs) |
| Addition operator for C string and string. More... | |
| String | operator+ (const String &lhs, Char rhs) |
| Addition operator for string and character. More... | |
| String | operator+ (Char lhs, const String &rhs) |
| Addition operator for character and string. More... | |
| String | operator+ (const String &lhs, UInt64 rhs) |
| Addition operator for UInt64 and string. More... | |
| String | operator+ (const String &lhs, SInt64 rhs) |
| Addition operator for SInt64 and string. More... | |
| String | operator+ (const String &lhs, UInt32 rhs) |
| Addition operator for UInt32 and string. More... | |
| String | operator+ (const String &lhs, SInt32 rhs) |
| Addition operator for SInt32 and string. More... | |
| String | operator+ (const String &lhs, Double rhs) |
| Addition operator for Double and string. More... | |
| String | operator+ (const String &lhs, const Color &rhs) |
| Addition operator for Color and string. More... | |
| String | operator+ (const String &lhs, Bool rhs) |
| Addition operator for Bool and string. More... | |
| String | operator+ (const String &lhs, const System::Time &rhs) |
| Addition operator for Time and string. More... | |
| bool | operator< (const String &lhs, const String &rhs) |
| Less than operator for string and string. More... | |
| bool | operator< (const String &lhs, const Char *rhs) |
| Less than operator for string and C string. More... | |
| bool | operator< (const Char *lhs, const String &rhs) |
| Less than operator for C string and string. More... | |
| bool | operator<= (const String &lhs, const String &rhs) |
| Less than or equal to operator for string and string. More... | |
| bool | operator<= (const String &lhs, const Char *rhs) |
| Less than or equal to operator for string and C string. More... | |
| bool | operator<= (const Char *lhs, const String &rhs) |
| Less than or equal to operator for C string and string. More... | |
| bool | operator> (const String &lhs, const String &rhs) |
| Greater than operator for string and string. More... | |
| bool | operator> (const String &lhs, const Char *rhs) |
| Greater than operator for string and C string. More... | |
| bool | operator> (const Char *lhs, const String &rhs) |
| Greater than operator for C string and string. More... | |
| bool | operator>= (const String &lhs, const String &rhs) |
| Greater than or equal to operator for string and string. More... | |
| bool | operator>= (const String &lhs, const Char *rhs) |
| Greater than or equal to operator for string and C string. More... | |
| bool | operator>= (const Char *lhs, const String &rhs) |
| Greater than or equal to operator for C string and string. More... | |
| bool | operator== (const String &lhs, const String &rhs) |
| Equal to comparison operator for string and string. More... | |
| bool | operator== (const String &lhs, const Char *rhs) |
| Equal to comparison operator for string and C string. More... | |
| bool | operator== (const Char *lhs, const String &rhs) |
| Equal to comparison operator for C string and string. More... | |
| bool | operator!= (const String &lhs, const String &rhs) |
| Not equal to comparison operator for string and string. More... | |
| bool | operator!= (const String &lhs, const Char *rhs) |
| Not equal to comparison operator for string and C string. More... | |
| bool | operator!= (const Char *lhs, const String &rhs) |
| Not equal to comparison operator for C string and string. More... | |
|
inlinenoexcept |
Construct using a given string.
| str | The original string. |
|
inlinenoexcept |
Construct using a given string.
| str | The original string. |
|
inline |
Construct a copy from a given C string.
| str | The C string to copy. |
Construct a copy of a given string and length.
Verify (assert in debug build) 'length' against the length of 'str'. Any trailing zero bytes from str[length-1] downwards will be trimmed, and length will be decreased accordingly. This is equivalent to using the constructor form String(str, length, true)
| str | The string to copy. |
| length | The number of bytes to copy. |
Construct a copy of a given string and length.
If trimTrailingDelimiters is true, any trailing zero bytes from str[length-1] downwards will be trimmed, and length will be decreased accordingly. Otherwise, the given string is copied 'as-is', and any trailing zero bytes will be included in the number returned by GetLength().
| str | The string to copy. |
| length | The number of bytes to copy. |
| trimTrailingDelimiters | If true, trailing zero bytes are trimmed. |
Construct a string from a given C string & length.
Any trailing zero bytes from str[length-1] downwards will be trimmed, and length will be decreased accordingly. This is equivalent to using the constructor form String(str, length, true)
| str | The C string to copy. |
| length | The number of bytes to copy. |
Construct a string from a given C string & length.
If trimTrailingDelimiters is true, any trailing zero bytes from str[length-1] downwards will be trimmed, and length will be decreased accordingly. Otherwise, the given C string is copied 'as-is', and any trailing zero bytes will be included in the number returned by GetLength().
| str | The C string to copy. |
| length | The number of bytes to copy. |
| trimTrailingDelimiters | If true, trailing zero bytes are trimmed. |
Construct a copy from a given byte pointer and length.
Any trailing zero bytes from str[length-1] downwards will be trimmed, and length will be decreased accordingly. This is equivalent to using the constructor form String(str, length, true)
| str | The byte pointer to copy. |
| length | The number of bytes to copy. |
Construct a string from a given byte pointer and length.
If trimTrailingDelimiters is true, any trailing zero bytes from str[length-1] downwards will be trimmed, and length will be decreased accordingly. Otherwise, the given C string is copied 'as-is', and any trailing zero bytes will be included in the number returned by GetLength().
| str | The byte pointer to copy. |
| length | The number of bytes to copy. |
| trimTrailingDelimiters | If true, trailing zero bytes are trimmed. |
Construct and fill a string with a given character and length.
| charCode | The character code to fill. |
| length | The number of bytes to fill. |
Reserve additional storage space.
| count | The number of additional bytes to reserve. |
Cut the string on a given position.
Verify (assert in debug build) 'pos' against the string length.
| pos | The position to cut the string. |
| String Murl::String::Trim | ( | ) | const |
Trim white spaces from left and right.
| String Murl::String::TrimLeft | ( | ) | const |
Trim white spaces from left.
| String Murl::String::TrimRight | ( | ) | const |
Trim white spaces from right.
| String Murl::String::ToLowerUTF8 | ( | ) | const |
Get the lower case string including UTF-8 characters.
| String Murl::String::ToUpperUTF8 | ( | ) | const |
Get the upper case string including UTF-8 characters.
| SInt32 Murl::String::GetLengthUTF8 | ( | ) | const |
Count the number of UTF-8 characters.
Get a UTF-8 character at a specified position.
Verify (assert in debug build) 'pos' against the string length.
| pos | The byte position to get the character from. |
| StringArray Murl::String::GetUTF8Chars | ( | ) | const |
Get the UTF-8 characters.
| WCharArray Murl::String::GetWChars | ( | ) | const |
Get the wide-characters.
| Bool Murl::String::GetWChars | ( | WCharArray & | wcharArray | ) | const |
Get the wide-characters and success status.
| wcharArray | The wide-characters array return value. |
| UInt16Array Murl::String::GetUTF16Chars | ( | ) | const |
Get the UTF-16 characters.
| Bool Murl::String::GetUTF16Chars | ( | UInt16Array & | utf16Array | ) | const |
Get the UTF-16 characters and success status.
| utf16Array | The UTF-16 characters array return value. |
| UInt32Array Murl::String::GetUTF32Chars | ( | ) | const |
Get the UTF-32 characters.
| Bool Murl::String::GetUTF32Chars | ( | UInt32Array & | utf32Array | ) | const |
Get the UTF-32 characters and success status.
| utf32Array | The UTF-32 characters array return value. |
| Bool Murl::String::SetWChars | ( | const WCharArray & | wcharArray | ) |
Set UTF-8 characters from a wide-character string.
| wcharArray | The wide-characters array. |
Set UTF-8 characters from a wide-character string pointer.
| wcharArray | A pointer to the zero-terminated wide-characters. |
| Bool Murl::String::SetUTF16Chars | ( | const UInt16Array & | utf16Array | ) |
Set UTF-8 characters from an UTF16 string.
| utf16Array | The UTF-16 characters array. |
Set UTF-8 characters from an UTF16 string pointer.
| utf16Array | A pointer to the zero-terminated UTF16 characters. |
| Bool Murl::String::SetUTF32Chars | ( | const UInt32Array & | utf32Array | ) |
Set UTF-8 characters from an UTF32 string.
| utf32Array | The UTF-32 characters array. |
Set UTF-8 characters from an UTF32 string pointer.
| utf32Array | A pointer to the zero-terminated UTF32 characters. |
| String& Murl::String::Cat | ( | const StringArray & | stringArray | ) |
Append all strings from an string array.
| stringArray | The string array to append. |
| Bool Murl::String::RemoveLastUTF8 | ( | ) |
Remove the last character from the string including UTF-8.
Get a character at a specified position.
Verify (assert in debug build) 'pos' against the string length.
| pos | The byte position to get the character from. |
Set a character.
Verify (assert in debug build) 'pos' against the string length.
| pos | The byte position. |
| charCode | The character code to set. |
|
inline |
Set to a given string.
| str | The string to set. |
Set to a given C string and length.
Any trailing zero bytes from str[length-1] downwards will be trimmed, and length will be decreased accordingly. This is equivalent to calling Set(str, length, true).
| str | The string to copy. |
| length | The number of bytes to copy. |
Set to a given C string and length.
If trimTrailingDelimiters is true, any trailing zero bytes from str[length-1] downwards will be trimmed, and length will be decreased accordingly. Otherwise, the given C string is copied 'as-is', and any trailing zero bytes will be included in the number returned by GetLength().
| str | The string to copy. |
| trimTrailingDelimiters | If true, trailing zero bytes are trimmed. |
| length | The number of bytes to copy. |
Insert a character.
| pos | The byte position to insert. |
| charCode | The character code to insert. |
Insert a C string & length.
| pos | The byte position to insert. |
| str | The C string to insert. |
| count | The number of bytes to insert. |
Insert a string.
| pos | The byte position to insert. |
| str | The string to insert. |
Insert a C string.
| pos | The byte position to insert. |
| str | The C string to insert. |
Remove character(s).
Verify (assert in debug build) 'pos' and 'count' against the string length.
| pos | The byte position to remove. |
| count | The number of characters to remove. |
Remove all occurrences of a character.
| character | The character to remove. |
Append a C string.
| str | The C string to append. |
Append a string.
| str | The string to append. |
Append one UTF-32 character.
| utf32CharCode | The UTF-32 character code to append. |
Append UTF-32 characters.
| utf32CharCode | The UTF-32 character code to append. |
| count | The number of characters to append. |
Append UTF-32 characters from a given pointer and length.
| utf32str | The UTF-32 pointer to append. |
| length | The number of bytes to copy. |
Append characters.
| charCode | The character code to append. |
| count | The number of characters to append. |
Append from a given string and length.
| str | The string to append. |
| length | The number of bytes to copy. |
Append from a given byte pointer and length.
| str | The byte pointer to append. |
| length | The number of bytes to copy. |
|
inline |
Get a reference of the string.
Append a character.
| charCode | The character code to append. |
Append from a given C string & length.
| str | The C string to append. |
| length | The number of bytes to copy. |
Get a substring copy.
| from | The byte position to start. |
| count | the number of bytes to copy. |
| String Murl::String::Mid | ( | const String & | startDelimiter, |
| const String & | endDelimiter, | ||
| Bool | isStartOptional = true, |
||
| Bool | isEndOptional = true |
||
| ) | const |
Get a substring copy using delimiters.
| startDelimiter | The start delimiter string. |
| endDelimiter | The end delimiter string. |
| isStartOptional | false if start delimiter is required to be found. |
| isEndOptional | false if end delimiter is required to be found. |
Get a substring copy.
| from | The byte position to start. |
Get a substring from the right.
| count | Number of bytes to copy. |
Get a substring from the left.
| count | Number of bytes to copy. |
| UInt32 Murl::String::Replace | ( | const Char * | find, |
| SInt32 | findLen, | ||
| const Char * | replace, | ||
| SInt32 | replaceLen | ||
| ) |
Find any occurrence of a C string & length and replace each occurrence by a C string & length.
| find | The C string to find. |
| findLen | The number of bytes to find. |
| replace | The C string to replace. |
| replaceLen | The number of bytes to replace. |
Find any occurrence of a string and replace each occurrence by a string.
| find | The string to find. |
| replace | The string to replace. |
Find any occurrence of a C string and replace each occurrence by a C string.
| find | The C string to find. |
| replace | The C string to replace. |
Find any occurrence of a string and replace each occurrence by a C string.
| find | The string to find. |
| replace | The C string to replace. |
Find any occurrence of a C string and replace each occurrence by a string.
| find | The C string to find. |
| replace | The string to replace. |
Replaces subsection of this string with other characters.
| offset | replace start offset |
| length | replace that many characters |
| replace | new characters |
Find a character.
Verify (assert in debug build) 'from' against the string length.
| charCode | The character to find. |
| from | The byte position to start. |
Find a C string & length.
Verify (assert in debug build) 'from' against the string length.
| length | The number of bytes to find. |
| str | The C string to find. |
| from | The byte position to start. |
Find a C string.
| str | The C string to find. |
| from | The byte position to start. |
Find a string.
| str | The string to find. |
| from | The byte position to start. |
Find a character from right to left.
Verify (assert in debug build) 'from' against the string length.
| charCode | The character to find. |
| from | The byte position to start. |
Find a character from right to left.
| charCode | The character to find. |
Find a C string & length from right to left at position.
Verify (assert in debug build) 'from' against the string length.
| length | The number of bytes to find. |
| str | The C string to find. |
| from | The byte position to start. |
Find a C string from right to left at position.
| str | The C string to find. |
| from | The byte position to start. |
Find a string from right to left at position.
| str | The string to find. |
| from | The byte position to start. |
Find a C string from right to left.
| str | The C string to find. |
Find a string from right to left.
| str | The string to find. |
Find first character from a character set C string & length.
Verify (assert in debug build) 'from' against the string length.
| length | The number of bytes in the C string. |
| str | The character set C string. |
| from | The byte position to start. |
Find first character from a character set C string.
| str | The character set C string. |
| from | The byte position to start. |
Find first character from a character set string.
| str | The character set string. |
| from | The byte position to start. |
Find the first character not matching any of the characters in a given set.
Verify (assert in debug build) 'from' against the string length.
| length | The number of bytes in the given C string character set. |
| str | The character set C string. |
| from | The byte position to start. |
Find the first character not matching any of the characters in a given set.
| str | The character set C string. |
| from | The byte position to start. |
Find the first character not matching any of the characters in a given set.
| str | The character set string. |
| from | The byte position to start. |
Check if the start matches a C string & length.
| str | The C string to match. |
| length | The number of bytes to match. |
Check if the start matches a C string.
| str | The C string to match. |
Check if the start matches a string.
| str | The string to match. |
Check if the end matches a C string & length.
| str | The C string to match. |
| length | The number of bytes to match. |
Check if the end matches a C string.
| str | The C string to match. |
Check if the end matches a string.
| str | The string to match. |
Compare a C string.
| str | The C string to compare. |
Compare a string.
| str | The string to compare. |
Check if a C string is equal.
| str | The C string to compare. |
Check if a string is equal.
| str | The string to compare. |
| UInt32 Murl::String::GetHashValue | ( | ) | const |
Calculate the string hash value.
|
inline |
Get the number of allocated bytes for characters, excluding the zero terminator.
|
inline |
Get number of byte characters.
|
inline |
Check if the string is empty.
|
inline |
Get a const reference of the string.
Convenience method for Lua scripting support.
|
inline |
Get the pointer to the first character.
|
inline |
Get the pointer to the end of the string.
|
inline |
Get the pointer to the last character.
|
inline |
Conversion operator to C string.
|
inline |
Conversion operator to byte pointer.
|
inline |
Conversion operator to void pointer.
The array operator.
Verify (assert in debug build) 'pos' against the string length.
| pos | The character byte position. |
|
inline |
Indirection operator.
Assignment operator for C string.
| str | The C string to assign. |
Assignment operator for string.
| str | The string to assign. |
Move operator for string.
| str | The string to assign. |
In-place addition operator for a character.
| chr | The character to add. |
In-place addition operator for const C string.
| str | The C string to add. |
In-place addition operator for string.
| str | The string to add. |
In-place addition operator for UInt64.
| value | The value to add. |
In-place addition operator for SInt64.
| value | The value to add. |
In-place addition operator for UInt32.
| value | The value to add. |
In-place addition operator for SInt32.
| value | The value to add. |
In-place addition operator for Double.
| value | The value to add. |
In-place addition operator for Bool.
| value | The value to add. |
| const String& Murl::String::operator+= | ( | const System::Time & | value | ) |
| void Murl::String::Swap | ( | String & | other | ) |
Exchange the content of the string with a given second one.
| other | The second string. |
Addition operator for string and string.
| lhs | The left hand side string. |
| rhs | The right hand side string. |
Addition operator for string and C string.
| lhs | The left hand side string. |
| rhs | The right hand side C string. |
Addition operator for C string and string.
| lhs | The left hand side C string. |
| rhs | The right hand side string. |
Addition operator for string and character.
| lhs | The left hand side string. |
| rhs | The right hand side character. |
Addition operator for character and string.
| lhs | The left hand side character. |
| rhs | The right hand side string. |
Addition operator for UInt64 and string.
| lhs | The left hand side string. |
| rhs | The right hand side variable. |
Addition operator for SInt64 and string.
| lhs | The left hand side string. |
| rhs | The right hand side variable. |
Addition operator for UInt32 and string.
| lhs | The left hand side string. |
| rhs | The right hand side variable. |
Addition operator for SInt32 and string.
| lhs | The left hand side string. |
| rhs | The right hand side variable. |
Addition operator for Double and string.
| lhs | The left hand side string. |
| rhs | The right hand side variable. |
Addition operator for Color and string.
| lhs | The left hand side string. |
| rhs | The right hand side variable. |
Addition operator for Bool and string.
| lhs | The left hand side string. |
| rhs | The right hand side variable. |
|
friend |
Addition operator for Time and string.
| lhs | The left hand side string. |
| rhs | The right hand side variable. |
Less than operator for string and string.
| lhs | The left hand side string. |
| rhs | The right hand side string. |
Less than operator for string and C string.
| lhs | The left hand side string. |
| rhs | The right hand side C string. |
Less than operator for C string and string.
| lhs | The left hand side C string. |
| rhs | The right hand side string. |
Less than or equal to operator for string and string.
| lhs | The left hand side string. |
| rhs | The right hand side string. |
Less than or equal to operator for string and C string.
| lhs | The left hand side string. |
| rhs | The right hand side C string. |
Less than or equal to operator for C string and string.
| lhs | The left hand side C string. |
| rhs | The right hand side string. |
Greater than operator for string and string.
| lhs | The left hand side string. |
| rhs | The right hand side string. |
Greater than operator for string and C string.
| lhs | The left hand side string. |
| rhs | The right hand side C string. |
Greater than operator for C string and string.
| lhs | The left hand side C string. |
| rhs | The right hand side string. |
Greater than or equal to operator for string and string.
| lhs | The left hand side string. |
| rhs | The right hand side string. |
Greater than or equal to operator for string and C string.
| lhs | The left hand side string. |
| rhs | The right hand side C string. |
Greater than or equal to operator for C string and string.
| lhs | The left hand side C string. |
| rhs | The right hand side string. |
Equal to comparison operator for string and string.
| lhs | The left hand side string. |
| rhs | The right hand side string. |
Equal to comparison operator for string and C string.
| lhs | The left hand side string. |
| rhs | The right hand side C string. |
Equal to comparison operator for C string and string.
| lhs | The left hand side C string. |
| rhs | The right hand side string. |
Not equal to comparison operator for string and string.
| lhs | The left hand side string. |
| rhs | The right hand side string. |
Not equal to comparison operator for string and C string.
| lhs | The left hand side string. |
| rhs | The right hand side C string. |
Not equal to comparison operator for C string and string.
| lhs | The left hand side C string. |
| rhs | The right hand side string. |