|
LightsprintSDK 2021.08.08
|
#include <RRMemory.h>
Public Member Functions | |
| RRString () | |
| RRString (const RRString &a) | |
| RRString (const char *a) | |
| RRString (const wchar_t *a) | |
| RRString (unsigned zero, const wchar_t *fmt,...) | |
| RRString & | operator= (const RRString &a) |
| RRString & | operator= (const char *a) |
| RRString & | operator= (const wchar_t *a) |
| void | clear () |
| void | format (const wchar_t *fmt,...) |
| bool | operator== (const RRString &a) const |
| bool | operator== (const char *a) const |
| bool | operator== (const wchar_t *a) const |
| bool | operator!= (const RRString &a) const |
| bool | operator!= (const char *a) const |
| bool | operator!= (const wchar_t *a) const |
| const char * | c_str () const |
| const wchar_t * | w_str () const |
| bool | empty () const |
| ~RRString () | |
| void | _skipDestructor () |
Public Member Functions inherited from rr::RRUniformlyAllocated | |
| void * | operator new (std::size_t n) |
| void * | operator new[] (std::size_t n) |
| void | operator delete (void *p, std::size_t n) |
| void | operator delete[] (void *p, std::size_t n) |
Minimalistic string, for portable API.
RRString is intentionally minimalistic, for passing data, not for manipulation. Its only purpose is to replace std::[w]string in public Lightsprint headers, to make SDK compatible with any STL implementation.
Encoding:
RRString implicitly converts from and explicitly to char* and wchar_t*. Conversions from/to third party string types are explicit, using RR_* macros.
| rr::RRString::RRString | ( | ) |
| rr::RRString::RRString | ( | const RRString & | a | ) |
| rr::RRString::RRString | ( | const char * | a | ) |
| rr::RRString::RRString | ( | const wchar_t * | a | ) |
| rr::RRString::RRString | ( | unsigned | zero, |
| const wchar_t * | fmt, | ||
| ... | |||
| ) |
Initializes string using wprintf() like syntax (s for wide string, hs for singlebyte). First parameter is reserved and should be always zero.
| rr::RRString::~RRString | ( | ) |
| RRString & rr::RRString::operator= | ( | const char * | a | ) |
| RRString & rr::RRString::operator= | ( | const wchar_t * | a | ) |
| void rr::RRString::clear | ( | ) |
| void rr::RRString::format | ( | const wchar_t * | fmt, |
| ... | |||
| ) |
Sets new string value using wprintf() like syntax (s for wide string, hs for singlebyte).
| bool rr::RRString::operator== | ( | const RRString & | a | ) | const |
| bool rr::RRString::operator== | ( | const char * | a | ) | const |
| bool rr::RRString::operator== | ( | const wchar_t * | a | ) | const |
| bool rr::RRString::operator!= | ( | const RRString & | a | ) | const |
| bool rr::RRString::operator!= | ( | const char * | a | ) | const |
| bool rr::RRString::operator!= | ( | const wchar_t * | a | ) | const |
|
inline |
String in local charset. Unrepresentable characters are replaced by ?. Never returns nullptr, empty string is "".
|
inline |
String in utf16 or utf32. Never returns nullptr, empty string is L"".
|
inline |
| void rr::RRString::_skipDestructor | ( | ) |
For internal use only.