Components in the bdlde package provide character encoding utilities.

Types

Name

Description

Base64Alphabet

This struct provides a namespace for enumerating the set of alphabets. See Enum in the TYPES sub‐section for details.

Base64Decoder

This class implements a mechanism capable of converting data of arbitrary length from its corresponding Base64 representation.

Base64DecoderOptions

This class stores the configuration of a Base64Decoder.

Base64Encoder

This class implements a mechanism capable of converting data of arbitrary length to its corresponding Base64 representation.

Base64EncoderOptions

This class stores the configuration of a Base64Encoder.

Base64IgnoreMode

This struct provides a namespace for enumerating the set of ignore modes. See Enum in the TYPES sub‐section for details.

ByteOrder

This struct provides a namespace for enumerating the set of byte orders. See Enum in the TYPES sub‐section for details.

CharConvertStatus

This struct provides a namespace for enumerating the set of mask codes that can be used to interpret int return values from translation functions in bdede.

CharConvertUcs2

This struct provides a namespace for a suite of pure procedures to convert character buffers between UTF‐8 and UCS‐2. UCS‐2 conversions are performed to/from the full 2 ˆ 16 bit space (the "UTF‐16" hole U+D800‐U+DFFF is not treated as a special case). Note that all C‐style routines in this component honor strlcpy semantics, meaning that all returned C‐style strings will be null‐terminated as long as the return buffer size is positive (i.e., dstCapacity > 0). Note that since all UCS‐2 operations take place as `unsigned short`s, byte order is not taken into consideration, and Byte Order Mark (BOM) characters are not generated. If a BOM is present in the input, it will be translated into the output.

CharConvertUtf16

This struct provides a namespace for a suite of static functions to convert buffers or containers between UTF‐8 and UTF‐16. Note that Byte Order Mark (BOM) sequences are neither generated nor recognized as special. If a BOM is present in the input, it will be translated, whether correct (0xfeff) or incorrect (0xfffe), into the output without any special handling.

CharConvertUtf32

This struct provides a namespace for a suite of static functions to convert buffers between UTF‐8 and UTF‐32. Byte Order Mark (BOM) code points are neither generated nor recognized as special, and thus may be incorrect for the actual byte order of output. If a BOM is present in the input, it will be translated, whether correct (0xfeff) or incorrect (0xfffe), into the output without any special handling.

Crc32

This class represents a CRC‐32 checksum value that can be updated as data is provided.

Crc32c

This class provides runtime‐efficient utilities to calculate a CRC32‐C checksum.

Crc64

This class represents a CRC‐64 checksum value that can be updated as data is provided.

HexDecoder

This class implements a mechanism capable of converting data of arbitrary length from its corresponding Hex representation.

HexEncoder

This class implements a mechanism capable of converting data of arbitrary length to its corresponding Hex representation.

Md5

This class represents an MD5 digest that can be updated as additional data is provided.

QuotedPrintableDecoder

This class implements a mechanism capable of converting data of arbitrary length from its corresponding Quoted‐Printable representation.

QuotedPrintableEncoder

This class implements a mechanism capable of converting data of arbitrary length to its corresponding Quoted‐Printable representation.

Sha1

This class represents a SHA‐1 digest that can be updated as additional data is provided.

Sha224

This class represents a SHA‐224 digest that can be updated as additional data is provided.

Sha256

This class represents a SHA‐256 digest that can be updated as additional data is provided.

Sha384

This class represents a SHA‐384 digest that can be updated as additional data is provided.

Sha512

This class represents a SHA‐512 digest that can be updated as additional data is provided.

Utf8CheckingInStreamBufWrapper

This class inherits from bsl::streambuf, and holds and wraps another streambuf. It forwards input through the held streambuf, and checks for invalid UTF‐8. The wrapping object does not support ouput, only input. If the held streambuf supports seeking, seeks are supported, though not forward seeks, and pubseekoff(0, bsl::ios_base::cur) is supported whether the wrapped streambuf supports seeking or not.

Utf8Util

This struct provides a namespace for static methods used for validating UTF‐8 strings, for counting the number of Unicode code points in them, for advancing pointers through UTF‐8 strings by a specified number of Unicode code points, for counting the number of bytes a UTF‐8 leading substring occupies, for counting the number of bytes in a UTF‐8 character, and for appending a Unicode character to a UTF‐8 string.

Functions

Name

Description

operator<<

Stream insertion operators

operator==

Equality operators

operator!=

Inequality operators

Created with MrDocs