#include <EPollPoller.h>
Public Types | |
| using | EventList = std::vector<epoll_event> |
| using | ChannelList = std::vector<Channel*> |
| using | ChannelMap = std::unordered_map<SOCKET, Channel*> |
Public Member Functions | |
| EPollPoller (EventLoop *loop) | |
| Constructor Function. | |
| virtual | ~EPollPoller () override |
| Destructor Function. | |
| EPollPoller (const EPollPoller &)=delete | |
| Copy Constructor Function. | |
| EPollPoller & | operator= (const EPollPoller &)=delete |
| Copy Assignment Operation. | |
| HANDLE | GetHandle () const |
| Get this EPollPoller Handle. | |
| virtual void | Poll (int timeoutMs, ChannelList *activeChannels) override |
| Poll events on EventList. | |
| virtual void | UpdateChannel (Channel *channel) override |
| Update Channel and Update Poll. | |
| virtual void | RemoveChannel (Channel *channel) override |
| Remove Channel and Update Poll. | |
| bool | HasChannel (Channel *channel) const |
| Determine if channel is in ChannelMap. | |
Static Public Member Functions | |
| static std::shared_ptr< Poller > | DefaultPoller (EventLoop *loop) |
| Create Default Poller. | |
Protected Attributes | |
| ChannelMap | m_Channels |
| This Poller interested Channels. | |
Private Member Functions | |
| void | FillActiveChannels (int numEvents, ChannelList *activeChannels) const |
| Fill REvents to ChannelList. | |
| void | Update (int operation, Channel *channel) const |
| Update epoll with operation. | |
Private Attributes | |
| HANDLE | m_EPollFd |
| EPoll fd. | |
| EventList | m_Events |
| EventList. | |
| EventLoop * | m_Loop |
| This Poller interested EventLoop. | |
EPoll Poller.
Definition at line 19 of file EPollPoller.h.