|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.avalon.framework.logger.AbstractLogEnabled org.apache.avalon.cornerstone.services.connection.AbstractHandlerFactory
Helper class to extend to create handler factorys.
Constructor Summary | |
AbstractHandlerFactory()
|
Method Summary | |
void |
configure(Configuration configuration)
Pass the Configuration to the Configurable
class. |
void |
contextualize(Context context)
Pass the Context to the component. |
ConnectionHandler |
createConnectionHandler()
Construct an appropriate ConnectionHandler. |
protected abstract ConnectionHandler |
newHandler()
Overide this method to create actual instance of connection handler. |
void |
releaseConnectionHandler(ConnectionHandler connectionHandler)
Release a previously created ConnectionHandler. |
void |
service(ServiceManager serviceManager)
Pass the ServiceManager to the Serviceable . |
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled |
enableLogging, getLogger, setupLogger, setupLogger, setupLogger |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public AbstractHandlerFactory()
Method Detail |
public void contextualize(Context context)
Contextualizable
contextualize
in interface Contextualizable
context
- the context. Must not be null
.public void service(ServiceManager serviceManager) throws ServiceException
Serviceable
ServiceManager
to the Serviceable
.
The Serviceable
implementation should use the specified
ServiceManager
to acquire the components it needs for
execution.
service
in interface Serviceable
serviceManager
- The ServiceManager
which this
Serviceable
uses. Must not be null
.
ServiceException
- if an error occurspublic void configure(Configuration configuration) throws ConfigurationException
Configurable
Configuration
to the Configurable
class.
configure
in interface Configurable
configuration
- the class configurations. Must not be null
.
ConfigurationException
- if an error occurspublic ConnectionHandler createConnectionHandler() throws java.lang.Exception
createConnectionHandler
in interface ConnectionHandlerFactory
java.lang.Exception
- if an error occurspublic void releaseConnectionHandler(ConnectionHandler connectionHandler)
ConnectionHandlerFactory
releaseConnectionHandler
in interface ConnectionHandlerFactory
protected abstract ConnectionHandler newHandler() throws java.lang.Exception
java.lang.Exception
- if an error occurs
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |