t.i.b._SignalReactorMixin : class documentation

Part of twisted.internet.base View Source View In Hierarchy

Known subclasses: twisted.internet.iocpreactor.reactor.IOCPReactor, twisted.internet.posixbase.PosixReactorBase

Private mixin to manage signals: it installs signal handlers at start time, and define run method.

It can only be used mixed in with ReactorBase, and has to be defined first in the inheritance (so that method resolution order finds startRunning first).
Method startRunning Forward call to ReactorBase, arrange for signal handlers to be installed if asked.
Method run Undocumented
Method mainLoop Undocumented
Method _handleSignals Install the signal handlers for the Twisted event loop.
Method _handleSigchld Reap all processes on SIGCHLD.
def _handleSignals(self): (source)
Install the signal handlers for the Twisted event loop.
def _handleSigchld(self, signum, frame, _threadSupport=platform.supportsThreads()): (source)

Reap all processes on SIGCHLD.

This gets called on SIGCHLD. We do no processing inside a signal handler, as the calls we make here could occur between any two python bytecode instructions. Deferring processing to the next eventloop round prevents us from violating the state constraints of arbitrary classes.
def startRunning(self, installSignalHandlers=True): (source)
Forward call to ReactorBase, arrange for signal handlers to be installed if asked.
def run(self, installSignalHandlers=True): (source)
Undocumented
def mainLoop(self): (source)
Undocumented
API Documentation for Twisted, generated by pydoctor at 2011-10-27 15:57:47.