nlib
nn::nlib::msgpack::JsonStreamParser::Token Struct Reference

Stores data on the tokens obtained by the parser. More...

#include <manual_en.h>

Public Attributes

Event event
 The event returned by Next().
 
char * buf
 Stores strings or binary data. More...
 
union {
number
 The union to store numeric data. The data member to be used differs depending on the event. More...
 
bool token_toobig
 When the event is EVENT_STRING and the token is too large, stores a non-zero value. In this case, a null string is set to buf.
 
int8_t ext
 When the event is EVENT_EXT, stores a data type 8-bit value.
 

Detailed Description

Stores data on the tokens obtained by the parser.

Definition at line 75 of file JsonStreamParser.h.

Member Data Documentation

§ buf

nn::nlib::msgpack::JsonStreamParser::Token::buf

Stores strings or binary data.

Description
Event Description
EVENT_STRING Stores a null-terminated string.
EVENT_KEY_NAME Stores a null-terminated string.
EVENT_BINARY Stores binary data.
EVENT_EXT Stores binary data.

Definition at line 77 of file JsonStreamParser.h.

§ number

nn::nlib::msgpack::JsonStreamParser::Token::number

The union to store numeric data. The data member to be used differs depending on the event.

Description
Event Data member Description
EVENT_STRING size Stores the string length.
EVENT_KEY_NAME size Stores the string length.
EVENT_BINARY size Stores the binary data size.
EVENT_EXT size Stores the binary data size.
EVENT_NUMBER_INT64 i64 Stores a number.
EVENT_NUMBER_UINT64 u64 Stores a number.
EVENT_NUMBER_DOUBLE f64 Stores a number.
EVENT_NUMBER_INT32 i32 Stores a number.
EVENT_NUMBER_UINT32 u32 Stores a number.
EVENT_NUMBER_FLOAT f32 Stores a number.

The documentation for this struct was generated from the following files: