Definition at line 101 of file utfUtils.cpp.
UTFCodeParser::UTFCodeParser |
( |
| ) |
|
|
inline |
virtual UTFCodeParser::~UTFCodeParser |
( |
| ) |
|
|
inlinevirtual |
int UTFCodeParser::addChar |
( |
char |
c | ) |
|
|
inline |
Add a UTF8 character to the code.
- Parameters
-
- Returns
- number of additional characters needed. 0 = complete, -1 on Error,
Definition at line 116 of file utfUtils.cpp.
References byte, and code.
Referenced by utf16to8(), and utf8to16().
144 if ((c & 0xC0) != 0x80)
int UTFCodeParser::addChar |
( |
char16_t |
c | ) |
|
|
inline |
Add a UTF16 character to the code.
- Parameters
-
- Returns
- number of additional characters needed. 0 = complete, -1 on Error,
Definition at line 161 of file utfUtils.cpp.
References byte, and code.
165 if (c < 0xD800 || c >= 0xE000)
180 if (c < 0xDC00 || c >= 0xE000)
int UTFCodeParser::addChar |
( |
char32_t |
c | ) |
|
|
inline |
Add a UTF32 character to the code.
- Parameters
-
- Returns
- number of additional characters needed. 0 = complete, -1 on Error,
Definition at line 207 of file utfUtils.cpp.
References byte, and code.
char32_t UTFCodeParser::getCode |
( |
| ) |
|
|
inline |
Get the current character code value.
- Returns
Definition at line 268 of file utfUtils.cpp.
References code.
std::u16string UTFCodeParser::getUTF16 |
( |
| ) |
|
|
inline |
Get the current code as a UTF16 character string.
- Returns
- The UTF16 representation of the code of an empty string if the code is not valid.
Definition at line 231 of file utfUtils.cpp.
References byte, code, and codeToUTF16().
Referenced by utf8to16().
std::u16string codeToUTF16(char32_t code)
std::u32string UTFCodeParser::getUTF32 |
( |
| ) |
|
|
inline |
Get the current code as a UTF32 character string.
- Returns
- The UTF32 representation of the code of an empty string if the code is not valid.
Definition at line 244 of file utfUtils.cpp.
References byte, and code.
std::string UTFCodeParser::getUTF8 |
( |
| ) |
|
|
inline |
Get the current code as a UTF8 character string.
- Returns
- The UTF8 representation of the code of an empty string if the code is not valid.
Definition at line 218 of file utfUtils.cpp.
References byte, code, and codeToUTF8().
Referenced by utf16to8().
std::string codeToUTF8(char32_t code)
void UTFCodeParser::reset |
( |
| ) |
|
|
inline |
bool UTFCodeParser::valid |
( |
| ) |
|
|
inline |
Is this current state a valid code?
- Returns
- True if code is valid.
Definition at line 277 of file utfUtils.cpp.
References byte.
int UTFCodeParser::byte = 0 |
|
private |
char32_t UTFCodeParser::code = 0 |
|
private |
The documentation for this class was generated from the following file:
- /backups/local/src/eve/EvEmu_Crucible/src/eve-core/utils/utfUtils.cpp