Package twisted :: Package application :: Module service :: Class IServiceCollection |
[frames | no frames]

## Class IServiceCollection

    Interface --+
                |
               IServiceCollection

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 Summary
| ``__iter__`(self)` Get an iterator over all child services
| ``addService`(self, service)` Add a child service.
`IService` @raise `KeyError`: Raised if the service has no child with the given name. | ``getServiceNamed`(self, name)` Get the child service with a given name.
| ``removeService`(self, service)` Remove a child service.

Method Details

### __iter__(self) Get an iterator over all child services

### addService(self, service) Add a child service. Parameters: `service` (type=`IService` @raise `RuntimeError`: Raised if the service has a child with the given name.)

### getServiceNamed(self, name) Get the child service with a given name. Parameters: `name` (type=`str`) Returns: `IService` @raise `KeyError`: Raised if the service has no child with the given name.

### removeService(self, service) Remove a child service. Parameters: `service` (type=`IService` @raise `ValueError`: Raised if the given service is not a child.)

Generated by Epydoc 2.0 on Sat Oct 25 00:55:05 2003 | http://epydoc.sf.net