BloombergLP::balber::BerUtil

Utility for encoding and decoding primitive BER constructs and values.

Synopsis

Declared in <balber_berutil.h>

struct BerUtil;

Description

This utility contains functions to encode and decode primitive BER constructs and simple value semantic types. By convention, all functions return 0 on success, and a non-zero value otherwise. Also by convention, all the "get" functions take an accumNumBytesConsumed; each of the functions will add to this variable the number of bytes consumed within the scope of the function.

Enums

NameDescription
Unnamed enum Constants used as BER length sentinels.

Static Member Functions

NameDescription
getEndOfContentOctets Decode BER end-of-content octets from streamBuf.
getIdentifierOctets Decode BER identifier octets from streamBuf.
getLength Decode BER length octets from streamBuf.
getValue getValue overloads
putEndOfContentOctets Encode the "end-of-content" octets (two consecutive zero-octets) to the specified streamBuf.
putIdentifierOctets Encode the identifier octets for the specified tagClass, tagType and tagNumber to the specified streamBuf.
putIndefiniteLengthOctet Encode the BER indefinite-length octet to streamBuf.
putLength Encode the specified length to the specified streamBuf.
putValue Encode the specified value to the specified streamBuf.