com.cafesoft.core.service
Interface ServiceConnector

All Superinterfaces:
Debuggable, Lifecycle, LifecycleService, Service
All Known Implementing Classes:
AbstractServiceConnector

public interface ServiceConnector
extends LifecycleService

ServiceConnector defines the interface for Services that provide network access to other Services. The Services to be made available are specified by registration of ServiceAdapters, which may be used to provide pluggable support for multiple services, protocols, etc, hosted by a ServiceConnector.


Field Summary
 
Fields inherited from interface com.cafesoft.core.lifecycle.Lifecycle
START_EVENT, STOP_EVENT
 
Method Summary
 void addServiceAdapter(ServiceAdapter adapter)
          Add a ServiceAdapter.
 ServiceAdapter[] getServiceAdapters()
          Get all ServiceAdapters.
 void removeServiceAdapter(ServiceAdapter adapter)
          Remove a ServiceAdapter.
 
Methods inherited from interface com.cafesoft.core.service.Service
destroy, getServiceConfig, initialize
 
Methods inherited from interface com.cafesoft.core.util.Debuggable
setDebug
 
Methods inherited from interface com.cafesoft.core.lifecycle.Lifecycle
addLifecycleListener, isStarted, removeLifecycleListener, start, stop
 

Method Detail

addServiceAdapter

public void addServiceAdapter(ServiceAdapter adapter)
                       throws ServiceException
Add a ServiceAdapter.

Parameters:
adapter - the ServiceAdapter to be added.
Throws:
ServiceException - if the ServiceAdapter is null or is a duplicate of a previously-registered ServiceAdapter.

removeServiceAdapter

public void removeServiceAdapter(ServiceAdapter adapter)
                          throws ServiceException
Remove a ServiceAdapter.

Parameters:
adapter - the ServiceAdapter to be removed.
Throws:
ServiceException - if the specified ServiceAdapter is not registered with this ServiceConnector.

getServiceAdapters

public ServiceAdapter[] getServiceAdapters()
Get all ServiceAdapters.

Returns:
an array of registered ServiceAdapters.


Generated on 8:41:50 AM June 06, 2005, © 1996-2005 Cafésoft LLC. All rights reserved.