template < class Elem, unsigned long MaxCode = 0x10ffffUL, codecvt_mode Mode = (codecvt_mode)0 > class codecvt_utf16 : public codecvt <Elem, char, mbstate_t>
label | value | description |
---|---|---|
consume_header | 4 | An optional initial header sequence (BOM) is read to determine whether a multibyte sequence converted in is big-endian or little-endian. |
generate_header | 2 | An initial header sequence (BOM) shall be generated to indicate whether a multibyte sequence converted out is big-endian or little-endian. |
little_endian | 1 | The multibyte sequence generated on conversions out shall be little-endian (as opposed to the default big-endian). |
member type | definition | notes |
---|---|---|
intern_type | The first template parameter (Elem) | The internal character type (wide character type). |
extern_type | char | The external character type (multibyte character type). |
state_type | mbstate_t | Conversion state type (see mbstate_t). |
result | codecvt_base::result | Enum type with the result of a conversion operation (see codecvt_base::result). |
member function | behavior in codecvt_utf16 |
---|---|
do_always_no_conv | Returns 0 (not all conversions will yield a noconv result). |
do_encoding | Returns 0 (the external encoding is not fixed-width). |
do_in | Converts from UTF-16 to the fixed-width equivalent of type Elem. |
do_length | Returns length (for codecvt::length). |
do_max_length | Returns the maximum length (in bytes) of a code point. |
do_out | Converts from the fixed-width wide character encoding (UCS-2 / UCS-4) to UTF-16. |
do_unshift | Brings the mbstate_t object to an initial state. |
(destructor) | Releases resources. |
|
|
Writing to file (UTF-16)... done! |