org.talika.tarsis.service
Class AbstractService

java.lang.Object
  extended by org.talika.tarsis.service.AbstractService
All Implemented Interfaces:
Service
Direct Known Subclasses:
AuthenticatorService, AuthorizatorService, CommandFactoryService, FactoryService, LoggerService

public abstract class AbstractService
extends java.lang.Object
implements Service

Base implementation of Service interface.

Version:
$Revision: 269 $
Author:
Jose M. Palomar

Constructor Summary
AbstractService()
          Creates a new AbstractService object.
 
Method Summary
 void destroy()
          Called by the framework to indicate that is being placed out of service.
protected  Context getContext()
          Returns the Tarsis context.
protected  Logger getLogger()
          Returns the Tarsis logger.
abstract  java.lang.String getName()
          Returns name of service.
 void init(Context context)
          Called by the framework to indicate that is being placed into service.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractService

public AbstractService()
Creates a new AbstractService object.

Method Detail

init

public void init(Context context)
          throws ServiceException
Called by the framework to indicate that is being placed into service.

Specified by:
init in interface Service
Parameters:
context - Context context that initialized service.
Throws:
ServiceException - if an exception has occurred that interferes with the services's normal operation
See Also:
Service.init(Context)

destroy

public void destroy()
Called by the framework to indicate that is being placed out of service.

Specified by:
destroy in interface Service
See Also:
Service.destroy()

getName

public abstract java.lang.String getName()
Returns name of service.

Specified by:
getName in interface Service
Returns:
String name of service.
See Also:
Service.getName()

getContext

protected final Context getContext()
Returns the Tarsis context.

Returns:
Context the Tarsis context.

getLogger

protected final Logger getLogger()
Returns the Tarsis logger.

Returns:
Logger the Tarsis logger.


Copyright © 2002-2012 Talika Open Source Group. All Rights Reserved.