ngl_server 1.0
基于 Actor 模型的 C++ 服务器框架
ngl::tools::varint_parm< T > Struct Template Reference

varint编解码参数结构体 More...

#include <tools_code.h>

Public Attributes

m_value
 待编码或解码后的整数值
char * m_buf = nullptr
 编码/解码缓冲区指针
int m_len = 0
 缓冲区长度
int32_t * m_bytes = nullptr
 实际读写的字节数

Detailed Description

template<typename T>
struct ngl::tools::varint_parm< T >

varint编解码参数结构体

Template Parameters
T整数类型,支持 int32_t 和 int64_t

用于 varint_encode 和 varint_decode 函数的参数传递。 varint 是一种使用可变长度字节序列编码整数的方法, 小值使用较少字节,大值使用较多字节。


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