org.gvsig.tools.service
Class AbstractService

java.lang.Object
  extended by org.gvsig.tools.service.AbstractService
All Implemented Interfaces:
Service
Direct Known Subclasses:
AbstractPersistentService

public abstract class AbstractService
extends Object
implements Service

Service base parent implementation, delegating in the child classes the retrieval of the ProviderManager.

Author:
2009- C�sar Ordi�ana - gvSIG team

Constructor Summary
AbstractService()
          Empty constructor to be used only for persistence purposes.
AbstractService(DynObject serviceParameters)
          Creates a new AbstractService.
 
Method Summary
protected  Provider getProvider()
          Returns the provider related to this service.
protected abstract  ProviderManager getProviderManager()
          Returns the reference to the ProviderManager.
protected  ProviderServices getProviderServices()
          Returns the provider services to be used by the provider of this service.
 DynObject getServiceParameters()
          Returns the service parameters this services was created with
protected  void init(DynObject serviceParameters, ProviderServices providerServices)
          Initialices the service.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.gvsig.tools.service.Service
getManager
 

Constructor Detail

AbstractService

public AbstractService()
Empty constructor to be used only for persistence purposes.


AbstractService

public AbstractService(DynObject serviceParameters)
                throws ServiceException
Creates a new AbstractService.

Parameters:
serviceParameters - the parameters of the current service
Throws:
ServiceException - if there is an error with the parameters
Method Detail

getServiceParameters

public DynObject getServiceParameters()
Returns the service parameters this services was created with

Returns:
the service parameters

init

protected void init(DynObject serviceParameters,
                    ProviderServices providerServices)
             throws ServiceException
Initialices the service.

Parameters:
serviceParameters - the service parameters
providerServices - the provider services
Throws:
ServiceException - thrown while creating the provider

getProvider

protected Provider getProvider()
Returns the provider related to this service.

Returns:
the provider

getProviderServices

protected ProviderServices getProviderServices()
Returns the provider services to be used by the provider of this service.

Returns:
the provider services

getProviderManager

protected abstract ProviderManager getProviderManager()
Returns the reference to the ProviderManager.

Returns:
the ProviderManager


Copyright © 2004-2011 gvSIG. All Rights Reserved.