#pragma once #include class CIOBuffer; class EpollServer { public: static EpollServer& GetInstance(); void Loop(); private: void et(struct epoll_event* events, int number, int epollfd, int listenfd); private: void addfd(int epollfd,int fd, void * ptr, int enable_et); int setnonblocking(int fd); private: int32_t _listenfd; int32_t _epollfd; };