9#ifndef INCLUDED_BSLFMT_UNICODECODEPOINT
10#define INCLUDED_BSLFMT_UNICODECODEPOINT
56#include <bslscm_version.h>
85 unsigned long int d_codePointValue;
93 void extractUtf8(
const void *bytes,
size_t maxBytes);
104 void extractUtf16(
const void *bytes,
size_t maxBytes);
115 void extractUtf32(
const void *bytes,
size_t maxBytes);
190 extractUtf8(bytes, maxBytes);
193 extractUtf16(bytes, maxBytes);
196 extractUtf32(bytes, maxBytes);
209 d_numSourceBytes = 0;
210 d_codePointValue = 0;
211 d_codePointWidth = 0;
224 return d_numSourceBytes;
230 return d_codePointValue;
236 return d_codePointWidth;
Definition bslfmt_unicodecodepoint.h:76
int codePointWidth() const
Return the width of this code point.
Definition bslfmt_unicodecodepoint.h:234
unsigned long int codePointValue() const
Return the value of this code point.
Definition bslfmt_unicodecodepoint.h:228
void extract(UtfEncoding encoding, const void *bytes, size_t maxBytes)
Definition bslfmt_unicodecodepoint.h:184
int numSourceBytes() const
Return the number of bytes occupied by this code point.
Definition bslfmt_unicodecodepoint.h:222
UnicodeCodePoint()
Create an uninitialized Unicode code point object.
Definition bslfmt_unicodecodepoint.h:177
UtfEncoding
Definition bslfmt_unicodecodepoint.h:79
@ e_UTF16
Definition bslfmt_unicodecodepoint.h:79
@ e_UTF8
Definition bslfmt_unicodecodepoint.h:79
@ e_UTF32
Definition bslfmt_unicodecodepoint.h:79
void reset()
Reset this object to the default state.
Definition bslfmt_unicodecodepoint.h:206
bool isValid() const
Definition bslfmt_unicodecodepoint.h:216
#define BSLA_UNREACHABLE
Definition bsla_unreachable.h:159
#define BSLS_ASSERT_OPT_UNREACHABLE(X)
Definition bsls_assert.h:2065
#define BSLS_IDENT(str)
BSLS_IDENT() - insert string into .comment binary segment (if supported)
Definition bsls_ident.h:238
Definition bslfmt_enablestreamedformatter.h:130