Known implementations: twisted.application.service.MultiService

Collection of services.

Contain several services, and manage their start-up/shut-down. Services can be accessed by name if they have a name, and it is always possible to iterate over them.

Method getServiceNamed Get the child service with a given name.
Method __iter__ Get an iterator over all child services.
Method addService Add a child service.
Method removeService Remove a child service.
def getServiceNamed(name):

Get the child service with a given name.

Returns (type: IService)
RaisesKeyErrorRaised if the service has no child with the given name.
def __iter__():

Get an iterator over all child services.

def addService(service):

Add a child service.

Only implementations of IService.setServiceParent should use this method.

RaisesRuntimeErrorRaised if the service has a child with the given name.
def removeService(service):

Remove a child service.

Only implementations of IService.disownServiceParent should use this method.

Returnsa Deferred which is triggered when the service has finished shutting down. If shutting down is immediate, a value can be returned (usually, None). (type: Deferred)
RaisesValueErrorRaised if the given service is not a child.
API Documentation for twisted, generated by pydoctor at 2020-03-25 17:34:30.