Macros to serialize/deserialize primitives to/from a memory buffer. More...
Go to the source code of this file.
Macros | |
#define | HT_THROW_INPUT_OVERRUN(_s_) |
#define | HT_THROW_BAD_VSTR(_s_) |
#define | HT_THROW_BAD_VINT(_s_) |
#define | HT_THROW_UNPOSSIBLE(_s_) |
#define | HT_DECODE_NEED(_r_, _l_) |
#define | HT_ENCODE_BOOL(_op_, _v_) *(_op_)++ = (_v_) ? 1 : 0 |
#define | HT_ENCODE_I8(_op_, _v_) *(_op_)++ = _v_ |
#define | HT_DECODE_I8(_ip_, _r_, _v_) |
#define | HT_ENCODE_I16(_op_, _v_) |
#define | HT_DECODE_I16(_ip_, _r_, _v_) |
#define | HT_ENCODE_I32(_op_, _v_) |
#define | HT_DECODE_I32(_ip_, _r_, _v_) |
#define | HT_ENCODE_I64(_op_, _v_) |
#define | HT_DECODE_I64(_ip_, _r_, _v_) |
#define | HT_MAX_V1B 0x7f |
#define | HT_MAX_V2B 0x3fff |
#define | HT_MAX_V3B 0x1fffff |
#define | HT_MAX_V4B 0xfffffff |
#define | HT_MAX_V5B 0x7ffffffffull |
#define | HT_MAX_V6B 0x3ffffffffffull |
#define | HT_MAX_V7B 0x1ffffffffffffull |
#define | HT_MAX_V8B 0xffffffffffffffull |
#define | HT_MAX_V9B 0x7fffffffffffffffull |
#define | HT_MAX_LEN_VINT32 5 |
#define | HT_MAX_LEN_VINT64 10 |
#define | HT_ENCODED_LEN_VI32(_v_) |
#define | HT_ENCODED_LEN_VI64(_v_) |
#define | HT_ENCODE_VINT0(_op_, _v_, _done_) |
#define | HT_ENCODE_VINT_(_op_, _v_, _done_) |
#define | HT_ENCODE_VINT4(_op_, _v_, _done_) |
#define | HT_ENCODE_VI32(_op_, _v_, _done_) |
#define | HT_ENCODE_VI64(_op_, _v_, _done_) |
#define | HT_DECODE_VINT0(_type_, _v_, _ip_, _r_) |
#define | HT_DECODE_VINT_(_type_, _v_, _ip_, _r_, _done_) |
#define | HT_DECODE_VINT4(_type_, _v_, _ip_, _r_, _done_) |
#define | HT_DECODE_VI32(_ip_, _r_, _v_, _done_) |
#define | HT_DECODE_VI64(_ip_, _r_, _v_, _done_) |
#define | HT_ENCODE_BYTES32(_op_, _ip_, _len_) |
#define | HT_DECODE_BYTES32(_ip_, _r_, _out_, _len_) |
#define | HT_ENCODE_STR16(_op_, _s_, _len_) |
#define | HT_DECODE_STR16(_ip_, _r_, _s_, _len_) |
#define | HT_ENCODE_VSTR(_op_, _s_, _len_) |
#define | HT_DECODE_VSTR(_ip_, _r_, _out_, _len_) |
Macros to serialize/deserialize primitives to/from a memory buffer.
Do not use directly; use the functions from Common/Serialization.h instead.
Definition in file serialization-c.h.
#define HT_DECODE_BYTES32 | ( | _ip_, | |
_r_, | |||
_out_, | |||
_len_ | |||
) |
Definition at line 395 of file serialization-c.h.
#define HT_DECODE_I16 | ( | _ip_, | |
_r_, | |||
_v_ | |||
) |
Definition at line 145 of file serialization-c.h.
#define HT_DECODE_I32 | ( | _ip_, | |
_r_, | |||
_v_ | |||
) |
Definition at line 180 of file serialization-c.h.
#define HT_DECODE_I64 | ( | _ip_, | |
_r_, | |||
_v_ | |||
) |
Definition at line 221 of file serialization-c.h.
#define HT_DECODE_I8 | ( | _ip_, | |
_r_, | |||
_v_ | |||
) |
Definition at line 115 of file serialization-c.h.
#define HT_DECODE_NEED | ( | _r_, | |
_l_ | |||
) |
Definition at line 94 of file serialization-c.h.
#define HT_DECODE_STR16 | ( | _ip_, | |
_r_, | |||
_s_, | |||
_len_ | |||
) |
Definition at line 429 of file serialization-c.h.
#define HT_DECODE_VI32 | ( | _ip_, | |
_r_, | |||
_v_, | |||
_done_ | |||
) |
Definition at line 349 of file serialization-c.h.
#define HT_DECODE_VI64 | ( | _ip_, | |
_r_, | |||
_v_, | |||
_done_ | |||
) |
Definition at line 364 of file serialization-c.h.
#define HT_DECODE_VINT0 | ( | _type_, | |
_v_, | |||
_ip_, | |||
_r_ | |||
) |
Definition at line 323 of file serialization-c.h.
#define HT_DECODE_VINT4 | ( | _type_, | |
_v_, | |||
_ip_, | |||
_r_, | |||
_done_ | |||
) |
Definition at line 335 of file serialization-c.h.
#define HT_DECODE_VINT_ | ( | _type_, | |
_v_, | |||
_ip_, | |||
_r_, | |||
_done_ | |||
) |
Definition at line 328 of file serialization-c.h.
#define HT_DECODE_VSTR | ( | _ip_, | |
_r_, | |||
_out_, | |||
_len_ | |||
) |
Definition at line 457 of file serialization-c.h.
#define HT_ENCODE_BOOL | ( | _op_, | |
_v_ | |||
) | *(_op_)++ = (_v_) ? 1 : 0 |
Definition at line 104 of file serialization-c.h.
#define HT_ENCODE_BYTES32 | ( | _op_, | |
_ip_, | |||
_len_ | |||
) |
Definition at line 381 of file serialization-c.h.
#define HT_ENCODE_I16 | ( | _op_, | |
_v_ | |||
) |
Definition at line 129 of file serialization-c.h.
#define HT_ENCODE_I32 | ( | _op_, | |
_v_ | |||
) |
Definition at line 162 of file serialization-c.h.
#define HT_ENCODE_I64 | ( | _op_, | |
_v_ | |||
) |
Definition at line 199 of file serialization-c.h.
#define HT_ENCODE_I8 | ( | _op_, | |
_v_ | |||
) | *(_op_)++ = _v_ |
Definition at line 110 of file serialization-c.h.
#define HT_ENCODE_STR16 | ( | _op_, | |
_s_, | |||
_len_ | |||
) |
Definition at line 411 of file serialization-c.h.
#define HT_ENCODE_VI32 | ( | _op_, | |
_v_, | |||
_done_ | |||
) |
Definition at line 297 of file serialization-c.h.
#define HT_ENCODE_VI64 | ( | _op_, | |
_v_, | |||
_done_ | |||
) |
Definition at line 312 of file serialization-c.h.
#define HT_ENCODE_VINT0 | ( | _op_, | |
_v_, | |||
_done_ | |||
) |
Definition at line 273 of file serialization-c.h.
#define HT_ENCODE_VINT4 | ( | _op_, | |
_v_, | |||
_done_ | |||
) |
Definition at line 284 of file serialization-c.h.
#define HT_ENCODE_VINT_ | ( | _op_, | |
_v_, | |||
_done_ | |||
) |
Definition at line 279 of file serialization-c.h.
#define HT_ENCODE_VSTR | ( | _op_, | |
_s_, | |||
_len_ | |||
) |
Definition at line 444 of file serialization-c.h.
#define HT_ENCODED_LEN_VI32 | ( | _v_ | ) |
Definition at line 252 of file serialization-c.h.
#define HT_ENCODED_LEN_VI64 | ( | _v_ | ) |
Definition at line 261 of file serialization-c.h.
#define HT_MAX_LEN_VINT32 5 |
Definition at line 246 of file serialization-c.h.
#define HT_MAX_LEN_VINT64 10 |
Definition at line 247 of file serialization-c.h.
#define HT_MAX_V1B 0x7f |
Definition at line 236 of file serialization-c.h.
#define HT_MAX_V2B 0x3fff |
Definition at line 237 of file serialization-c.h.
#define HT_MAX_V3B 0x1fffff |
Definition at line 238 of file serialization-c.h.
#define HT_MAX_V4B 0xfffffff |
Definition at line 239 of file serialization-c.h.
#define HT_MAX_V5B 0x7ffffffffull |
Definition at line 240 of file serialization-c.h.
#define HT_MAX_V6B 0x3ffffffffffull |
Definition at line 241 of file serialization-c.h.
#define HT_MAX_V7B 0x1ffffffffffffull |
Definition at line 242 of file serialization-c.h.
#define HT_MAX_V8B 0xffffffffffffffull |
Definition at line 243 of file serialization-c.h.
#define HT_MAX_V9B 0x7fffffffffffffffull |
Definition at line 244 of file serialization-c.h.
#define HT_THROW_BAD_VINT | ( | _s_ | ) |
Definition at line 79 of file serialization-c.h.
#define HT_THROW_BAD_VSTR | ( | _s_ | ) |
Definition at line 72 of file serialization-c.h.
#define HT_THROW_INPUT_OVERRUN | ( | _s_ | ) |
Definition at line 65 of file serialization-c.h.
#define HT_THROW_UNPOSSIBLE | ( | _s_ | ) |
Definition at line 86 of file serialization-c.h.