You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@felix.apache.org by bu...@apache.org on 2015/03/12 22:35:32 UTC

svn commit: r943586 - in /websites/staging/felix/trunk/content: ./ documentation/subprojects/apache-felix-dependency-manager/reference/components.html

Author: buildbot
Date: Thu Mar 12 21:35:31 2015
New Revision: 943586

Log:
Staging update by buildbot for felix

Modified:
    websites/staging/felix/trunk/content/   (props changed)
    websites/staging/felix/trunk/content/documentation/subprojects/apache-felix-dependency-manager/reference/components.html

Propchange: websites/staging/felix/trunk/content/
------------------------------------------------------------------------------
--- cms:source-revision (original)
+++ cms:source-revision Thu Mar 12 21:35:31 2015
@@ -1 +1 @@
-1666191
+1666311

Modified: websites/staging/felix/trunk/content/documentation/subprojects/apache-felix-dependency-manager/reference/components.html
==============================================================================
--- websites/staging/felix/trunk/content/documentation/subprojects/apache-felix-dependency-manager/reference/components.html (original)
+++ websites/staging/felix/trunk/content/documentation/subprojects/apache-felix-dependency-manager/reference/components.html Thu Mar 12 21:35:31 2015
@@ -96,6 +96,35 @@
 <li><code>()</code>.</li>
 </ul>
 <p>If you don't specify anything, the methods with these names will be invoked on the instance. By using <code>setCallbacks()</code> you can however change this behavior: You can change the names of the methods to look for. Any methods that are set to <code>null</code> will not be invoked at all. Another thing you can do is to specify a different instance to invoke these methods on. If you do that, you will usually want to use the first signature, which gives you a reference to the <code>Component</code> whose life cycle method was invoked.</p>
+<p>Here is a descrition of the component states:</p>
+<ul>
+<li>
+<p><em>Inactive state</em>: The Component is defined, but not enabled (not yet added to a
+DependencyManager object, or the bundle has been stopped). </p>
+</li>
+<li>
+<p><em>Waiting for required</em> state: The Component is enabled (has been added to a
+DependencyManager object) and the required dependencies declared in the Activator are 
+tracked. The component remains in the current state until all required dependencies are
+available.</p>
+</li>
+<li>
+<p><em>Instantiated and waiting for required</em> state: All required dependencies declared
+in the Activator are available. The Component has been instantiated, has been injected 
+with all required dependencies, including optional dependencies on class fields (autoconfig).
+and has been invoked in the <em>init</em> callback. Now, if some extra required dependencies have
+been dynamically added in the <em>init</em> callback, then the component remains in the
+current state until all extra required dependencies become available.</p>
+</li>
+<li>
+<p><em>Tracking optional</em>: All Required dependencies are available (including the ones
+that have been dynamically declared from the init component callback). The component has 
+been invoked in the <em>start</em> callback and the optional dependencies (with callbacks) are 
+then tracked.</p>
+</li>
+</ul>
+<h2 id="what-happens-during-component-instantiation">What happens during component instantiation ?</h2>
+<p>TBD (in progress).</p>
 <h2 id="interfaces-and-properties">Interfaces and properties</h2>
 <p>Components in the context of the dependency manager can be published as OSGi services under one or more interface names, plus optionally a set of properties. This is no different than a normal OSGi service. It's important to mention that you don't have to register a service. If you don't, you basically created a component that can do work and have dependencies and a managed life cycle.</p>
 <h2 id="composition">Composition</h2>
@@ -103,7 +132,7 @@
 <h2 id="factories">Factories</h2>
 <p>Out of the box, there already is support for lazy instantiation, meaning that the dependency manager can create component instances for you when their required dependencies are resolved. However, sometimes creating a single instance using a default constructor is not enough. In those cases, you can tell the dependency manager to delegate the creation process to a factory.</p>
       <div class="timestamp" style="margin-top: 30px; font-size: 80%; text-align: right;">
-        Rev. 1665812 by marrs on Wed, 11 Mar 2015 09:02:04 +0000
+        Rev. 1666311 by pderop on Thu, 12 Mar 2015 21:35:06 +0000
       </div>
       <div class="trademarkFooter"> 
         Apache Felix, Felix, Apache, the Apache feather logo, and the Apache Felix project