nlib
nn::nlib::msgpack::MpDirectWriter Struct Reference

Defines various static member functions for directly writing MessagePack into memory. More...

#include "nn/nlib/msgpack/MpDirectWriter.h"

Static Public Member Functions

static nlib_byte_tWriteUint8 (nlib_byte_t *p, nlib_byte_t *pend, uint8_t val) noexcept
 Writes two-byte data that starts with 0xcc. More...
 
static nlib_byte_tWriteUint16 (nlib_byte_t *p, nlib_byte_t *pend, uint16_t val) noexcept
 Writes three-byte data that starts with 0xcd. More...
 
static nlib_byte_tWriteUint32 (nlib_byte_t *p, nlib_byte_t *pend, uint32_t val) noexcept
 Writes five-byte data that starts with 0xce. More...
 
static nlib_byte_tWriteUint64 (nlib_byte_t *p, nlib_byte_t *pend, uint64_t val) noexcept
 Writes nine-byte data that starts with 0xcf. More...
 
static nlib_byte_tWriteInt8 (nlib_byte_t *p, nlib_byte_t *pend, int8_t val) noexcept
 Writes two-byte data that starts with 0xd0. More...
 
static nlib_byte_tWriteInt16 (nlib_byte_t *p, nlib_byte_t *pend, int16_t val) noexcept
 Writes three-byte data that starts with 0xd1. More...
 
static nlib_byte_tWriteInt32 (nlib_byte_t *p, nlib_byte_t *pend, int32_t val) noexcept
 Writes five-byte data that starts with 0xd2. More...
 
static nlib_byte_tWriteInt64 (nlib_byte_t *p, nlib_byte_t *pend, int64_t val) noexcept
 Writes nine-byte data that starts with 0xd3. More...
 
static nlib_byte_tWriteNil (nlib_byte_t *p, nlib_byte_t *pend) noexcept
 Writes 0xc0. More...
 
static nlib_byte_tWriteBoolean (nlib_byte_t *p, nlib_byte_t *pend, bool val) noexcept
 Writes 0xc2 (if true) or 0xc3 (if false). More...
 
static nlib_byte_tWriteFloat (nlib_byte_t *p, nlib_byte_t *pend, float val) noexcept
 Writes five-byte data that starts with 0xca. More...
 
static nlib_byte_tWriteDouble (nlib_byte_t *p, nlib_byte_t *pend, double val) noexcept
 Writes nine-byte data that starts with 0xcb. More...
 
static nlib_byte_tWriteString (nlib_byte_t *p, nlib_byte_t *pend, const char *str, uint32_t len) noexcept
 Writes data according to the string length. More...
 
static nlib_byte_tWriteString (nlib_byte_t *p, nlib_byte_t *pend, const char *str) noexcept
 Returns WriteString(p, pend, str, nlib_strlen(str)).
 
static nlib_byte_tWriteStringHeader (nlib_byte_t *p, nlib_byte_t *pend, uint32_t len) noexcept
 Data according to the string length is written, but the string itself is not written. More...
 
static nlib_byte_tWriteBin (nlib_byte_t *p, nlib_byte_t *pend, const nlib_byte_t *bin, uint32_t n) noexcept
 Writes binary data according to the data size. More...
 
static nlib_byte_tWriteBinHeader (nlib_byte_t *p, nlib_byte_t *pend, uint32_t n) noexcept
 Data according to the binary data size is written, but the binary data itself is not written. More...
 
static nlib_byte_tWriteExt (nlib_byte_t *p, nlib_byte_t *pend, int8_t type, const nlib_byte_t *data, uint32_t n) noexcept
 Writes data according to the data size. More...
 
static nlib_byte_tWriteExtHeader (nlib_byte_t *p, nlib_byte_t *pend, int8_t type, uint32_t n) noexcept
 Data according to the data size is written, but the data itself is not written. More...
 
static nlib_byte_tWriteArrayHeader (nlib_byte_t *p, nlib_byte_t *pend, uint32_t count) noexcept
 Writes data according to the number of elements in the array. More...
 
static nlib_byte_tWriteMapHeader (nlib_byte_t *p, nlib_byte_t *pend, uint32_t count) noexcept
 Writes data according to the number of elements in the array. More...
 
static nlib_byte_tWriteUnsignedInt (nlib_byte_t *p, nlib_byte_t *pend, uint8_t val) noexcept
 Encodes the provided numerical data into data with the minimum length. Writes data of a size up to two bytes. More...
 
static nlib_byte_tWriteUnsignedInt (nlib_byte_t *p, nlib_byte_t *pend, uint16_t val) noexcept
 Encodes the provided numerical data into data with the minimum length. Writes data of a size up to three bytes. More...
 
static nlib_byte_tWriteUnsignedInt (nlib_byte_t *p, nlib_byte_t *pend, uint32_t val) noexcept
 Encodes the provided numerical data into data with the minimum length. Writes data of a size up to five bytes. More...
 
static nlib_byte_tWriteUnsignedInt (nlib_byte_t *p, nlib_byte_t *pend, uint64_t val) noexcept
 Encodes the provided numerical data into data with the minimum length. Writes data of a size up to nine bytes. More...
 
static nlib_byte_tWriteInt (nlib_byte_t *p, nlib_byte_t *pend, int8_t val) noexcept
 Encodes the provided numerical data into data with the minimum length. Writes data of a size up to two bytes. More...
 
static nlib_byte_tWriteInt (nlib_byte_t *p, nlib_byte_t *pend, int16_t val) noexcept
 Encodes the provided numerical data into data with the minimum length. Writes data of a size up to three bytes. More...
 
static nlib_byte_tWriteInt (nlib_byte_t *p, nlib_byte_t *pend, int32_t val) noexcept
 Encodes the provided numerical data into data with the minimum length. Writes data of a size up to five bytes. More...
 
static nlib_byte_tWriteInt (nlib_byte_t *p, nlib_byte_t *pend, int64_t val) noexcept
 Encodes the provided numerical data into data with the minimum length. Writes data of a size up to nine bytes. More...
 
static nlib_byte_tWriteTimestamp (nlib_byte_t *p, nlib_byte_t *pend, int64_t sec, uint32_t nsec) noexcept
 Encodes the provided time data into data with the minimum length. Writes data of a size up to 15 bytes. More...
 
static nlib_byte_tWriteTimestamp (nlib_byte_t *p, nlib_byte_t *pend, nlib_time val) noexcept
 Encodes the provided time data into data with the minimum length. Writes data of a size up to 15 bytes. More...
 

Detailed Description

Defines various static member functions for directly writing MessagePack into memory.

Definition at line 23 of file MpDirectWriter.h.

Member Function Documentation

◆ WriteArrayHeader()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteArrayHeader ( nlib_byte_t p,
nlib_byte_t pend,
uint32_t  count 
)
inlinestaticnoexcept

Writes data according to the number of elements in the array.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]countNumber of elements in the array.
Returns
Pointer to the position immediately before the array if successful, or NULL if the area size is insufficient for data to be written.
Description
The first byte differs depending on the data size, and data of a size up to 5 + n bytes is written. The user must write n elements in the array after executing this function.
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-array

Definition at line 402 of file MpDirectWriter.h.

◆ WriteBin()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteBin ( nlib_byte_t p,
nlib_byte_t pend,
const nlib_byte_t bin,
uint32_t  n 
)
inlinestaticnoexcept

Writes binary data according to the data size.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]binBinary data.
[in]nData size.
Returns
Pointer to the position immediately after the binary data if successful, or NULL if the area size is insufficient for data to be written.
Description
The first byte differs depending on the data size, and data of a size up to 5 + n bytes is written.
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-bin

Definition at line 268 of file MpDirectWriter.h.

◆ WriteBinHeader()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteBinHeader ( nlib_byte_t p,
nlib_byte_t pend,
uint32_t  n 
)
inlinestaticnoexcept

Data according to the binary data size is written, but the binary data itself is not written.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]nData size.
Returns
Pointer to the position immediately before the binary data if successful, or NULL if the area size is insufficient for data to be written.
Description
The user must additionally write n bytes of binary data after executing this function.

Definition at line 249 of file MpDirectWriter.h.

◆ WriteBoolean()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteBoolean ( nlib_byte_t p,
nlib_byte_t pend,
bool  val 
)
inlinestaticnoexcept

Writes 0xc2 (if true) or 0xc3 (if false).

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
p + 1 if successful, or NULL if the area size is insufficient for data to be written.
Description
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-bool

Definition at line 162 of file MpDirectWriter.h.

◆ WriteDouble()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteDouble ( nlib_byte_t p,
nlib_byte_t pend,
double  val 
)
inlinestaticnoexcept

Writes nine-byte data that starts with 0xcb.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
p + 9 if successful, or NULL if the area size is insufficient for data to be written.
Description
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-float

Definition at line 180 of file MpDirectWriter.h.

◆ WriteExt()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteExt ( nlib_byte_t p,
nlib_byte_t pend,
int8_t  type,
const nlib_byte_t data,
uint32_t  n 
)
inlinestaticnoexcept

Writes data according to the data size.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]typeData type.
[in]dataData.
[in]nData size.
Returns
Pointer to the position immediately after the data if successful, or NULL if the area size is insufficient for data to be written.
Description
The first byte differs depending on the data size, and data of a size up to 6 + n bytes is written.
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-ext

Definition at line 342 of file MpDirectWriter.h.

◆ WriteExtHeader()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteExtHeader ( nlib_byte_t p,
nlib_byte_t pend,
int8_t  type,
uint32_t  n 
)
inlinestaticnoexcept

Data according to the data size is written, but the data itself is not written.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]typeData type.
[in]nData size.
Returns
Pointer to the position immediately before the data if successful, or NULL if the area size is insufficient for data to be written.
Description
The user must additionally write n bytes of data after executing this function.

Definition at line 291 of file MpDirectWriter.h.

◆ WriteFloat()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteFloat ( nlib_byte_t p,
nlib_byte_t pend,
float  val 
)
inlinestaticnoexcept

Writes five-byte data that starts with 0xca.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
p + 5 if successful, or NULL if the area size is insufficient for data to be written.
Description
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-float

Definition at line 168 of file MpDirectWriter.h.

◆ WriteInt() [1/4]

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteInt ( nlib_byte_t p,
nlib_byte_t pend,
int8_t  val 
)
inlinestaticnoexcept

Encodes the provided numerical data into data with the minimum length. Writes data of a size up to two bytes.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
Pointer to the position immediately after the numerical value if successful, or NULL if the area size is insufficient for data to be written.

Definition at line 490 of file MpDirectWriter.h.

◆ WriteInt() [2/4]

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteInt ( nlib_byte_t p,
nlib_byte_t pend,
int16_t  val 
)
inlinestaticnoexcept

Encodes the provided numerical data into data with the minimum length. Writes data of a size up to three bytes.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
Pointer to the position immediately after the numerical value if successful, or NULL if the area size is insufficient for data to be written.

Definition at line 500 of file MpDirectWriter.h.

◆ WriteInt() [3/4]

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteInt ( nlib_byte_t p,
nlib_byte_t pend,
int32_t  val 
)
inlinestaticnoexcept

Encodes the provided numerical data into data with the minimum length. Writes data of a size up to five bytes.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
Pointer to the position immediately after the numerical value if successful, or NULL if the area size is insufficient for data to be written.

Definition at line 516 of file MpDirectWriter.h.

◆ WriteInt() [4/4]

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteInt ( nlib_byte_t p,
nlib_byte_t pend,
int64_t  val 
)
inlinestaticnoexcept

Encodes the provided numerical data into data with the minimum length. Writes data of a size up to nine bytes.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
Pointer to the position immediately after the numerical value if successful, or NULL if the area size is insufficient for data to be written.

Definition at line 536 of file MpDirectWriter.h.

◆ WriteInt16()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteInt16 ( nlib_byte_t p,
nlib_byte_t pend,
int16_t  val 
)
inlinestaticnoexcept

Writes three-byte data that starts with 0xd1.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
p + 3 if successful, or NULL if the area size is insufficient for data to be written.
Description
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-int

Definition at line 135 of file MpDirectWriter.h.

◆ WriteInt32()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteInt32 ( nlib_byte_t p,
nlib_byte_t pend,
int32_t  val 
)
inlinestaticnoexcept

Writes five-byte data that starts with 0xd2.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
p + 5 if successful, or NULL if the area size is insufficient for data to be written.
Description
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-int

Definition at line 142 of file MpDirectWriter.h.

◆ WriteInt64()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteInt64 ( nlib_byte_t p,
nlib_byte_t pend,
int64_t  val 
)
inlinestaticnoexcept

Writes nine-byte data that starts with 0xd3.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
p + 9 if successful, or NULL if the area size is insufficient for data to be written.
Description
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-int

Definition at line 149 of file MpDirectWriter.h.

◆ WriteInt8()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteInt8 ( nlib_byte_t p,
nlib_byte_t pend,
int8_t  val 
)
inlinestaticnoexcept

Writes two-byte data that starts with 0xd0.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
p + 2 if successful, or NULL if the area size is insufficient for data to be written.
Description
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-int

Definition at line 128 of file MpDirectWriter.h.

◆ WriteMapHeader()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteMapHeader ( nlib_byte_t p,
nlib_byte_t pend,
uint32_t  count 
)
inlinestaticnoexcept

Writes data according to the number of elements in the array.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]countNumber of elements (pairs of a key and value) in the map.
Returns
Pointer to the position immediately before the map if successful, or NULL if the area size is insufficient for data to be written.
Description
The first byte differs depending on the data size, and data of a size up to 5 + n bytes is written. The user must write 2 * n elements (n pairs of a key and value) after executing this function.
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-map

Definition at line 421 of file MpDirectWriter.h.

◆ WriteNil()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteNil ( nlib_byte_t p,
nlib_byte_t pend 
)
inlinestaticnoexcept

Writes 0xc0.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
Returns
p + 1 if successful, or NULL if the area size is insufficient for data to be written.
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-nil

Definition at line 156 of file MpDirectWriter.h.

◆ WriteString()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteString ( nlib_byte_t p,
nlib_byte_t pend,
const char *  str,
uint32_t  len 
)
inlinestaticnoexcept

Writes data according to the string length.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]strThe string to be serialized.
[in]lenSpecifies the string length.
Returns
Pointer to the position immediately after the string if successful, or NULL if the area size is insufficient for data to be written.
Description
The first byte differs depending on the string length, and data of a size up to 5 + len bytes is written.
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-str

Definition at line 216 of file MpDirectWriter.h.

◆ WriteStringHeader()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteStringHeader ( nlib_byte_t p,
nlib_byte_t pend,
uint32_t  len 
)
inlinestaticnoexcept

Data according to the string length is written, but the string itself is not written.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]lenSpecifies the string length.
Returns
Pointer to the position immediately before the string body if successful, or NULL if the area size is insufficient for data to be written.
Description
The user must additionally write len bytes of string data after executing this function.

Definition at line 192 of file MpDirectWriter.h.

◆ WriteTimestamp() [1/2]

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteTimestamp ( nlib_byte_t p,
nlib_byte_t pend,
int64_t  sec,
uint32_t  nsec 
)
inlinestaticnoexcept

Encodes the provided time data into data with the minimum length. Writes data of a size up to 15 bytes.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]secThe integer part (in seconds) of the time elapsed from 1970-01-01.
[in]nsecThe decimal part (in nanoseconds) of the time elapsed from 1970-01-01.
Returns
Pointer to the position immediately after the time data if successful, or NULL if the area size is insufficient for data to be written.
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-timestamp

Definition at line 548 of file MpDirectWriter.h.

◆ WriteTimestamp() [2/2]

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteTimestamp ( nlib_byte_t p,
nlib_byte_t pend,
nlib_time  val 
)
inlinestaticnoexcept

Encodes the provided time data into data with the minimum length. Writes data of a size up to 15 bytes.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe time data to be serialized.
Returns
Pointer to the position immediately after the time data if successful, or NULL if the area size is insufficient for data to be written.
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-timestamp

Definition at line 578 of file MpDirectWriter.h.

◆ WriteUint16()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteUint16 ( nlib_byte_t p,
nlib_byte_t pend,
uint16_t  val 
)
inlinestaticnoexcept

Writes three-byte data that starts with 0xcd.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
p + 3 if successful, or NULL if the area size is insufficient for data to be written.
Description
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-int

Definition at line 107 of file MpDirectWriter.h.

◆ WriteUint32()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteUint32 ( nlib_byte_t p,
nlib_byte_t pend,
uint32_t  val 
)
inlinestaticnoexcept

Writes five-byte data that starts with 0xce.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
p + 5 if successful, or NULL if the area size is insufficient for data to be written.
Description
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-int

Definition at line 114 of file MpDirectWriter.h.

◆ WriteUint64()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteUint64 ( nlib_byte_t p,
nlib_byte_t pend,
uint64_t  val 
)
inlinestaticnoexcept

Writes nine-byte data that starts with 0xcf.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
p + 9 if successful, or NULL if the area size is insufficient for data to be written.
Description
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-int

Definition at line 121 of file MpDirectWriter.h.

◆ WriteUint8()

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteUint8 ( nlib_byte_t p,
nlib_byte_t pend,
uint8_t  val 
)
inlinestaticnoexcept

Writes two-byte data that starts with 0xcc.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
p + 2 if successful, or NULL if the area size is insufficient for data to be written.
Description
See also
https://github.com/msgpack/msgpack/blob/master/spec.md#formats-int

Definition at line 99 of file MpDirectWriter.h.

◆ WriteUnsignedInt() [1/4]

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteUnsignedInt ( nlib_byte_t p,
nlib_byte_t pend,
uint8_t  val 
)
inlinestaticnoexcept

Encodes the provided numerical data into data with the minimum length. Writes data of a size up to two bytes.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
Pointer to the position immediately after the numerical value if successful, or NULL if the area size is insufficient for data to be written.

Definition at line 440 of file MpDirectWriter.h.

◆ WriteUnsignedInt() [2/4]

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteUnsignedInt ( nlib_byte_t p,
nlib_byte_t pend,
uint16_t  val 
)
inlinestaticnoexcept

Encodes the provided numerical data into data with the minimum length. Writes data of a size up to three bytes.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
Pointer to the position immediately after the numerical value if successful, or NULL if the area size is insufficient for data to be written.

Definition at line 451 of file MpDirectWriter.h.

◆ WriteUnsignedInt() [3/4]

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteUnsignedInt ( nlib_byte_t p,
nlib_byte_t pend,
uint32_t  val 
)
inlinestaticnoexcept

Encodes the provided numerical data into data with the minimum length. Writes data of a size up to five bytes.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
Pointer to the position immediately after the numerical value if successful, or NULL if the area size is insufficient for data to be written.

Definition at line 464 of file MpDirectWriter.h.

◆ WriteUnsignedInt() [4/4]

nlib_byte_t * nn::nlib::msgpack::MpDirectWriter::WriteUnsignedInt ( nlib_byte_t p,
nlib_byte_t pend,
uint64_t  val 
)
inlinestaticnoexcept

Encodes the provided numerical data into data with the minimum length. Writes data of a size up to nine bytes.

Parameters
[in]pPointer to the area that serialized data is written into.
[in]pendThe end of the area that data can be written into.
[in]valThe value to be serialized.
Returns
Pointer to the position immediately after the numerical value if successful, or NULL if the area size is insufficient for data to be written.

Definition at line 481 of file MpDirectWriter.h.


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