public class ServiceContainerImpl extends Object implements ServiceContainer, ServiceConstants
CLAZZ_NAME, COMPONENT_CONFIG_KEY, COMPONENT_CONFIG_PROPERTIES_KEY, COMPONENT_CONFIG_VALUE, COMPONENT_CONTAINERFLAVOUR_VALUE, COMPONENT_ISENCRYPTED_KEY, COMPONENT_LOCATION_KEY, COMPONENT_PARAMETERS_KEY, COMPONENT_PARAMETERS_VALUE, COMPONENT_ROLE_KEYS, COMPONENT_ROLE_VALUE, COMPONENT_ROLECONFIGFLAVOUR_VALUE, CONTAINERCLAZZNAME_CONFIG_KEY, CONTAINERFLAVOUR_CONFIG_KEY, DISPOSAL_DELAY_KEY, DYNAMICPROXY_ENABLED_KEY, INTERCEPTOR_KEY, INTERCEPTOR_LIST_KEY, RECONFIGURATION_DELAY_KEY, ROLE_NAME, SERVICEMANAGER_KEY, SERVICEMANAGER_LIST_KEYAVALON_CONTAINER_YAAFI, COMPONENT_APP_ROOT, URN_AVALON_CLASSLOADER, URN_AVALON_HOME, URN_AVALON_NAME, URN_AVALON_PARTITION, URN_AVALON_TEMP| Constructor and Description |
|---|
ServiceContainerImpl()
Constructor using sensible defaults.
|
| Modifier and Type | Method and Description |
|---|---|
void |
configure(org.apache.avalon.framework.configuration.Configuration configuration) |
void |
contextualize(org.apache.avalon.framework.context.Context context) |
void |
decommission(String name)
Decommision the given service by calling Startable.stop()
and Disposable.dispose().
|
void |
dispose()
Disposes the service container implementation.
|
void |
enableLogging(org.apache.avalon.framework.logger.Logger logger) |
org.apache.avalon.framework.parameters.Parameters |
getParameters()
Return the Avalon parameters loaded by the Avalon service container
|
RoleEntry[] |
getRoleEntries()
Get a list of all RoleEntries.
|
RoleEntry |
getRoleEntry(String name)
Get a RoleEntryImpl for a given service
|
boolean |
hasService(String name) |
void |
initialize() |
Object |
lookup(String name)
Lookup a service instance.
|
void |
parameterize(org.apache.avalon.framework.parameters.Parameters parameters) |
void |
reconfigure(org.apache.avalon.framework.configuration.Configuration configuration)
Reconfiguring the services.
|
void |
reconfigure(String[] names)
Reconfigures a set of services by calling Suspendable.suspend(),
Reconfigurable.reconfigure() and Suspendable.resume().
|
void |
release(Object object) |
void |
service(org.apache.avalon.framework.service.ServiceManager serviceManager) |
String |
toString() |
public ServiceContainerImpl()
public void enableLogging(org.apache.avalon.framework.logger.Logger logger)
enableLogging in interface org.apache.avalon.framework.logger.LogEnabledLogEnabled.enableLogging(org.apache.avalon.framework.logger.Logger)public void contextualize(org.apache.avalon.framework.context.Context context) throws org.apache.avalon.framework.context.ContextException
contextualize in interface org.apache.avalon.framework.context.Contextualizableorg.apache.avalon.framework.context.ContextExceptionContextualizable.contextualize(org.apache.avalon.framework.context.Context)public void service(org.apache.avalon.framework.service.ServiceManager serviceManager) throws org.apache.avalon.framework.service.ServiceException
service in interface org.apache.avalon.framework.service.Serviceableorg.apache.avalon.framework.service.ServiceExceptionServiceable.service(org.apache.avalon.framework.service.ServiceManager)public 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.ConfigurationExceptionConfigurable.configure(org.apache.avalon.framework.configuration.Configuration)public void parameterize(org.apache.avalon.framework.parameters.Parameters parameters) throws org.apache.avalon.framework.parameters.ParameterException
parameterize in interface org.apache.avalon.framework.parameters.Parameterizableorg.apache.avalon.framework.parameters.ParameterExceptionParameterizable.parameterize(org.apache.avalon.framework.parameters.Parameters)public void initialize() throws Exception
initialize in interface org.apache.avalon.framework.activity.InitializableExceptionInitializable.initialize()public void dispose()
dispose in interface org.apache.avalon.framework.activity.DisposableDisposable.dispose()public void reconfigure(org.apache.avalon.framework.configuration.Configuration configuration) throws org.apache.avalon.framework.configuration.ConfigurationException
reconfigure in interface org.apache.avalon.framework.configuration.Reconfigurableorg.apache.avalon.framework.configuration.ConfigurationExceptionReconfigurable.reconfigure(org.apache.avalon.framework.configuration.Configuration)public RoleEntry getRoleEntry(String name) throws org.apache.avalon.framework.service.ServiceException
ServiceLifecycleManagergetRoleEntry in interface ServiceLifecycleManagername - the name of the service componentorg.apache.avalon.framework.service.ServiceException - the service was not foundServiceLifecycleManager.getRoleEntry(java.lang.String)public RoleEntry[] getRoleEntries()
ServiceLifecycleManagergetRoleEntries in interface ServiceLifecycleManagerServiceLifecycleManager.getRoleEntries()public void reconfigure(String[] names) throws org.apache.avalon.framework.service.ServiceException, org.apache.avalon.framework.configuration.ConfigurationException
ServiceLifecycleManagerreconfigure in interface ServiceLifecycleManagernames - the set of services to be reconfiguredorg.apache.avalon.framework.service.ServiceException - one of the service was not foundorg.apache.avalon.framework.configuration.ConfigurationException - the reconfiguration failedServiceLifecycleManager.reconfigure(java.lang.String[])public boolean hasService(String name)
hasService in interface org.apache.avalon.framework.service.ServiceManagerServiceManager.hasService(java.lang.String)public Object lookup(String name) throws org.apache.avalon.framework.service.ServiceException
lookup in interface org.apache.avalon.framework.service.ServiceManagerorg.apache.avalon.framework.service.ServiceExceptionServiceManager.lookup(java.lang.String)public void release(Object object)
release in interface org.apache.avalon.framework.service.ServiceManagerpublic void decommission(String name) throws org.apache.avalon.framework.service.ServiceException
ServiceLifecycleManagerdecommission in interface ServiceLifecycleManagername - the name of the serviceorg.apache.avalon.framework.service.ServiceException - the service was not foundServiceLifecycleManager.decommission(java.lang.String)public org.apache.avalon.framework.parameters.Parameters getParameters()
ServiceContainergetParameters in interface ServiceContainerServiceContainer.getParameters()public String toString()
toString in class ObjectObject.toString()Copyright © 2004–1970 The Apache Software Foundation. All rights reserved.