Decode the specified value from the specified streamBuf, consuming exactly the specified length bytes.

Synopsis

Declared in <balber_berutil.h>

template<typename TYPE>
static
int
getValue(
    TYPE* value,
    std::streambuf* streamBuf,
    int length,
    BerDecoderOptions const& options = BerDecoderOptions());

Description

Return 0 on success, and a non‐zero value otherwise. Optionally specify decoding options to control aspects of the decoding. Note that the value consists of the contents of the bytes only (no length prefix). Also note that only fundamental C++ types, bsl::string, and BDE date/time types are supported.

Return Value

0 on success, and a non‐zero value otherwise

Parameters

Name

Description

value

destination for the decoded value

streamBuf

input stream buffer

length

number of content octets

options

decoder options controlling decoding behavior

Created with MrDocs