/usr/lib/python3/dist-packages/twisted/application/__pycache__
Edit: /usr/lib/python3/dist-packages/twisted/application/__pycache__/service.cpython-310.pyc (13648B)
o
b- @ s d Z ddlmZmZmZ ddlmZ ddlmZ ddl m
Z
ddlmZ ddl
mZ G dd d eZee
eG d
d dZG dd
d
eZeeG dd dZG dd deZeeG dd deZG dd deZeeG dd dZdddZdddZg dZdS ) aa
Service architecture for Twisted.
Services are arranged in a hierarchy. At the leafs of the hierarchy,
the services which actually interact with the outside world are started.
Services can be named or anonymous -- usually, they will be named if
there is need to access them through the hierarchy (from a parent or
a sibling).
Maintainer: Moshe Zadka
) Attribute Interfaceimplementer)defer)sob)IPlugin)
components)namedAnyc @ s0 e Zd ZdZedZedZedZdd ZdS )
IServiceMakerz
An object which can be used to construct services in a flexible
way.
This interface should most often be implemented along with
L{twisted.plugin.IPlugin}, and will most often be used by the
'twistd' command.
zA short string naming this Twisted plugin, for example 'web' or 'pencil'. This name will be used as the subcommand of 'twistd'.zLA brief summary of the features provided by this Twisted application plugin.zcA C{twisted.python.usage.Options} subclass defining the configuration options for this application.c C dS )a
Create and return an object providing
L{twisted.application.service.IService}.
@param options: A mapping (typically a C{dict} or
L{twisted.python.usage.Options} instance) of configuration
options to desired configuration values.
N )optionsr r =/usr/lib/python3/dist-packages/twisted/application/service.pymakeService4 zIServiceMaker.makeServiceN) __name__
__module____qualname____doc__r tapnamedescriptionr
r r r r r r
s r
c @ s0 e Zd ZdZdd Zedd Zedd ZdS ) ServiceMakerzO
Utility class to simplify the definition of L{IServiceMaker} plugins.
c C s || _ || _|| _|| _d S N)namemoduler r )selfr r r r r r r __init__E s
zServiceMaker.__init__c C t | jjS r )r r Optionsr r r r r
K zServiceMaker.optionsc C r r )r r r r r r r r O r zServiceMaker.makeServiceN)r r r r r propertyr
r r r r r r ? s
r c @ sX e Zd ZdZedZedZedZdd Zdd Z d d
Z
dd Zd
d Zdd Z
dS )IServicezS
A service.
Run start-up and shut-down code at the appropriate times.
z5A C{str} which is the name of the service or C{None}.z