|
BDE 4.39.x Production Release
|
Basic Development Library Data Encoder (bdlde)
Mechanisms for standard encodings and hashings, e.g., base64, md5.
Basic Development Library Data Encoder (bdlde)
The 'bdlde' package provides mechanisms (typically in the form of fully value-semantic objects) for performing various standard hashings of an input dataset, for, e.g., basic encoding, check-sums, and cryptographic hashes.
The 'bdlde' package currently has 23 components having 4 levels of physical dependency. The list below shows the hierarchical ordering of the components. The order of components within each level is not architecturally significant, just alphabetical.
bdlde_base64alphabet : Provide an enumeration of the set of possible base 64 alphabets.
bdlde_base64decoder : Provide automata for converting to and from Base64 encodings.
bdlde_base64decoderoptions : Provide value-semantic attribute class for decoder options.
bdlde_base64encoder : Provide automata for converting to and from Base64 encodings.
bdlde_base64encoderoptions : Provide a value-semantic attribute class for encoder options.
bdlde_base64ignoremode : Provide an enumeration of the set of possible base64 ignore modes.
bdlde_byteorder : Provide an enumeration of the set of possible byte orders.
bdlde_charconvertstatus : Provide masks for interpreting status from charconvert functions.
bdlde_charconvertucs2 : Provide efficient conversions between UTF-8 and UCS-2 encodings.
bdlde_charconvertutf16 : Provide fast, safe conversion between UTF-8 and UTF-16 encodings.
bdlde_charconvertutf32 : Provide fast, safe conversion between UTF-8 encoding and UTF-32.
bdlde_crc32 : Provide a mechanism for computing the CRC-32 checksum of a dataset.
bdlde_crc32c : Provide utilities to calculate the CRC32-C checksum of a dataset.
bdlde_crc64 : Provide a mechanism for computing the CRC-64 checksum of a dataset.
bdlde_hexdecoder : Provide mechanism for decoding text from hexadecimal.
bdlde_hexencoder : Provide mechanism for encoding text into hexadecimal.
'bdlde_md5': Provide a value-semantic type encoding a message in an MD5 digest.
bdlde_quotedprintabledecoder : Provide automata converting to and from Quoted-Printable encodings.
bdlde_quotedprintableencoder : Provide automata converting to and from Quoted-Printable encodings.
bdlde_sha1 : Provide a value-semantic type encoding a message in a SHA-1 digest.
bdlde_sha2 : Provide a value-semantic type encoding a message in a SHA-2 digest.
bdlde_utf8checkinginstreambufwrapper : Provide a stream buffer wrapper for validating UTF-8 input.
bdlde_utf8util : Provide basic utilities for UTF-8 encodings.
This section illustrates intended use of this package.
The following snippets of code illustrate a typical use of the 'bdlde_Crc32' class. Each function would typically execute in separate processes or potentially on separate machines. The 'senderExample' function below demonstrates how a message sender can write a message and its CRC-32 checksum to a 'bdlx' output stream. Note that 'Out' may be a 'typedef' of any class that implements the 'bdlx_OutStream' protocol:
The 'receiverExample' function below illustrates how a message receiver can read a message and its CRC-32 checksum from a 'bdlx' input stream, then perform a local CRC-32 computation to verify that the message was received intact. Note that 'In' may be a 'typedef' of any class that implements the 'bdlx_InStream' protocol:
The following snippets of code illustrate a typical use of the 'bdlde_Md5' class. Each function would typically execute in separate processes or potentially on separate machines. The 'senderExample' function below demonstrates how a message sender can write a message and its MD5 hash to a 'bdlx' output stream. Note that 'Out' may be a 'typedef' of any class that implements the 'bdlx_OutStream' protocol:
The 'receiverExample' function below illustrates how a message receiver can read a message and its MD5 hash from a 'bdlx' input stream, then perform a local MD5 computation to verify that the message was received intact. Note that 'In' may be a 'typedef' of any class that implements the 'bdlx_InStream' protocol: