|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.felix.ipojo.api.ComponentType
org.apache.felix.ipojo.api.PrimitiveComponentType
org.apache.felix.ipojo.api.SingletonComponentType
public class SingletonComponentType
Allows defining a primitive component type that create an unique instance when created. The factory is set to private by default.
Constructor Summary | |
---|---|
SingletonComponentType()
Creates a SingletonComponentType. |
Method Summary | |
---|---|
ComponentInstance |
create()
Starts the component type and creates the singleton instance. |
ComponentInstance |
create(Dictionary conf)
Starts the component type and creates the singleton instance. |
ComponentInstance |
create(String name)
Starts the component type and creates the singleton instance. |
SingletonComponentType |
setObject(Object obj)
Sets the pojo object used by the instance. |
Methods inherited from class org.apache.felix.ipojo.api.PrimitiveComponentType |
---|
addDependency, addDependency, addHandler, addProperty, addProperty, addService, getFactory, setBundleContext, setClassName, setComponentTypeName, setComponentTypeVersion, setFactoryMethod, setImmediate, setInvalidateMethod, setManagedServicePID, setPropagation, setPublic, setUpdatedMethod, setValidateMethod, start, stop |
Methods inherited from class org.apache.felix.ipojo.api.ComponentType |
---|
createInstance, createInstance, createInstance, disposeInstance, disposeInstance, getInstanceByName |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SingletonComponentType()
Method Detail |
---|
public SingletonComponentType setObject(Object obj)
obj
- the object.
public ComponentInstance create() throws UnacceptableConfiguration, MissingHandlerException, ConfigurationException
PrimitiveComponentType.start()
and the
ComponentType.createInstance()
methods.
ConfigurationException
- occurs if the type description is
incorrect
MissingHandlerException
- occurs if a handler is not available
UnacceptableConfiguration
- occurs if the configuration is not
acceptable by the instanceComponentType.start()
,
ComponentType.createInstance()
public ComponentInstance create(Dictionary conf) throws UnacceptableConfiguration, MissingHandlerException, ConfigurationException
PrimitiveComponentType.start()
and the
ComponentType.createInstance()
methods.
conf
- the instance configuration
ConfigurationException
- occurs if the type description is
incorrect
MissingHandlerException
- occurs if a handler is not available
UnacceptableConfiguration
- occurs if the configuration is not
acceptable by the instanceComponentType.start()
,
ComponentType.createInstance()
public ComponentInstance create(String name) throws UnacceptableConfiguration, MissingHandlerException, ConfigurationException
PrimitiveComponentType.start()
and the
ComponentType.createInstance()
methods.
name
- the name of the instance to create. This parameter will
be used as the instance.name
property.
ConfigurationException
- occurs if the type description is
incorrect
MissingHandlerException
- occurs if a handler is not available
UnacceptableConfiguration
- occurs if the configuration is not
acceptable by the instanceComponentType.start()
,
ComponentType.createInstance()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |