Immutable string container. More...
#include <kanzi/core/string/immutable_string.hpp>
Public Member Functions | |
| const char * | c_str () const |
| Access string data. | |
| ImmutableString ()=default | |
| Empty constructor. | |
| ImmutableString (ImmutableString &&other) noexcept | |
| Move constructor. | |
| ImmutableString (string_view content) | |
| Constructor. | |
| operator string_view () const | |
| string_view operator. | |
| ImmutableString & | operator= (ImmutableString &&other) noexcept |
| Move operator. | |
Friends | |
| bool | operator!= (const ImmutableString &lhs, const ImmutableString &rhs) |
| Not equals operator. | |
| bool | operator!= (const ImmutableString &lhs, string_view rhs) |
| Not equals operator. | |
| bool | operator!= (string_view lhs, const ImmutableString &rhs) |
| Not equals operator. | |
| bool | operator< (const ImmutableString &lhs, const ImmutableString &rhs) |
| Less than operator. | |
| bool | operator== (const ImmutableString &lhs, const ImmutableString &rhs) |
| Comparison operator. | |
| bool | operator== (const ImmutableString &lhs, string_view rhs) |
| Comparison operator. | |
| bool | operator== (string_view lhs, const ImmutableString &rhs) |
| Comparison operator. | |
| void | swap (ImmutableString &left, ImmutableString &right) |
| Swap operation. | |
Immutable string container.
Represents a string that is allocated dynamically but cannot be changed.
|
explicitdefault |
Empty constructor.
|
inlineexplicit |
Constructor.
| content | String to construct from. |
|
inlinenoexcept |
Move constructor.
| other | Source string. |
|
inline |
string_view operator.
|
inlinenoexcept |
Move operator.
| other | Source string. |
|
friend |
Swap operation.
| left | Left operand. |
| right | Right operand. |
|
friend |
Comparison operator.
| lhs | Left-hand side operand. |
| rhs | Right-hand side operand. |
|
friend |
Comparison operator.
| lhs | Left-hand side operand. |
| rhs | Right-hand side operand. |
|
friend |
Comparison operator.
| lhs | Left-hand side operand. |
| rhs | Right-hand side operand. |
|
friend |
Not equals operator.
| lhs | Left-hand side operand. |
| rhs | Right-hand side operand. |
|
friend |
Not equals operator.
| lhs | Left-hand side operand. |
| rhs | Right-hand side operand. |
|
friend |
Not equals operator.
| lhs | Left-hand side operand. |
| rhs | Right-hand side operand. |
|
friend |
Less than operator.
| lhs | Left-hand side operand. |
| rhs | Right-hand side operand. |