📄 session.h
字号:
#include "core.h"#ifndef _SESSION_H#define _SESSION_H#ifdef __cplusplusextern "C" {#endif/* Initialize SESSION struct */SESSION *session_init();/* initialize session */int sess_set(SESSION *, int);/* SESSION event handler */void sess_event_handler(int , short , void *);/* update event base*/int sess_event_update(SESSION *, short);/* read data from fd*/int sess_read_handler(SESSION *);/* wirite data to fd */int sess_write_handler(SESSION *);/* packet read */void sess_packet_reader(SESSION *);/* packet handler for hook */void sess_packet_handler(SESSION *);/* data handler */void sess_data_handler(SESSION *);/* push MESSAGE to pthread joblist queue */void sess_push_message(SESSION *, int);/* read chunk from BUFFER */int sess_chunk_reader(SESSION *);/* add MEM_CHUNK to send queue */int sess_push_chunk(SESSION *, void *, size_t);/* add cache to sess->cache */int sess_push_cache(SESSION *, void *, size_t);/* add FILE_CHUNK to send queue */int sess_push_file(SESSION *, char *, uint64_t , uint64_t);/* read out of band data and handling it */int sess_oob_handler(SESSION *sess);/* check connection state send oob data ensure connection is connected */int sess_state_handler(SESSION *sess);/* terminate session */int sess_terminate(SESSION *);/* clean session */void sess_clean(SESSION **);#ifdef __cplusplus }#endif#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -