STTNet
 全部  命名空间 文件 函数 变量 类型定义 枚举 枚举值 宏定义 
Public 属性 | 所有成员列表
stt::network::WebSocketFDInformation结构体 参考

保存客户端WS/WSS请求信息的结构体 更多...

#include <sttnet.h>

Public 属性

int fd
 底层的socket套接字 更多...
 
bool closeflag
 true:发送了关闭帧 false:没有发送关闭帧 更多...
 
std::string locPara
 握手阶段的Http/Https路径和参数 更多...
 
std::string header
 握手阶段的Http/Https请求头 更多...
 
time_t HBTime =0
 发送心跳的时间(没有发送过就填0) (检查完又要清空为0) 更多...
 
time_t response
 上次收到信息的时间 更多...
 
size_t recv_length
 待接收的长度 更多...
 
size_t have_recv_length
 已经接收的长度 更多...
 
int message_type
 消息类型 更多...
 
std::string message =""
 消息 更多...
 
bool fin
 fin的状态 更多...
 
std::string mask
 mask 更多...
 
std::unordered_map
< std::string, std::any > 
ctx
 所需的数据仓库 更多...
 

详细描述

保存客户端WS/WSS请求信息的结构体

类成员变量说明

bool stt::network::WebSocketFDInformation::closeflag

true:发送了关闭帧 false:没有发送关闭帧

std::unordered_map<std::string,std::any> stt::network::WebSocketFDInformation::ctx

所需的数据仓库

int stt::network::WebSocketFDInformation::fd

底层的socket套接字

bool stt::network::WebSocketFDInformation::fin

fin的状态

size_t stt::network::WebSocketFDInformation::have_recv_length

已经接收的长度

time_t stt::network::WebSocketFDInformation::HBTime =0

发送心跳的时间(没有发送过就填0) (检查完又要清空为0)

std::string stt::network::WebSocketFDInformation::header

握手阶段的Http/Https请求头

std::string stt::network::WebSocketFDInformation::locPara

握手阶段的Http/Https路径和参数

std::string stt::network::WebSocketFDInformation::mask

mask

std::string stt::network::WebSocketFDInformation::message =""

消息

int stt::network::WebSocketFDInformation::message_type

消息类型

size_t stt::network::WebSocketFDInformation::recv_length

待接收的长度

time_t stt::network::WebSocketFDInformation::response

上次收到信息的时间


该结构体的文档由以下文件生成: