solar.service
Interface ServiceManager

All Known Implementing Classes:
BaseServiceManager

public interface ServiceManager

Interface for the manager of a set of services.

Version:
$Id: ServiceManager.java,v 1.7 2003/09/05 03:15:49 glchen Exp $
Author:
Guanling Chen

Method Summary
 Service getService(java.lang.String name)
          Return an instance of specified service.
 serp.util.Options getServiceConfig(java.lang.String name)
          Return the configuration of a specified service.
 java.lang.Object getServiceObject(java.lang.String name)
          Get an application-specific service object.
 boolean hasRegistered(java.lang.String name)
          Determines whether a service is registered.
 void init(serp.util.Options opts)
          Init the service manager with configurations of all services.
 void setServiceObject(java.lang.String name, java.lang.Object obj)
          Set application-specific service object.
 void stopService(java.lang.String name)
          Stop a specified service.
 void stopServices()
          Stop all services.
 

Method Detail

init

public void init(serp.util.Options opts)
          throws ServiceException
Init the service manager with configurations of all services.

ServiceException

hasRegistered

public boolean hasRegistered(java.lang.String name)
Determines whether a service is registered.


getService

public Service getService(java.lang.String name)
                   throws ServiceException
Return an instance of specified service.

ServiceException

getServiceConfig

public serp.util.Options getServiceConfig(java.lang.String name)
                                   throws ServiceException
Return the configuration of a specified service.

ServiceException

setServiceObject

public void setServiceObject(java.lang.String name,
                             java.lang.Object obj)
Set application-specific service object.


getServiceObject

public java.lang.Object getServiceObject(java.lang.String name)
Get an application-specific service object.


stopService

public void stopService(java.lang.String name)
Stop a specified service.


stopServices

public void stopServices()
Stop all services.