public class ExcaliburComponentSelector extends AbstractDualLogEnabled implements org.apache.avalon.framework.context.Contextualizable, org.apache.avalon.framework.component.ComponentSelector, org.apache.avalon.framework.component.Composable, org.apache.avalon.framework.configuration.Configurable, org.apache.avalon.framework.activity.Initializable, org.apache.avalon.framework.thread.ThreadSafe, org.apache.avalon.framework.activity.Disposable, RoleManageable, org.apache.avalon.excalibur.logger.LogKitManageable, org.apache.avalon.excalibur.logger.LoggerManageable, org.apache.excalibur.instrument.InstrumentManageable, org.apache.excalibur.instrument.Instrumentable
| Modifier and Type | Field and Description |
|---|---|
private static java.lang.String |
DEFAULT_NAME
Deprecated.
The ComponentSelector's name for logging purposes.
|
private java.util.Map |
m_componentHandlers
Deprecated.
Static component handlers.
|
private org.apache.avalon.framework.component.ComponentManager |
m_componentManager
Deprecated.
The application context for components
|
private java.util.Map |
m_componentMapping
Deprecated.
Dynamic component handlers mapping.
|
private org.apache.avalon.framework.configuration.Configuration |
m_configuration
Deprecated.
Static configuraiton object.
|
protected org.apache.avalon.framework.context.Context |
m_context
Deprecated.
The application context for components
|
private boolean |
m_disposed
Deprecated.
Flag for if this is disposed or not.
|
private boolean |
m_initialized
Deprecated.
Flag for if this is initialized or not.
|
private java.lang.String |
m_instrumentableName
Deprecated.
Instrumentable Name assigned to this Instrumentable
|
private org.apache.excalibur.instrument.InstrumentManager |
m_instrumentManager
Deprecated.
Instrument Manager to register objects created by this selector with (May be null).
|
private java.lang.ClassLoader |
m_loader
Deprecated.
The classloader used for this system.
|
private LogkitLoggerManager |
m_logkit
Deprecated.
The RoleManager to get hint shortcuts
|
private java.lang.String |
m_rolename
Deprecated.
The role name for this instance
|
private RoleManager |
m_roles
Deprecated.
The RoleManager to get hint shortcuts
|
| Constructor and Description |
|---|
ExcaliburComponentSelector()
Deprecated.
Create the ComponentSelector
|
ExcaliburComponentSelector(java.lang.ClassLoader loader)
Deprecated.
Create the ComponentSelector with a Classloader
|
| Modifier and Type | Method and Description |
|---|---|
void |
addComponent(java.lang.Object hint,
java.lang.Class component,
org.apache.avalon.framework.configuration.Configuration configuration)
Deprecated.
Add a new component to the manager.
|
void |
addComponentInstance(java.lang.Object hint,
org.apache.avalon.framework.component.Component instance)
Deprecated.
Add a static instance of a component to the manager.
|
protected boolean |
canRelease(org.apache.avalon.framework.component.Component component)
Deprecated.
Is this component looked up using this selector?
|
void |
compose(org.apache.avalon.framework.component.ComponentManager componentManager)
Deprecated.
Compose the ComponentSelector so that we know what the parent ComponentLocator is.
|
void |
configure(org.apache.avalon.framework.configuration.Configuration configuration)
Deprecated.
Default Configuration handler for ComponentSelector.
|
void |
contextualize(org.apache.avalon.framework.context.Context context)
Deprecated.
Provide the application Context.
|
void |
dispose()
Deprecated.
Properly dispose of all the ComponentHandlers.
|
org.apache.excalibur.instrument.Instrumentable[] |
getChildInstrumentables()
Deprecated.
Any Object which implements Instrumentable can also make use of other
Instrumentable child objects.
|
protected ComponentHandler |
getComponentHandler(java.lang.String role,
java.lang.Class componentClass,
org.apache.avalon.framework.configuration.Configuration configuration,
org.apache.avalon.framework.component.ComponentManager componentManager,
org.apache.avalon.framework.context.Context context,
RoleManager roleManager,
LogkitLoggerManager logkitManager)
Deprecated.
Obtain a new ComponentHandler for the specified component.
|
protected java.util.Map |
getComponentHandlers()
Deprecated.
Makes the ComponentHandlers available to subclasses.
|
java.lang.String |
getInstrumentableName()
Deprecated.
Gets the name of the Instrumentable.
|
org.apache.excalibur.instrument.Instrument[] |
getInstruments()
Deprecated.
Obtain a reference to all the Instruments that the Instrumentable object
wishes to expose.
|
private java.lang.String |
getName()
Deprecated.
Return this selector's configuration name or a default name if no such
configuration was provided.
|
boolean |
hasComponent(java.lang.Object hint)
Deprecated.
Tests for existence of a component.
|
void |
initialize()
Deprecated.
Properly initialize of the Child handlers.
|
void |
release(org.apache.avalon.framework.component.Component component)
Deprecated.
Release the Component to the propper ComponentHandler.
|
org.apache.avalon.framework.component.Component |
select(java.lang.Object hint)
Deprecated.
Return an instance of a component based on a hint.
|
void |
setInstrumentableName(java.lang.String name)
Deprecated.
Sets the name for the Instrumentable.
|
void |
setInstrumentManager(org.apache.excalibur.instrument.InstrumentManager instrumentManager)
Deprecated.
Sets the InstrumentManager for child components.
|
void |
setLoggerManager(org.apache.avalon.excalibur.logger.LoggerManager logkit)
Deprecated.
Configure the LoggerManager.
|
void |
setLogKitManager(org.apache.avalon.excalibur.logger.LogKitManager logkit)
Deprecated.
Configure the LogKitManager
|
void |
setRoleManager(RoleManager roles)
Deprecated.
Configure the RoleManager
|
getLogkitLogger, setLoggerprivate final java.lang.ClassLoader m_loader
private static final java.lang.String DEFAULT_NAME
private java.lang.String m_rolename
protected org.apache.avalon.framework.context.Context m_context
private org.apache.avalon.framework.component.ComponentManager m_componentManager
private org.apache.avalon.framework.configuration.Configuration m_configuration
private java.util.Map m_componentHandlers
private java.util.Map m_componentMapping
private boolean m_disposed
private boolean m_initialized
private RoleManager m_roles
private LogkitLoggerManager m_logkit
private org.apache.excalibur.instrument.InstrumentManager m_instrumentManager
private java.lang.String m_instrumentableName
public ExcaliburComponentSelector()
public ExcaliburComponentSelector(java.lang.ClassLoader loader)
public void contextualize(org.apache.avalon.framework.context.Context context)
contextualize in interface org.apache.avalon.framework.context.Contextualizablepublic org.apache.avalon.framework.component.Component select(java.lang.Object hint)
throws org.apache.avalon.framework.component.ComponentException
select in interface org.apache.avalon.framework.component.ComponentSelectororg.apache.avalon.framework.component.ComponentExceptionpublic boolean hasComponent(java.lang.Object hint)
hasComponent in interface org.apache.avalon.framework.component.ComponentSelectorpublic void release(org.apache.avalon.framework.component.Component component)
release in interface org.apache.avalon.framework.component.ComponentSelectorprotected boolean canRelease(org.apache.avalon.framework.component.Component component)
public void compose(org.apache.avalon.framework.component.ComponentManager componentManager)
throws org.apache.avalon.framework.component.ComponentException
compose in interface org.apache.avalon.framework.component.Composableorg.apache.avalon.framework.component.ComponentExceptionpublic void configure(org.apache.avalon.framework.configuration.Configuration configuration)
throws org.apache.avalon.framework.configuration.ConfigurationException
configure in interface org.apache.avalon.framework.configuration.Configurableorg.apache.avalon.framework.configuration.ConfigurationExceptionpublic void initialize()
initialize in interface org.apache.avalon.framework.activity.Initializablepublic void dispose()
dispose in interface org.apache.avalon.framework.activity.Disposablepublic void setRoleManager(RoleManager roles)
setRoleManager in interface RoleManageablepublic void setLogKitManager(org.apache.avalon.excalibur.logger.LogKitManager logkit)
setLogKitManager in interface org.apache.avalon.excalibur.logger.LogKitManageablepublic void setInstrumentManager(org.apache.excalibur.instrument.InstrumentManager instrumentManager)
setInstrumentManager in interface org.apache.excalibur.instrument.InstrumentManageableinstrumentManager - The InstrumentManager for the component to use.public void setInstrumentableName(java.lang.String name)
This value may be set by a parent Instrumentable, or by the InstrumentManager using the value of the 'instrumentable' attribute in the configuration of the component.
setInstrumentableName in interface org.apache.excalibur.instrument.Instrumentablename - The name used to identify a Instrumentable.public java.lang.String getInstrumentableName()
getInstrumentableName in interface org.apache.excalibur.instrument.Instrumentablepublic org.apache.excalibur.instrument.Instrument[] getInstruments()
getInstruments in interface org.apache.excalibur.instrument.Instrumentablepublic org.apache.excalibur.instrument.Instrumentable[] getChildInstrumentables()
getChildInstrumentables in interface org.apache.excalibur.instrument.Instrumentablepublic void setLoggerManager(org.apache.avalon.excalibur.logger.LoggerManager logkit)
setLoggerManager in interface org.apache.avalon.excalibur.logger.LoggerManageableprotected ComponentHandler getComponentHandler(java.lang.String role, java.lang.Class componentClass, org.apache.avalon.framework.configuration.Configuration configuration, org.apache.avalon.framework.component.ComponentManager componentManager, org.apache.avalon.framework.context.Context context, RoleManager roleManager, LogkitLoggerManager logkitManager) throws java.lang.Exception
componentClass - Class of the component for which the handle is
being requested.configuration - The configuration for this component.componentManager - The ComponentLocator which will be managing
the Component.context - The current context object.roleManager - The current RoleManager.logkitManager - The current LogKitManager.java.lang.Exception - If there were any problems obtaining a ComponentHandlerprotected java.util.Map getComponentHandlers()
public void addComponent(java.lang.Object hint,
java.lang.Class component,
org.apache.avalon.framework.configuration.Configuration configuration)
throws org.apache.avalon.framework.component.ComponentException
hint - the hint name for the new component.component - the class of this component.configuration - the configuration for this component.org.apache.avalon.framework.component.ComponentExceptionpublic void addComponentInstance(java.lang.Object hint,
org.apache.avalon.framework.component.Component instance)
hint - the hint for the component.instance - the instance of the component.private java.lang.String getName()
addComponentInstance with no associated configuration