client.h

来自「Linux下使用Select模型的两个类Client And Server」· C头文件 代码 · 共 39 行

H
39
字号
// // File:   client.h// Author: root//// Created on February 19, 2008, 9:36 AM//#ifndef _CLIENT_H#define	_CLIENT_H#include <sys/socket.h>#include <sys/errno.h>#include <sys/types.h>#include <netinet/in.h>#include <arpa/inet.h>#include <fcntl.h>#include <stdio.h>#include <string>#include <iostream>using namespace std;class client{public:    enum {BUFFERSIZE = 1024};    client(int fd,struct sockaddr_in sinaddr,int timeout);    ~client();    bool update();    string _value;private:    int _fd;    int _timeout;    char *buffer;};#endif	/* _CLIENT_H */

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?