Implements interfaces: twisted.internet.interfaces.IReactorFDSet

A reactor that uses epoll(7).

Method __init__ Initialize epoll object, file descriptor tracking dictionaries, and the base class.
Method addReader Add a FileDescriptor for notification of data available to read.
Method addWriter Add a FileDescriptor for notification of data available to write.
Method removeReader Remove a Selectable for notification of data available to read.
Method removeWriter Remove a Selectable for notification of data available to write.
Method removeAll Remove all selectables, and return a list of them.
Method getReaders Return the list of file descriptors currently monitored for input events by the reactor.
Method getWriters Return the list file descriptors currently monitored for output events by the reactor.
Method doPoll Poll the poller for new events.
Instance Variable _poller A epoll which will be used to check for I/O readiness.
Instance Variable _selectables A dictionary mapping integer file descriptors to instances of FileDescriptor which have been registered with the reactor. All FileDescriptors which are currently receiving read or write readiness notifications will be present as values in this dictionary.
Instance Variable _reads A set containing integer file descriptors. Values in this set will be registered with _poller for read readiness notifications which will be dispatched to the corresponding FileDescriptor instances in _selectables.
Instance Variable _writes A set containing integer file descriptors. Values in this set will be registered with _poller for write readiness notifications which will be dispatched to the corresponding FileDescriptor instances in _selectables.
Instance Variable _continuousPolling A _ContinuousPolling instance, used to handle file descriptors (e.g. filesytem files) that are not supported by epoll(7).
Method _add Private method for adding a descriptor from the event loop.
Method _remove Private method for removing a descriptor from the event loop.

Inherited from _PollLikeMixin:

Method _doReadOrWrite fd is available for read or write, do the work and raise errors if necessary.

Inherited from _PollLikeMixin:

Method _doReadOrWrite fd is available for read or write, do the work and raise errors if necessary.

Inherited from _PollLikeMixin:

Method _doReadOrWrite fd is available for read or write, do the work and raise errors if necessary.

Inherited from _PollLikeMixin:

Method _doReadOrWrite fd is available for read or write, do the work and raise errors if necessary.

Inherited from _PollLikeMixin:

Method _doReadOrWrite fd is available for read or write, do the work and raise errors if necessary.
_poller =
A epoll which will be used to check for I/O readiness.
_selectables =
A dictionary mapping integer file descriptors to instances of FileDescriptor which have been registered with the reactor. All FileDescriptors which are currently receiving read or write readiness notifications will be present as values in this dictionary.
_reads =
A set containing integer file descriptors. Values in this set will be registered with _poller for read readiness notifications which will be dispatched to the corresponding FileDescriptor instances in _selectables.
_writes =
A set containing integer file descriptors. Values in this set will be registered with _poller for write readiness notifications which will be dispatched to the corresponding FileDescriptor instances in _selectables.
_continuousPolling =
A _ContinuousPolling instance, used to handle file descriptors (e.g. filesytem files) that are not supported by epoll(7).
def __init__(self): (source)

Initialize epoll object, file descriptor tracking dictionaries, and the base class.

def _add(self, xer, primary, other, selectables, event, antievent): (source)

Private method for adding a descriptor from the event loop.

It takes care of adding it if new or modifying it if already added for another state (read -> read/write for example).

def addReader(self, reader): (source)

Add a FileDescriptor for notification of data available to read.

def addWriter(self, writer): (source)

Add a FileDescriptor for notification of data available to write.

def _remove(self, xer, primary, other, selectables, event, antievent): (source)

Private method for removing a descriptor from the event loop.

It does the inverse job of _add, and also add a check in case of the fd has gone away.

def removeReader(self, reader): (source)

Remove a Selectable for notification of data available to read.

def removeWriter(self, writer): (source)

Remove a Selectable for notification of data available to write.

def removeAll(self): (source)

Remove all selectables, and return a list of them.

def getReaders(self): (source)

Return the list of file descriptors currently monitored for input events by the reactor.

Returnsthe list of file descriptors monitored for input events. (type: list of IReadDescriptor)
def getWriters(self): (source)

Return the list file descriptors currently monitored for output events by the reactor.

Returnsthe list of file descriptors monitored for output events. (type: list of IWriteDescriptor)
def doPoll(self, timeout): (source)

Poll the poller for new events.

API Documentation for Twisted, generated by pydoctor at 2016-04-11 10:39:53.