Simox  2.3.74.0
nlohmann::detail::binary_reader< BasicJsonType, SAX > Class Template Reference

deserialization of CBOR, MessagePack, and UBJSON values More...

Public Member Functions

 binary_reader (input_adapter_t adapter)
 create a binary reader More...
 
bool sax_parse (const input_format_t format, json_sax_t *sax_, const bool strict=true)
 

Static Public Member Functions

static constexpr bool little_endianess (int num=1) noexcept
 determine system byte order More...
 

Detailed Description

template<typename BasicJsonType, typename SAX = json_sax_dom_parser<BasicJsonType>>
class nlohmann::detail::binary_reader< BasicJsonType, SAX >

deserialization of CBOR, MessagePack, and UBJSON values

Constructor & Destructor Documentation

◆ binary_reader()

template<typename BasicJsonType , typename SAX = json_sax_dom_parser<BasicJsonType>>
nlohmann::detail::binary_reader< BasicJsonType, SAX >::binary_reader ( input_adapter_t  adapter)
inlineexplicit

create a binary reader

Parameters
[in]adapterinput adapter to read from

Member Function Documentation

◆ little_endianess()

template<typename BasicJsonType , typename SAX = json_sax_dom_parser<BasicJsonType>>
static constexpr bool nlohmann::detail::binary_reader< BasicJsonType, SAX >::little_endianess ( int  num = 1)
inlinestaticnoexcept

determine system byte order

Returns
true if and only if system's byte order is little endian
Note
from http://stackoverflow.com/a/1001328/266378

◆ sax_parse()

template<typename BasicJsonType , typename SAX = json_sax_dom_parser<BasicJsonType>>
bool nlohmann::detail::binary_reader< BasicJsonType, SAX >::sax_parse ( const input_format_t  format,
json_sax_t *  sax_,
const bool  strict = true 
)
inline
Parameters
[in]formatthe binary format to parse
[in]sax_a SAX event processor
[in]strictwhether to expect the input to be consumed completed
Returns