fixed javadoc
git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@987878 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/dependencymanager/annotation/src/main/java/org/apache/felix/dm/annotation/api/LifecycleController.java b/dependencymanager/annotation/src/main/java/org/apache/felix/dm/annotation/api/LifecycleController.java
index a8b59b0..84bd946 100644
--- a/dependencymanager/annotation/src/main/java/org/apache/felix/dm/annotation/api/LifecycleController.java
+++ b/dependencymanager/annotation/src/main/java/org/apache/felix/dm/annotation/api/LifecycleController.java
@@ -28,17 +28,17 @@
* Injects a <code>Runnable</code> object in a Service for starting/stopping it programatically.
* By default, a Service is implicitly started when the service's bundle is started and when
* all required dependencies are satisfied. However, it is sometimes required to programatically
- * take control of when the service started or stopped. In this case, the injected <code>Runnable</code>
+ * take control of when the service is started or stopped. In this case, the injected <code>Runnable</code>
* can be invoked in order to start (and eventually register) a Service at any time. When this annotation
- * is used, then the Service on which this annotation is applied is not provided once the Service is ready,
- * as it is the case by default and you have to call the injected Runnable yourself.
+ * is used, then the Service on which this annotation is applied is not activated by default, and you have to
+ * call the injected Runnable yourself.
* <p>
* <h3>Usage Examples</h3>
* <blockquote>
*
* <pre>
* /**
- * * This Service will be registered programatically into the OSGi registry, using the publisher attribute.
+ * * This Service will be registered programatically into the OSGi registry, using the LifecycleController annotation.
* */
* @Service
* class X implements Z {
@@ -47,17 +47,20 @@
*
* @Init
* void init() {
- * // Our component won't be started by default once the bundle is started and when all
- * // required dependencies are injected. Our Component will be registered only when we
- * // decide to invoke the Runnable injected by the LifecycleController annotation.
- * }
- *
- * public void registerServiceWheneverIWant() {
- * m_starter.run(); // start our component.
+ * // At this point, all required dependencies are there, but we'll activate our service in 2 seconds ...
+ * Thread t = new Thread() {
+ * public void run() {
+ * sleep(2000);
+ * m_starter.run();
+ * }
+ * };
+ * t.start();
* }
*
+ * @Start
* public void start() {
- * // This method will be called after we invoke our m_starter Runnable.
+ * // This method will be called after we invoke our m_starter Runnable, and our service will be
+ * // published after our method returns, as in normal case.
* }
* }
* </pre>
@@ -68,7 +71,7 @@
public @interface LifecycleController
{
/**
- * Specify the action to be performed when the Injected runnable is invoked. By default, the
+ * Specifies the action to be performed when the Injected runnable is invoked. By default, the
* Runnable will fire a Service Component activation, when invoked. If you specify this attribute
* to false, then the Service Component will be stopped, when the runnable is invoked.
*/