A flag which is true between the time reactor.stop is called
and the time the shutdown system event is fired. This is used to determine
whether that event should be fired after each iteration through the
mainloop. This should be replaced with an explicit state machine. (type: bool)

A flag which is true from the time reactor.run is called until
the time reactor.run returns. This is used to prevent calls
to reactor.run on a running reactor. This should be replaced
with an explicit state machine. (type: bool)

A flag which is true between paired calls to reactor.run and
reactor.stop. This should be replaced with an explicit state
machine. (type: bool)

_justStopped =

A flag which is true between the time reactor.stop is called
and the time the shutdown system event is fired. This is used to determine
whether that event should be fired after each iteration through the
mainloop. This should be replaced with an explicit state machine. (type: bool)

_started =

A flag which is true from the time reactor.run is called until
the time reactor.run returns. This is used to prevent calls
to reactor.run on a running reactor. This should be replaced
with an explicit state machine. (type: bool)

A two element tuple giving values to use when creating the process. The
first element of the tuple is a list of str
giving the values for argv of the child process. The second element of the
tuple is either None if env was None
or a dict mapping str environment keys to
str environment values.

Stop the reactor threadpool. This method is only valid if there is
currently a threadpool (created by _initThreadPool).
It is not intended to be called directly; instead, it will be called by a
shutdown trigger created in _initThreadPool.

Use this method when you want to run a function in the reactor's thread
from another thread. Calling callFromThread
should wake up the main thread (where reactor.run() is
executing) and run the given callable in that thread.

If you're writing a multi-threaded application the callable
may need to be thread safe, but this method doesn't require it as such. If
you want to call a function in the next mainloop iteration, but you're in
the same thread, use callLater
with a delay of 0.