|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.felix.ipojo.handlers.providedservice.ProvidedService
public class ProvidedService
Provided Service represent a provided service by the component.
Field Summary | |
---|---|
static int |
INSTANCE_STRATEGY
Factory policy : INSTANCE. |
static int |
REGISTERED
Service State : REGISTRED. |
static int |
SERVICE_STRATEGY
Factory policy : SERVICE_FACTORY. |
static int |
SINGLETON_STRATEGY
Factory Policy : SINGLETON_FACTORY. |
static int |
STATIC_STRATEGY
Factory policy : STATIC_FACTORY. |
static int |
UNREGISTERED
Service State : UNREGISTRED. |
Constructor Summary | |
---|---|
ProvidedService(ProvidedServiceHandler handler,
String[] specification,
int factoryPolicy,
Class creationStrategyClass)
Creates a provided service object. |
Method Summary | |
---|---|
protected void |
addProperties(Dictionary props)
Add properties to the list. |
protected void |
deleteProperties(Dictionary props)
Remove properties from the list. |
protected InstanceManager |
getInstanceManager()
|
Property[] |
getProperties()
Get the list of properties attached to the service registration. |
Object |
getService(Bundle bundle,
ServiceRegistration registration)
Return a service object for the dependency. |
ServiceReference |
getServiceReference()
Get the service reference of the service registration. |
ServiceRegistration |
getServiceRegistration()
Get the service registration. |
String[] |
getServiceSpecifications()
Get the published service specifications. |
int |
getState()
Get the current provided service state. |
protected void |
registerService()
Registers the service. |
protected void |
setProperties(Property[] props)
Add properties to the provided service. |
void |
ungetService(Bundle bundle,
ServiceRegistration registration,
Object service)
The unget method. |
protected void |
unregisterService()
Unregisters the service. |
void |
update()
Update the service properties. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int REGISTERED
public static final int UNREGISTERED
public static final int SINGLETON_STRATEGY
public static final int SERVICE_STRATEGY
public static final int STATIC_STRATEGY
public static final int INSTANCE_STRATEGY
Constructor Detail |
---|
public ProvidedService(ProvidedServiceHandler handler, String[] specification, int factoryPolicy, Class creationStrategyClass)
handler
- the the provided service handler.specification
- the specifications provided by this provided servicefactoryPolicy
- the service providing policycreationStrategyClass
- the customized service object creation strategy.Method Detail |
---|
protected void setProperties(Property[] props)
props
- : the properties to attached to the service registrationpublic ServiceReference getServiceReference()
public Object getService(Bundle bundle, ServiceRegistration registration)
getService
in interface ServiceFactory
bundle
- : the bundleregistration
- : the service registration of the registred service
ServiceFactory.getService(org.osgi.framework.Bundle, org.osgi.framework.ServiceRegistration)
public void ungetService(Bundle bundle, ServiceRegistration registration, Object service)
ungetService
in interface ServiceFactory
bundle
- : bundleregistration
- : service registrationservice
- : service objectServiceFactory.ungetService(org.osgi.framework.Bundle,
org.osgi.framework.ServiceRegistration, java.lang.Object)
protected void registerService()
protected void unregisterService()
public int getState()
protected InstanceManager getInstanceManager()
public Property[] getProperties()
public void update()
protected void addProperties(Dictionary props)
props
- : properties to addprotected void deleteProperties(Dictionary props)
props
- : properties to removepublic String[] getServiceSpecifications()
public ServiceRegistration getServiceRegistration()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |