[#BloombergLP-baljsn-DatumUtil-decode-0b5] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/baljsn.adoc[baljsn]::xref:BloombergLP/baljsn/DatumUtil.adoc[DatumUtil]::decode :relfileprefix: ../../../ :mrdocs: `decode` overloads == Synopses Declared in `<baljsn_datumutil.h>` Decode the specified `json` into the specified `result`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static int xref:BloombergLP/baljsn/DatumUtil/decode-0e.adoc[decode]( xref:BloombergLP/bdld/ManagedDatum.adoc[bdld::ManagedDatum]* result, std::string_view const& json); ---- [.small]#xref:BloombergLP/baljsn/DatumUtil/decode-0e.adoc[_» more..._]# Decode JSON from the specified `jsonBuffer` into the specified `result`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static int xref:BloombergLP/baljsn/DatumUtil/decode-01c.adoc[decode]( xref:BloombergLP/bdld/ManagedDatum.adoc[bdld::ManagedDatum]* result, std::streambuf* jsonBuffer); ---- [.small]#xref:BloombergLP/baljsn/DatumUtil/decode-01c.adoc[_» more..._]# Decode `json` into `result`, using the specified `options`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static int xref:BloombergLP/baljsn/DatumUtil/decode-0b4.adoc[decode]( xref:BloombergLP/bdld/ManagedDatum.adoc[bdld::ManagedDatum]* result, std::string_view const& json, xref:BloombergLP/baljsn/DatumDecoderOptions.adoc[DatumDecoderOptions] const& options); ---- [.small]#xref:BloombergLP/baljsn/DatumUtil/decode-0b4.adoc[_» more..._]# Decode `json` into `result`, writing errors to `errorStream`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static int xref:BloombergLP/baljsn/DatumUtil/decode-00.adoc[decode]( xref:BloombergLP/bdld/ManagedDatum.adoc[bdld::ManagedDatum]* result, std::ostream* errorStream, std::string_view const& json); ---- [.small]#xref:BloombergLP/baljsn/DatumUtil/decode-00.adoc[_» more..._]# Decode JSON from `jsonBuffer` into `result`, writing errors to `errorStream`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static int xref:BloombergLP/baljsn/DatumUtil/decode-017.adoc[decode]( xref:BloombergLP/bdld/ManagedDatum.adoc[bdld::ManagedDatum]* result, std::ostream* errorStream, std::streambuf* jsonBuffer); ---- [.small]#xref:BloombergLP/baljsn/DatumUtil/decode-017.adoc[_» more..._]# Decode JSON from `jsonBuffer` into `result`, using the specified `options`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static int xref:BloombergLP/baljsn/DatumUtil/decode-0f.adoc[decode]( xref:BloombergLP/bdld/ManagedDatum.adoc[bdld::ManagedDatum]* result, std::streambuf* jsonBuffer, xref:BloombergLP/baljsn/DatumDecoderOptions.adoc[DatumDecoderOptions] const& options); ---- [.small]#xref:BloombergLP/baljsn/DatumUtil/decode-0f.adoc[_» more..._]# Decode `json` into `result`, writing errors to `errorStream`, using `options`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static int xref:BloombergLP/baljsn/DatumUtil/decode-09.adoc[decode]( xref:BloombergLP/bdld/ManagedDatum.adoc[bdld::ManagedDatum]* result, std::ostream* errorStream, std::string_view const& json, xref:BloombergLP/baljsn/DatumDecoderOptions.adoc[DatumDecoderOptions] const& options); ---- [.small]#xref:BloombergLP/baljsn/DatumUtil/decode-09.adoc[_» more..._]# Decode JSON from `jsonBuffer` into `result`, writing errors to `errorStream`, using `options`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static int xref:BloombergLP/baljsn/DatumUtil/decode-0a.adoc[decode]( xref:BloombergLP/bdld/ManagedDatum.adoc[bdld::ManagedDatum]* result, std::ostream* errorStream, std::streambuf* jsonBuffer, xref:BloombergLP/baljsn/DatumDecoderOptions.adoc[DatumDecoderOptions] const& options); ---- [.small]#xref:BloombergLP/baljsn/DatumUtil/decode-0a.adoc[_» more..._]# == Return Value 0 on success, and a negative value otherwise == Parameters [cols="1,4"] |=== | Name| Description | *result* | receives the decoded `Datum` | *json* | JSON text to decode | *jsonBuffer* | stream buffer providing JSON text | *options* | decoding options | *errorStream* | optional stream for parse‐error descriptions |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#