public abstract class AbstractServiceManager extends java.lang.Object implements ServiceManager
ServiceManager implementation which stores the registered
ServiceFactory objects into a Map, using the name as the key.| Constructor and Description |
|---|
AbstractServiceManager() |
| Modifier and Type | Method and Description |
|---|---|
void |
addServiceFactory(ServiceFactory serviceFactory)
Adds a new
ServiceFactory to the registry. |
Service |
createService(DynObject serviceParameters)
Creates a new
Service. |
DynObject |
createServiceParameters(java.lang.String serviceName)
Creates the parameters for the
Service created by the factory
with the given name. |
protected java.lang.String |
getName() |
protected abstract java.lang.String |
getRegistryDescription() |
protected abstract java.lang.String |
getRegistryKey() |
java.util.List |
getServiceFactories() |
protected ServiceFactory |
getServiceFactory(java.lang.String serviceName) |
public void addServiceFactory(ServiceFactory serviceFactory)
ServiceManagerServiceFactory to the registry.addServiceFactory in interface ServiceManagerserviceFactory - to addprotected java.lang.String getName()
protected abstract java.lang.String getRegistryKey()
protected abstract java.lang.String getRegistryDescription()
public Service createService(DynObject serviceParameters) throws ServiceException
ServiceManagerService.createService in interface ServiceManagerserviceParameters - for the ServiceServiceServiceException - if the parameters are not valid or there is an error creating
the Providerpublic DynObject createServiceParameters(java.lang.String serviceName) throws ServiceException
ServiceManagerService created by the factory
with the given name.createServiceParameters in interface ServiceManagerserviceName - name of the factory to create the ServiceServiceExceptionprotected ServiceFactory getServiceFactory(java.lang.String serviceName) throws ParametersException, NotRegisteredException
public java.util.List getServiceFactories()