public class HandlerManagerFactory extends ComponentFactory implements HandlerFactory
IPojoFactory.DefaultNameGenerator, IPojoFactory.NameGenerator, IPojoFactory.RequiredHandler, IPojoFactory.RetryNameGenerator
HANDLER_AUTO_PRIMITIVE, m_tracker
INSTANCE_NAME, m_componentDesc, m_componentInstances, m_componentMetadata, m_context, m_factoryName, m_isPublic, m_listeners, m_logger, m_requiredHandlers, m_sr, m_state, m_version
IPOJO_NAMESPACE
FACTORY_VERSION_PROPERTY, INSTANCE_NAME_PROPERTY, INVALID, VALID
Constructor and Description |
---|
HandlerManagerFactory(org.osgi.framework.BundleContext context,
org.apache.felix.ipojo.metadata.Element metadata)
Creates a handler factory.
|
Modifier and Type | Method and Description |
---|---|
ComponentInstance |
createInstance(java.util.Dictionary configuration,
IPojoContext context,
HandlerManager[] handlers)
Creates an instance.
|
ComponentTypeDescription |
getComponentTypeDescription()
Gets the component type description of the current factory.
|
java.lang.String |
getFactoryName()
Computes the factory name.
|
java.lang.String |
getHandlerName()
Gets the name associated with this handler factory.
|
java.lang.String |
getNamespace()
Gets the namespace associated with this handler factory.
|
java.util.List<IPojoFactory.RequiredHandler> |
getRequiredHandlerList()
Computes required handlers.
|
int |
getStartLevel()
Gets the start level of the handler objects created by this factory.
|
java.lang.String |
getType()
Gets the type of the handler factory.
|
void |
stopping()
Stops the factory.
|
addedService, addingService, check, defineClass, getBundleClassLoader, getClassName, getPojoMetadata, getVersion, loadClass, modifiedService, removedService, setUseFactoryClassloader, starting
addFactoryStateListener, checkAcceptability, computeDescription, computeFactoryState, createComponentInstance, createComponentInstance, deleted, dispose, disposed, getBundleContext, getComponentDescription, getComponentMetadata, getDescription, getHandler, getInstanceByName, getInstances, getInstancesNames, getIPOJOBundleContext, getLogger, getMissingHandlers, getName, getRequiredHandlers, getState, isAcceptable, match, reconfigure, removeFactoryStateListener, restart, start, stop, updated
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addFactoryStateListener, createComponentInstance, createComponentInstance, getBundleContext, getClassName, getComponentDescription, getComponentMetadata, getDescription, getInstances, getInstancesNames, getMissingHandlers, getName, getRequiredHandlers, getState, getVersion, isAcceptable, reconfigure, removeFactoryStateListener
public HandlerManagerFactory(org.osgi.framework.BundleContext context, org.apache.felix.ipojo.metadata.Element metadata) throws ConfigurationException
context
- the bundle contextmetadata
- the metadata of the component to createConfigurationException
- if the element describing the factory is malformed.public java.lang.String getNamespace()
HandlerFactory
getNamespace
in interface HandlerFactory
public java.lang.String getHandlerName()
HandlerFactory
getHandlerName
in interface HandlerFactory
public java.lang.String getType()
HandlerFactory
primitive
and composite
.getType
in interface HandlerFactory
public int getStartLevel()
HandlerFactory
getStartLevel
in interface HandlerFactory
public ComponentTypeDescription getComponentTypeDescription()
ComponentFactory
getComponentTypeDescription
in class ComponentFactory
IPojoFactory.getComponentTypeDescription()
public java.lang.String getFactoryName()
ComponentFactory
getFactoryName
in class ComponentFactory
public void stopping()
stopping
in class ComponentFactory
public ComponentInstance createInstance(java.util.Dictionary configuration, IPojoContext context, HandlerManager[] handlers) throws ConfigurationException
createInstance
in class ComponentFactory
configuration
- the configuration of the created instance.context
- the service context to push for this instance.handlers
- the handler array to attach to the instance.HandlerManager
.ConfigurationException
- if the instance configuration failed.Factory.createComponentInstance(java.util.Dictionary)
public java.util.List<IPojoFactory.RequiredHandler> getRequiredHandlerList()
getRequiredHandlerList
in class ComponentFactory
Copyright © 2006-2014 The Apache Software Foundation. All Rights Reserved.