/usr/lib/python3/dist-packages/twisted/internet/__pycache__
NameSizeModeActions
abstract.cpython-310.pyc176100644editdlrm
address.cpython-310.pyc56700644editdlrm
asyncioreactor.cpython-310.pyc99550644editdlrm
base.cpython-310.pyc408700644editdlrm
cfreactor.cpython-310.pyc156380644editdlrm
default.cpython-310.pyc11720644editdlrm
defer.cpython-310.pyc687400644editdlrm
endpoints.cpython-310.pyc733480644editdlrm
epollreactor.cpython-310.pyc69210644editdlrm
error.cpython-310.pyc150360644editdlrm
fdesc.cpython-310.pyc31730644editdlrm
gireactor.cpython-310.pyc40980644editdlrm
glib2reactor.cpython-310.pyc14680644editdlrm
gtk2reactor.cpython-310.pyc25890644editdlrm
gtk3reactor.cpython-310.pyc18690644editdlrm
inotify.cpython-310.pyc108480644editdlrm
interfaces.cpython-310.pyc1173770644editdlrm
kqreactor.cpython-310.pyc85820644editdlrm
main.cpython-310.pyc9750644editdlrm
pollreactor.cpython-310.pyc59600644editdlrm
posixbase.cpython-310.pyc234570644editdlrm
process.cpython-310.pyc286110644editdlrm
protocol.cpython-310.pyc306580644editdlrm
pyuisupport.cpython-310.pyc9730644editdlrm
reactor.cpython-310.pyc19200644editdlrm
selectreactor.cpython-310.pyc53030644editdlrm
serialport.cpython-310.pyc27780644editdlrm
ssl.cpython-310.pyc89290644editdlrm
stdio.cpython-310.pyc9840644editdlrm
task.cpython-310.pyc321410644editdlrm
tcp.cpython-310.pyc466840644editdlrm
testing.cpython-310.pyc333470644editdlrm
threads.cpython-310.pyc42080644editdlrm
tksupport.cpython-310.pyc21690644editdlrm
udp.cpython-310.pyc165840644editdlrm
unix.cpython-310.pyc195310644editdlrm
utils.cpython-310.pyc93270644editdlrm
win32eventreactor.cpython-310.pyc138810644editdlrm
wxreactor.cpython-310.pyc48970644editdlrm
wxsupport.cpython-310.pyc16930644editdlrm
_baseprocess.cpython-310.pyc22160644editdlrm
_dumbwin32proc.cpython-310.pyc116270644editdlrm
_glibbase.cpython-310.pyc117910644editdlrm
_idna.cpython-310.pyc14940644editdlrm
_newtls.cpython-310.pyc87140644editdlrm
_pollingfile.cpython-310.pyc84760644editdlrm
_posixserialport.cpython-310.pyc21910644editdlrm
_posixstdio.cpython-310.pyc53090644editdlrm
_producer_helpers.cpython-310.pyc38670644editdlrm
_resolver.cpython-310.pyc84020644editdlrm
_signals.cpython-310.pyc28240644editdlrm
_sslverify.cpython-310.pyc684120644editdlrm
_threadedselect.cpython-310.pyc117550644editdlrm
_win32serialport.cpython-310.pyc37070644editdlrm
_win32stdio.cpython-310.pyc40240644editdlrm
__init__.cpython-310.pyc6080644editdlrm
Edit: /usr/lib/python3/dist-packages/twisted/internet/__pycache__/epollreactor.cpython-310.pyc (6921B)
o b" @sdZddlZddlZddlmZddlmZddlmZddl m Z ze edZ e edZ e ed Ze ed Ze ed ZWneyMZzeedZ[wweeGd d d ejejZddZd dgZdS)z An epoll() based implementation of the twisted main loop. To install the event loop (and you should do this before any connections, listeners or connectors are added):: from twisted.internet import epollreactor epollreactor.install() N) implementer) posixbase) IReactorFDSet)logepollEPOLLHUPEPOLLERREPOLLINEPOLLOUTc@s|eZdZdZeeBZeZe Z ddZ ddZ ddZ dd Zd d Zd d ZddZddZddZddZddZeZdS) EPollReactora A reactor that uses epoll(7). @ivar _poller: A C{epoll} which will be used to check for I/O readiness. @ivar _selectables: A dictionary mapping integer file descriptors to instances of C{FileDescriptor} which have been registered with the reactor. All C{FileDescriptors} which are currently receiving read or write readiness notifications will be present as values in this dictionary. @ivar _reads: A set containing integer file descriptors. Values in this set will be registered with C{_poller} for read readiness notifications which will be dispatched to the corresponding C{FileDescriptor} instances in C{_selectables}. @ivar _writes: A set containing integer file descriptors. Values in this set will be registered with C{_poller} for write readiness notifications which will be dispatched to the corresponding C{FileDescriptor} instances in C{_selectables}. @ivar _continuousPolling: A L{_ContinuousPolling} instance, used to handle file descriptors (e.g. filesystem files) that are not supported by C{epoll(7)}. cCs<td|_t|_t|_i|_t||_tj |dS)zm Initialize epoll object, file descriptor tracking dictionaries, and the base class. iN) r_pollerset_reads_writes _selectablesr_ContinuousPolling_continuousPollingPosixReactorBase__init__selfr?/usr/lib/python3/dist-packages/twisted/internet/epollreactor.pyrGs  zEPollReactor.__init__c Cs\|}||vr,|}||vr||O}|j||n|j|||||||<dSdS)z 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). N)filenor modifyregisteradd) rxerprimaryother selectablesevent antieventfdflagsrrr_addVs  zEPollReactor._addc Cdz|||j|j|jttWdSty1}z|jtjkr%|j |nWYd}~dSd}~ww)zR Add a FileDescriptor for notification of data available to read. N) r%rrrr r OSErrorerrnoEPERMr addReader)rreadererrrr*p  zEPollReactor.addReaderc Cr&)zS Add a FileDescriptor for notification of data available to write. N) r%rrrr r r'r(r)r addWriter)rwriterr,rrrr.r-zEPollReactor.addWriterc Csz|}|dkr|D] \}}||urnq dS||vr;||vr+|} |j|| n ||=|j|||dSdS)z 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. N)ritemsr r unregisterremove) rrrrr r!r"r#fdesr$rrr_removes zEPollReactor._removecC:|j|r|j|dS|||j|j|jttdS)zQ Remove a Selectable for notification of data available to read. N) r isReading removeReaderr5rrrr r )rr+rrrr8  zEPollReactor.removeReadercCr6)zR Remove a Selectable for notification of data available to write. N) r isWriting removeWriterr5rrrr r )rr/rrrr;r9zEPollReactor.removeWritercs6fddjDfddjDjS)zD Remove all selectables, and return a list of them. cg|]}j|qSrr.0r#rrr z*EPollReactor.removeAll..cr<rr=r>rrrr@rA) _removeAllrrr removeAllrrrrrCszEPollReactor.removeAllcfddjDjS)Ncr<rr=r>rrrr@ z+EPollReactor.getReaders..)rr getReadersrrrrrF zEPollReactor.getReaderscrD)Ncr<rr=r>rrrr@rEz+EPollReactor.getWriters..)rr getWritersrrrrrHrGzEPollReactor.getWritersc Cs|durd}z |j|t|j}Wnty,}z|jtjkr'WYd}~dSd}~ww|j}|D]\}}z|j|}Wn tyFYq2wt |||||q2dS)z1 Poll the poller for new events. Nr0) r polllenrr'r(EINTR_doReadOrWriteKeyErrorrcallWithLogger)rtimeoutlerr_drdwr#r! selectablerrrdoPolls&   zEPollReactor.doPollN)__name__ __module__ __qualname____doc__rr_POLL_DISCONNECTEDr _POLL_INr _POLL_OUTrr%r*r.r5r8r;rCrFrHrT doIterationrrrrr %s"   r cCst}ddlm}||dS)z& Install the epoll() reactor. r)installReactorN)r twisted.internet.mainr])pr]rrrinstalls  r`)rXr(selectzope.interfacertwisted.internetrtwisted.internet.interfacesrtwisted.pythonrgetattrrrrr r AttributeErrorr, ImportErrorr_PollLikeMixinr r`__all__rrrrs,         T