de.janrufmonitor.repository
Class AbstractConfigurableCallManager

java.lang.Object
  extended by de.janrufmonitor.repository.AbstractConfigurableCallManager
All Implemented Interfaces:
IConfigurable, IManager, IRepositoryManager, ICallManager
Direct Known Subclasses:
AbstractDatabaseCallManager, AbstractFilterCallManager

public abstract class AbstractConfigurableCallManager
extends Object
implements ICallManager, IConfigurable

This abstract class can be used as base class for a new call manager implementation which is supporting configuration.

Author:
Thilo Brandt

Field Summary
protected  String CFG_ENABLED
           
protected  String CFG_PRIO
           
protected  Properties m_configuration
           
protected  String m_externalID
           
protected  Logger m_logger
           
 
Constructor Summary
AbstractConfigurableCallManager()
           
 
Method Summary
 String getConfigurableID()
          Gets the ID of the configurable object.
abstract  String getID()
          Gets the ID of the new call manager.
 String getManagerID()
          Gets the ID of a manager implementation
 int getPriority()
          Gets priority of a manager, which is needed to be handled by the framework.
abstract  IRuntime getRuntime()
          Gets the runtime objects.
 boolean isActive()
          Gets the status of the repository manager
 void restart()
          This method is called on restart time by the runtime object.
 void setConfiguration(Properties configuration)
          Sets the configuration in the configurable object.
 void setManagerID(String id)
          Sets the ID of a manager implementation
 void shutdown()
          This method is called on shutdown time by the runtime object.
 void startup()
          This method is called on startup time by the runtime object.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface de.janrufmonitor.framework.manager.IRepositoryManager
isSupported
 
Methods inherited from interface de.janrufmonitor.framework.configuration.IConfigurable
getNamespace
 

Field Detail

CFG_PRIO

protected String CFG_PRIO

CFG_ENABLED

protected String CFG_ENABLED

m_logger

protected Logger m_logger

m_externalID

protected String m_externalID

m_configuration

protected Properties m_configuration
Constructor Detail

AbstractConfigurableCallManager

public AbstractConfigurableCallManager()
Method Detail

getID

public abstract String getID()
Gets the ID of the new call manager. The ID is taken for registration at call manager factory and at the configurable notifier.

Returns:
call manager ID

getRuntime

public abstract IRuntime getRuntime()
Gets the runtime objects.

Returns:
the current runtime object.

isActive

public boolean isActive()
Description copied from interface: IRepositoryManager
Gets the status of the repository manager

Specified by:
isActive in interface IRepositoryManager
Returns:
true, if the repository manager is active

getPriority

public int getPriority()
Description copied from interface: IManager
Gets priority of a manager, which is needed to be handled by the framework.

Specified by:
getPriority in interface IManager
Returns:
Id of this Manager

setConfiguration

public void setConfiguration(Properties configuration)
Description copied from interface: IConfigurable
Sets the configuration in the configurable object. This method is called by the configuration notifier to interact with its registered components.

Specified by:
setConfiguration in interface IConfigurable
Parameters:
configuration - the configuration for the given namespace

getConfigurableID

public String getConfigurableID()
Description copied from interface: IConfigurable
Gets the ID of the configurable object.

Specified by:
getConfigurableID in interface IConfigurable
Returns:
a valid and unique ID

setManagerID

public void setManagerID(String id)
Description copied from interface: IManager
Sets the ID of a manager implementation

Specified by:
setManagerID in interface IManager

getManagerID

public String getManagerID()
Description copied from interface: IManager
Gets the ID of a manager implementation

Specified by:
getManagerID in interface IManager
Returns:
Id of this Manager

shutdown

public void shutdown()
Description copied from interface: IManager
This method is called on shutdown time by the runtime object.

Specified by:
shutdown in interface IManager

startup

public void startup()
Description copied from interface: IManager
This method is called on startup time by the runtime object.

Specified by:
startup in interface IManager

restart

public void restart()
Description copied from interface: IManager
This method is called on restart time by the runtime object.

Specified by:
restart in interface IManager

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2010 by Thilo Brandt. All Rights Reserved.