SourcePro® 2022.1 |
SourcePro® API Reference Guide |
Converts char
, RWCString or std::string UTF-8 values to UTF-16.
More...
#include <rw/stream/RWFromUTF8Converter.h>
Public Member Functions | |
void | convert (char from, RWUChar &to) |
void | convert (char from, wchar_t &to) |
void | convert (char from, RWWString &to) |
void | convert (const char *from, size_t len, RWWString &to) |
void | convert (const RWCString &from, RWWString &to) |
void | convert (const std::string &from, RWWString &to) |
RWFromUTF8Converter converts char
, RWCString or std::string UTF-8 values to UTF-16. The character or string to be converted must be encoded in UTF-8. To translate other encodings, use converters supplied by the Internationalization Module. All characters or strings must contain complete UTF-8 characters. Partial encodings will result in the converter throwing an RWExternalStreamException.
void RWFromUTF8Converter::convert | ( | char | from, |
RWUChar & | to | ||
) |
Converts a single byte UTF-8 char to UTF-16 encoded RWUChar.
from | contains the UTF-8 character to convert |
to | returns the resulting UTF-16 character |
void RWFromUTF8Converter::convert | ( | char | from, |
wchar_t & | to | ||
) |
Converts a single byte UTF-8 char to UTF-16 encoded wchar_t
.
void RWFromUTF8Converter::convert | ( | char | from, |
RWWString & | to | ||
) |
Converts a single byte UTF-8 char to a UTF-16 encoded RWWString.
void RWFromUTF8Converter::convert | ( | const char * | from, |
size_t | len, | ||
RWWString & | to | ||
) |
Converts one or more UTF-8 chars to a UTF-16 encoded RWWString.
Copyright © 2022 Rogue Wave Software, Inc., a Perforce company. All Rights Reserved. |