|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.avalon.framework.component.WrapperComponentManager
This is a ComponentManager
implementation that can wrap around a
ServiceManager
object effectively adapting a ServiceManager
interface to a ComponentManager
interface.
Constructor Summary | |
WrapperComponentManager(ServiceManager manager)
Creation of a new wrapper component manger using a supplied service manager as a source backing the wrapped. |
Method Summary | |
boolean |
hasComponent(java.lang.String key)
Check to see if a Component exists for a key. |
Component |
lookup(java.lang.String key)
Retrieve a component via a key. |
void |
release(Component component)
Return the Component when you are finished with it. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public WrapperComponentManager(ServiceManager manager)
manager
- the service manager backing the wrapper.Method Detail |
public Component lookup(java.lang.String key) throws ComponentException
lookup
in interface ComponentManager
key
- the key
ComponentException
- if unable to aquire componentpublic boolean hasComponent(java.lang.String key)
Component
exists for a key.
hasComponent
in interface ComponentManager
key
- a string identifying the key to check.
public void release(Component component)
Component
when you are finished with it. This
allows the ComponentManager
to handle the End-Of-Life Lifecycle
events associated with the Component. Please note, that no Exceptions
should be thrown at this point. This is to allow easy use of the
ComponentManager system without having to trap Exceptions on a release.
release
in interface ComponentManager
component
- The Component we are releasing.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |