|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.ops4j.pax.swissbox.lifecycle.AbstractLifecycle
org.ops4j.pax.swissbox.tracker.ReplaceableService<T>
public class ReplaceableService<T>
Constructor Summary | |
---|---|
ReplaceableService(org.osgi.framework.BundleContext context,
java.lang.Class<T> serviceClass)
Creates a new replaceable service without a listener. |
|
ReplaceableService(org.osgi.framework.BundleContext context,
java.lang.Class<T> serviceClass,
ReplaceableServiceListener<T> listener)
Creates a new replaceable service. |
Method Summary | |
---|---|
T |
getService()
Returne the current service. |
protected void |
onStart()
Creates a service collection and starts it. |
protected void |
onStop()
Stops the service collection and releases resources. |
Methods inherited from class org.ops4j.pax.swissbox.lifecycle.AbstractLifecycle |
---|
isStarted, start, stop |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ReplaceableService(org.osgi.framework.BundleContext context, java.lang.Class<T> serviceClass)
context
- bundle contextserviceClass
- class of the replaceable servicepublic ReplaceableService(org.osgi.framework.BundleContext context, java.lang.Class<T> serviceClass, ReplaceableServiceListener<T> listener)
context
- bundle contextserviceClass
- class of the replaceable servicelistener
- a listenerMethod Detail |
---|
public T getService()
protected void onStart()
onStart
in class AbstractLifecycle
AbstractLifecycle.onStart()
protected void onStop()
onStop
in class AbstractLifecycle
AbstractLifecycle.onStop()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |