felix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pde...@apache.org
Subject svn commit: r1636297 - in /felix/sandbox/pderop/dependencymanager-prototype: org.apache.felix.dependencymanager.annotation/src/org/apache/felix/dm/annotation/api/ org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/co...
Date Mon, 03 Nov 2014 09:45:16 GMT
Author: pderop
Date: Mon Nov  3 09:45:15 2014
New Revision: 1636297

URL: http://svn.apache.org/r1636297
Log:
FELIX-4684: Removed the constants in org.apache.felix.dm.runtime.api.ComponentFactory.FACTORY_NAME and
org.apache.felix.dm.runtime.api.ComponentFactory.FACTORY_INSTANCE and reuse the constants from
org.apache.felix.dm.annotation.api.Component.FACTORY_NAME and org.apache.felix.dm.annotation.api.Component.FACTORY_INSTANCE.

Also cleaned imports and reformatted some classes.

Modified:
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.annotation/src/org/apache/felix/dm/annotation/api/Component.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectAnnotation.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectLifecycleAnnotation.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectLifecycleWithDynamicProxyAnnotation.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ComponentFactoryAnnotation.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ComponentFactoryServiceTestWthPublisher.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ExtraComponentFactoryServiceProperties.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ServiceFactoryAnnotation.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/tests/ComponentFactoryAnnotationTest.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/ComponentBuilder.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/ComponentInstanceImpl.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/FactorySet.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/api/ComponentFactory.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/composite/ProviderImpl.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/composite/ProviderParticipant2.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/CompositionManager.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/ProviderImpl.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/ProviderParticipant2.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/customdep/PathTracker.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAccess.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAccessImpl.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAndParameterFactory.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceParameterImpl.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceAccess.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceAccessImpl.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceImpl.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceParameterImpl.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/dictionary/annot/SpellChecker.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceConsumer.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceProvider.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceProviderImpl.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceConsumer.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceProvider.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceProviderImpl.java
    felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/tpool/ComponentExecutorFactoryImpl.java

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.annotation/src/org/apache/felix/dm/annotation/api/Component.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.annotation/src/org/apache/felix/dm/annotation/api/Component.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.annotation/src/org/apache/felix/dm/annotation/api/Component.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.annotation/src/org/apache/felix/dm/annotation/api/Component.java Mon Nov  3 09:45:15 2014
@@ -99,12 +99,14 @@ import java.lang.annotation.Target;
  *      }   
  *  }
  * 
+ *  import import org.apache.felix.dm.runtime.api.ComponentFactory;
+ *
  *  /**
  *    * This class will instantiate some X component instances
  *    */
  *  @Component 
  *  class Y {
- *      @ServiceDependency(filter="(" + ComponentFactory.FACTORY_NAME + "=MyComponentFactory)")
+ *      @ServiceDependency(filter="(" + Component.FACTORY_NAME + "=MyComponentFactory)")
  *      ComponentFactory _XFactory;
  *    
  *      @Start
@@ -122,7 +124,7 @@ import java.lang.annotation.Target;
  *          instance1.update(instance1Conf);
  *          
  *          // Instantiate a third X instance, by explicitly providing the implementation object
- *          Dictionary instance3Conf = new Hashtable() {{ put(ComponentFactory.FACTORY_INSTANCE, new X()); }};
+ *          Dictionary instance3Conf = new Hashtable() {{ put(Component.FACTORY_INSTANCE, new X()); }};
  *          ComponentInstance instance3 = _XFactory.newInstance(instance3Conf);
  *      
  *          // Destroy x1/x2/x3 components
@@ -142,6 +144,18 @@ import java.lang.annotation.Target;
 public @interface Component
 {
     /**
+     * Service property name used to match a given Component Factory.
+     * @see #factoryName() for more information about factory sets.
+     */
+    final static String FACTORY_NAME = "dm.factory.name";
+    
+    /**
+     * Key used when providing an implementation for the instantiation of in a component factory.
+     * @see #factoryName()
+     */
+    final static String FACTORY_INSTANCE = "dm.factory.instance";
+
+    /**
      * Sets list of provided interfaces. By default, the directly implemented interfaces are provided.
      */
     Class<?>[] provides() default {};
@@ -178,8 +192,8 @@ public @interface Component
     /**
      * Returns the name of the <code>ComponentFactory</code> used to dynamically instantiate this component.
      * When you set this attribute, a <code>org.apache.felix.dm.runtime.api.ComponentFactory</code> OSGi Service will 
-     * be provided with a <code>dm.runtime.factory.name</code> service property matching 
-     * your specified <code>factoryName</code> attribute.
+     * be provided with a <code>dm.factory.name</code> service property matching your specified <code>factoryName</code> attribute.
+     * 
      * The ComponentFactory will be provided once the component bundle is started, even if required dependencies are not available, and the
      * ComponentFactory will be unregistered from the OSGi registry once the component bundle is stopped or being updated.<p>
      * So, another component may then be injected with this ComponentFactory in order to dynamically instantiate some component instances:
@@ -204,23 +218,5 @@ public @interface Component
     /**
      * Sets the static method used to create the components implementation instance.
      */
-    String factoryMethod() default "";
-        
-    /**
-     * Service property name used to match a given Factory Set.
-     * @see #factorySet() for more information about factory sets.
-     * @deprecated This constant was used by a {@link #factorySet()} annotation which is deprecated. Now a {@link #factoryName()}
-     * and the org.apache.felix.dm.runtime.api.ComponentFactory service can be filtered using the 
-     * org.apache.felix.dm.runtime.api.ComponentFactory.FACTORY_NAME constant.
-     */
-    final static String FACTORY_NAME = "dm.factory.name";
-    
-    /**
-     * Key used when providing an implementation in a factory Set dictionary configuration.
-     * @see #factorySet()
-     * @deprecated This constant was used by a {@link #factorySet()} annotation which is deprecated. Now a {@link #factoryName()}
-     * should be used instead, and a component instance can be stored in the dictionary passed to the ComponentFactory.newInstance() method
-     * using the org.apache.felix.dm.runtime.api.ComponentFactory.FACTORY_INSTANCE key.
-     */
-    final static String FACTORY_INSTANCE = "dm.factory.instance";
+    String factoryMethod() default "";        
 }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectAnnotation.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectAnnotation.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectAnnotation.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectAnnotation.java Mon Nov  3 09:45:15 2014
@@ -19,7 +19,13 @@
 package org.apache.felix.dm.runtime.itest.components;
 
 import org.apache.felix.dm.DependencyManager;
-import org.apache.felix.dm.annotation.api.*;
+import org.apache.felix.dm.annotation.api.AspectService;
+import org.apache.felix.dm.annotation.api.Component;
+import org.apache.felix.dm.annotation.api.Destroy;
+import org.apache.felix.dm.annotation.api.Init;
+import org.apache.felix.dm.annotation.api.Inject;
+import org.apache.felix.dm.annotation.api.ServiceDependency;
+import org.apache.felix.dm.annotation.api.Stop;
 import org.apache.felix.dm.itest.Ensure;
 import org.osgi.framework.BundleContext;
 import org.osgi.framework.ServiceRegistration;

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectLifecycleAnnotation.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectLifecycleAnnotation.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectLifecycleAnnotation.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectLifecycleAnnotation.java Mon Nov  3 09:45:15 2014
@@ -18,7 +18,13 @@
  */
 package org.apache.felix.dm.runtime.itest.components;
 
-import org.apache.felix.dm.annotation.api.*;
+import org.apache.felix.dm.annotation.api.AspectService;
+import org.apache.felix.dm.annotation.api.Component;
+import org.apache.felix.dm.annotation.api.Destroy;
+import org.apache.felix.dm.annotation.api.Init;
+import org.apache.felix.dm.annotation.api.ServiceDependency;
+import org.apache.felix.dm.annotation.api.Start;
+import org.apache.felix.dm.annotation.api.Stop;
 import org.apache.felix.dm.itest.Ensure;
 
 public class AspectLifecycleAnnotation {

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectLifecycleWithDynamicProxyAnnotation.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectLifecycleWithDynamicProxyAnnotation.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectLifecycleWithDynamicProxyAnnotation.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/AspectLifecycleWithDynamicProxyAnnotation.java Mon Nov  3 09:45:15 2014
@@ -22,7 +22,13 @@ import java.lang.reflect.InvocationHandl
 import java.lang.reflect.Method;
 import java.lang.reflect.Proxy;
 
-import org.apache.felix.dm.annotation.api.*;
+import org.apache.felix.dm.annotation.api.AspectService;
+import org.apache.felix.dm.annotation.api.Component;
+import org.apache.felix.dm.annotation.api.Destroy;
+import org.apache.felix.dm.annotation.api.Init;
+import org.apache.felix.dm.annotation.api.ServiceDependency;
+import org.apache.felix.dm.annotation.api.Start;
+import org.apache.felix.dm.annotation.api.Stop;
 import org.apache.felix.dm.itest.Ensure;
 
 public class AspectLifecycleWithDynamicProxyAnnotation {

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ComponentFactoryAnnotation.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ComponentFactoryAnnotation.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ComponentFactoryAnnotation.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ComponentFactoryAnnotation.java Mon Nov  3 09:45:15 2014
@@ -22,6 +22,8 @@ import java.util.Dictionary;
 import java.util.HashMap;
 import java.util.Map;
 
+import junit.framework.Assert;
+
 import org.apache.felix.dm.annotation.api.Component;
 import org.apache.felix.dm.annotation.api.Init;
 import org.apache.felix.dm.annotation.api.Property;
@@ -30,8 +32,6 @@ import org.apache.felix.dm.annotation.ap
 import org.apache.felix.dm.annotation.api.Stop;
 import org.apache.felix.dm.itest.Ensure;
 
-import junit.framework.Assert;
-
 @SuppressWarnings({"unchecked", "rawtypes"})
 public class ComponentFactoryAnnotation {
     public final static String FACTORY = "ComponentFactoryAnnotation.Factory";

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ComponentFactoryServiceTestWthPublisher.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ComponentFactoryServiceTestWthPublisher.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ComponentFactoryServiceTestWthPublisher.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ComponentFactoryServiceTestWthPublisher.java Mon Nov  3 09:45:15 2014
@@ -18,11 +18,9 @@
  */
 package org.apache.felix.dm.runtime.itest.components;
 
-import java.util.Dictionary;
 import java.util.HashMap;
 import java.util.Hashtable;
 import java.util.Map;
-import java.util.Set;
 
 import org.apache.felix.dm.annotation.api.Component;
 import org.apache.felix.dm.annotation.api.Init;
@@ -103,7 +101,7 @@ public class ComponentFactoryServiceTest
 
     @Component
     public static class ProviderImplFactory {
-        @ServiceDependency(filter = "(" + ComponentFactory.FACTORY_NAME + "=" + FACTORY + ")")
+        @ServiceDependency(filter = "(" + Component.FACTORY_NAME + "=" + FACTORY + ")")
         void bind(ComponentFactory providerImplFactory) {
             providerImplFactory.newInstance(new Hashtable() {
                 {

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ExtraComponentFactoryServiceProperties.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ExtraComponentFactoryServiceProperties.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ExtraComponentFactoryServiceProperties.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ExtraComponentFactoryServiceProperties.java Mon Nov  3 09:45:15 2014
@@ -51,7 +51,7 @@ public class ExtraComponentFactoryServic
 
     @Component
     public static class ProviderImplFactory {
-        @ServiceDependency(filter = "(" + ComponentFactory.FACTORY_NAME + "=" + FACTORYNAME + ")")
+        @ServiceDependency(filter = "(" + Component.FACTORY_NAME + "=" + FACTORYNAME + ")")
         volatile ComponentFactory m_factory;
 
         @Start

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ServiceFactoryAnnotation.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ServiceFactoryAnnotation.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ServiceFactoryAnnotation.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/components/ServiceFactoryAnnotation.java Mon Nov  3 09:45:15 2014
@@ -22,6 +22,8 @@ import java.util.Dictionary;
 import java.util.HashMap;
 import java.util.Map;
 
+import junit.framework.Assert;
+
 import org.apache.felix.dm.annotation.api.Component;
 import org.apache.felix.dm.annotation.api.Init;
 import org.apache.felix.dm.annotation.api.Property;
@@ -30,8 +32,6 @@ import org.apache.felix.dm.annotation.ap
 import org.apache.felix.dm.annotation.api.Stop;
 import org.apache.felix.dm.itest.Ensure;
 
-import junit.framework.Assert;
-
 @SuppressWarnings({"unchecked", "rawtypes"})
 public class ServiceFactoryAnnotation {
     public final static String FACTORY = "ServiceFactoryAnnotation.Factory";

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/tests/ComponentFactoryAnnotationTest.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/tests/ComponentFactoryAnnotationTest.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/tests/ComponentFactoryAnnotationTest.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime.itest/src/org/apache/felix/dm/runtime/itest/tests/ComponentFactoryAnnotationTest.java Mon Nov  3 09:45:15 2014
@@ -21,6 +21,7 @@ package org.apache.felix.dm.runtime.ites
 import java.util.Hashtable;
 
 import org.apache.felix.dm.DependencyManager;
+import org.apache.felix.dm.annotation.api.Component;
 import org.apache.felix.dm.itest.Ensure;
 import org.apache.felix.dm.itest.TestBase;
 import org.apache.felix.dm.runtime.api.ComponentFactory;
@@ -42,7 +43,7 @@ public class ComponentFactoryAnnotationT
                 .setImplementation(this)
                 .add(m.createServiceDependency()
                         .setService(ComponentFactory.class,
-                                "(" + ComponentFactory.FACTORY_NAME + "=" + ComponentFactoryAnnotation.FACTORY + ")")
+                                "(" + Component.FACTORY_NAME + "=" + ComponentFactoryAnnotation.FACTORY + ")")
                         .setRequired(true).setCallbacks("bindFactory", null)));
 
         // Check if the test.annotation components have been initialized orderly

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/ComponentBuilder.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/ComponentBuilder.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/ComponentBuilder.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/ComponentBuilder.java Mon Nov  3 09:45:15 2014
@@ -36,7 +36,8 @@ import org.osgi.framework.Bundle;
 public class ComponentBuilder extends AbstractBuilder
 {
     private final static String TYPE = "Component";
-    private final static String DM_FACTORY_NAME = "dm.factory.name";
+    public final static String FACTORY_NAME = "dm.factory.name";
+    public final static String FACTORY_INSTANCE = "dm.factory.instance";
 
     @Override
     public String getType()
@@ -102,7 +103,7 @@ public class ComponentBuilder extends Ab
             c.setImplementation(factorySet);
             c.setCallbacks(null, "start", "stop", null);
             Hashtable<String, String> props = new Hashtable<String, String>();
-            props.put(DM_FACTORY_NAME, factory);
+            props.put(ComponentBuilder.FACTORY_NAME, factory);
             c.setInterface(Set.class.getName(), props);
         } 
         else if (factoryName != null) {
@@ -117,7 +118,7 @@ public class ComponentBuilder extends Ab
             c.setImplementation(compFactory);
             c.setCallbacks(null, "start", "stop", null);
             Hashtable<String, String> props = new Hashtable<String, String>();
-            props.put(ComponentFactory.FACTORY_NAME, factoryName);
+            props.put(ComponentBuilder.FACTORY_NAME, factoryName);
             c.setInterface(ComponentFactory.class.getName(), props);
         }
 

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/ComponentInstanceImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/ComponentInstanceImpl.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/ComponentInstanceImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/ComponentInstanceImpl.java Mon Nov  3 09:45:15 2014
@@ -58,7 +58,7 @@ public class ComponentInstanceImpl imple
         m_component = m_dm.createComponent();
         
         Class<?> implClass = m_bundle.loadClass(m_srvMeta.getString(Params.impl));
-        Object impl = conf.get(ComponentFactory.FACTORY_INSTANCE);
+        Object impl = conf.get(ComponentBuilder.FACTORY_INSTANCE);
         if (impl == null) {
             String factoryMethod = m_srvMeta.getString(Params.factoryMethod, null);
             if (factoryMethod == null) {

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/FactorySet.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/FactorySet.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/FactorySet.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/FactorySet.java Mon Nov  3 09:45:15 2014
@@ -46,6 +46,15 @@ import org.osgi.framework.Bundle;
 public class FactorySet extends AbstractSet<Dictionary>
 {
     /**
+     * When a Dictionary is registered in a factory Set, we use this special 
+     * property key, whose value may provide the instance to use when
+     * creating a service.
+     */
+    private final static String DM_FACTORY_INSTANCE = "dm.factory.instance";
+    
+    public final static String DM_FACTORY_NAME = "dm.factory.name";
+
+    /**
      * The actual Service instance that is allocated for each dictionaries added in this Set.
      */
     private Object m_impl;
@@ -108,13 +117,6 @@ public class FactorySet extends Abstract
     private final static Object SERVICE_CREATING = new Object();
 
     /**
-     * When a Dictionary is registered in a factory Set, we use this special 
-     * property key, whose value may provide the instance to use when
-     * creating a service.
-     */
-    private final static String DM_FACTORY_INSTANCE = "dm.factory.instance";
-
-    /**
      * This class wraps <tt>Dictionary</tt>, allowing to store the dictionary into a Map, using
      * reference-equality in place of object-equality when getting the Dictionary from the Map.
      */

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/api/ComponentFactory.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/api/ComponentFactory.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/api/ComponentFactory.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.runtime/src/org/apache/felix/dm/runtime/api/ComponentFactory.java Mon Nov  3 09:45:15 2014
@@ -9,18 +9,6 @@ import java.util.Dictionary;
  */
 public interface ComponentFactory {
     /**
-     * A ComponentFactory is registered in the OSGI service registry with a FACTORY_NAME matching the "factoryName" attribute
-     * value used in the DM Component annotation.
-     */
-    public final static String FACTORY_NAME = "dm.runtime.factory.name";
-    
-    /**
-     * When instantiating a Component, you can specify the component instance in the dictionary passed to the {@link #newInstance(Dictionary)}
-     * method using this key.
-     */
-    public final static String FACTORY_INSTANCE = "dm.runtime.factory.instance";
-
-    /**
      * Instantiates a Component instance. Any properties starts with a "." are considered as private. Other properties will be
      * published as the component instance service properties (if the component provides a services).
      * @param conf the properties passed to the component "configure" method which is specified with the "configure" attribute

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/composite/ProviderImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/composite/ProviderImpl.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/composite/ProviderImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/composite/ProviderImpl.java Mon Nov  3 09:45:15 2014
@@ -19,7 +19,7 @@ public class ProviderImpl implements Pro
         // validate configuration and throw an exception if the properties are invalid
         m_conf = conf;
     }
-    
+
     Object[] getComposition() {
         return new Object[] { this, m_participant1, m_participant2 };
     }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/composite/ProviderParticipant2.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/composite/ProviderParticipant2.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/composite/ProviderParticipant2.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/composite/ProviderParticipant2.java Mon Nov  3 09:45:15 2014
@@ -4,7 +4,7 @@ import org.osgi.service.log.LogService;
 
 public class ProviderParticipant2 {
     private volatile LogService m_log; // Injected
-    
+
     void start() {
         m_log.log(LogService.LOG_INFO, "ProviderParticipant2.start()");
     }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/CompositionManager.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/CompositionManager.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/CompositionManager.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/CompositionManager.java Mon Nov  3 09:45:15 2014
@@ -12,12 +12,12 @@ public class CompositionManager {
     private ProviderParticipant2 m_participant2;
     private ProviderImpl m_providerImpl;
     private Dictionary<String, String> m_conf;
-    
+
     public void updated(Dictionary<String, String> conf) throws Exception {
         // validate configuration and throw an exception if the properties are invalid
         m_conf = conf;
     }
-    
+
     /**
      * Builds the composition of objects used to implement the "Provider" service.
      * The Configuration injected by Config Admin will be used to configure the components
@@ -30,7 +30,7 @@ public class CompositionManager {
         m_providerImpl = new ProviderImpl(m_participant1, m_participant2);
         return m_providerImpl; // Main object implementing the Provider service
     }
-    
+
     Object[] getComposition() {
         return new Object[] { m_providerImpl, m_participant1, m_participant2 };
     }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/ProviderImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/ProviderImpl.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/ProviderImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/ProviderImpl.java Mon Nov  3 09:45:15 2014
@@ -12,14 +12,14 @@ import org.osgi.service.log.LogService;
 public class ProviderImpl implements Provider {
     private final ProviderParticipant1 m_participant1;
     private final ProviderParticipant2 m_participant2;
-    
+
     private volatile LogService m_log; // Injected
 
     ProviderImpl(ProviderParticipant1 participant1, ProviderParticipant2 participant2) {
         m_participant1 = participant1;
         m_participant2 = participant2;
     }
-    
+
     void start() {
         m_log.log(LogService.LOG_INFO, "ProviderImpl.start(): participants=" + m_participant1 + "," + m_participant2);
     }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/ProviderParticipant2.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/ProviderParticipant2.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/ProviderParticipant2.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/compositefactory/ProviderParticipant2.java Mon Nov  3 09:45:15 2014
@@ -4,7 +4,7 @@ import org.osgi.service.log.LogService;
 
 public class ProviderParticipant2 {
     private volatile LogService m_log; // Injected
-    
+
     void start() {
         m_log.log(LogService.LOG_INFO, "ProviderParticipant2.start()");
     }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/customdep/PathTracker.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/customdep/PathTracker.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/customdep/PathTracker.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/customdep/PathTracker.java Mon Nov  3 09:45:15 2014
@@ -4,7 +4,7 @@ import org.osgi.service.log.LogService;
 
 public class PathTracker {
     volatile LogService logService;
-    
+
     void add(String path) {
         logService.log(LogService.LOG_INFO, "PathTracker.add: " + path);
     }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAccess.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAccess.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAccess.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAccess.java Mon Nov  3 09:45:15 2014
@@ -2,5 +2,6 @@ package org.apache.felix.dependencymanag
 
 public interface DeviceAccess {
     Device getDevice();
+
     DeviceParameter getDeviceParameter();
 }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAccessImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAccessImpl.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAccessImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAccessImpl.java Mon Nov  3 09:45:15 2014
@@ -10,11 +10,11 @@ import org.apache.felix.dm.annotation.ap
 import org.apache.felix.dm.annotation.api.Start;
 import org.osgi.service.log.LogService;
 
-@AdapterService(adapteeService=Device.class)
+@AdapterService(adapteeService = Device.class)
 public class DeviceAccessImpl implements DeviceAccess {
     volatile Device device;
-    
-    @ServiceDependency(name="deviceparam")
+
+    @ServiceDependency(name = "deviceparam")
     volatile DeviceParameter deviceParameter;
 
     @ServiceDependency
@@ -29,9 +29,9 @@ public class DeviceAccessImpl implements
         filters.put("deviceparam.required", "true");
         return filters;
     }
-    
+
     @Start
-    Map<?,?> start() {
+    Map<?, ?> start() {
         log.log(LogService.LOG_INFO, "DeviceAccessImpl.start");
         // Dynamically add a service property, using the device.id
         Map<String, Object> props = new Hashtable<>();
@@ -46,6 +46,6 @@ public class DeviceAccessImpl implements
 
     @Override
     public DeviceParameter getDeviceParameter() {
-        return deviceParameter;    
+        return deviceParameter;
     }
 }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAndParameterFactory.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAndParameterFactory.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAndParameterFactory.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceAndParameterFactory.java Mon Nov  3 09:45:15 2014
@@ -2,7 +2,6 @@ package org.apache.felix.dependencymanag
 
 import java.util.Dictionary;
 import java.util.Hashtable;
-import java.util.Set;
 
 import org.apache.felix.dm.annotation.api.Component;
 import org.apache.felix.dm.annotation.api.ServiceDependency;
@@ -16,10 +15,10 @@ import org.osgi.service.log.LogService;
  */
 @Component
 public class DeviceAndParameterFactory {
-    @ServiceDependency(filter = "(" + ComponentFactory.FACTORY_NAME + "=Device)")
+    @ServiceDependency(filter = "(" + Component.FACTORY_NAME + "=Device)")
     volatile ComponentFactory m_deviceFactory;
-    
-    @ServiceDependency(filter = "(" + ComponentFactory.FACTORY_NAME + "=DeviceParameter)")
+
+    @ServiceDependency(filter = "(" + Component.FACTORY_NAME + "=DeviceParameter)")
     volatile ComponentFactory m_deviceParameterFactory;
 
     @ServiceDependency
@@ -28,18 +27,18 @@ public class DeviceAndParameterFactory {
     @Start
     public void start() {
         log.log(LogService.LOG_INFO, "DeviceAndParameterFactory.start");
-        for (int i = 0; i < 2; i ++) {
+        for (int i = 0; i < 2; i++) {
             createDeviceAndParameter(i);
         }
     }
-    
+
     private void createDeviceAndParameter(int id) {
         log.log(LogService.LOG_INFO, "DeviceAndParameterFactory: creating Device/DeviceParameter with id=" + id);
 
-        Dictionary<String,Object> device = new Hashtable<>();
+        Dictionary<String, Object> device = new Hashtable<>();
         device.put("device.id", new Integer(id));
         m_deviceFactory.newInstance(device);
-        
+
         Dictionary<String, Object> param = new Hashtable<>();
         param.put("device.id", new Integer(id));
         m_deviceParameterFactory.newInstance(param);

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceParameterImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceParameterImpl.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceParameterImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/annot/DeviceParameterImpl.java Mon Nov  3 09:45:15 2014
@@ -4,10 +4,10 @@ import java.util.Dictionary;
 
 import org.apache.felix.dm.annotation.api.Component;
 
-@Component(factoryName="DeviceParameter", factoryConfigure="configure")
+@Component(factoryName = "DeviceParameter", factoryConfigure = "configure")
 public class DeviceParameterImpl implements DeviceParameter {
     int id;
-        
+
     void configure(Dictionary<String, Object> configuration) {
         this.id = (Integer) configuration.get("device.id");
     }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceAccess.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceAccess.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceAccess.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceAccess.java Mon Nov  3 09:45:15 2014
@@ -2,5 +2,6 @@ package org.apache.felix.dependencymanag
 
 public interface DeviceAccess {
     Device getDevice();
+
     DeviceParameter getDeviceParameter();
 }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceAccessImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceAccessImpl.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceAccessImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceAccessImpl.java Mon Nov  3 09:45:15 2014
@@ -12,17 +12,16 @@ public class DeviceAccessImpl implements
     void init(Component c) {
         // Dynamically add an extra dependency on a DeviceParameter.
         DependencyManager dm = c.getDependencyManager();
-        c.add(dm.createServiceDependency()
-            .setService(DeviceParameter.class, "(device.id=" + device.getDeviceId() + ")")
-            .setRequired(true));
+        c.add(dm.createServiceDependency().setService(DeviceParameter.class, "(device.id=" + device.getDeviceId() + ")").setRequired(
+            true));
     }
-    
+
     void start(Component c) {
         // Our service is starting: before being registered in the OSGi service registry,
         // add here a service property, using the device.id.
         Hashtable<String, Object> props = new Hashtable<>();
         props.put("device.access.id", device.getDeviceId());
-        c.setServiceProperties(props);  
+        c.setServiceProperties(props);
     }
 
     @Override
@@ -32,6 +31,6 @@ public class DeviceAccessImpl implements
 
     @Override
     public DeviceParameter getDeviceParameter() {
-        return deviceParameter;    
+        return deviceParameter;
     }
 }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceImpl.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceImpl.java Mon Nov  3 09:45:15 2014
@@ -1,13 +1,12 @@
 package org.apache.felix.dependencymanager.samples.device.api;
 
-
 public class DeviceImpl implements Device {
     final int id;
-    
+
     public DeviceImpl(int id) {
         this.id = id;
     }
-    
+
     @Override
     public int getDeviceId() {
         return id;

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceParameterImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceParameterImpl.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceParameterImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/device/api/DeviceParameterImpl.java Mon Nov  3 09:45:15 2014
@@ -1,9 +1,8 @@
 package org.apache.felix.dependencymanager.samples.device.api;
 
-
 public class DeviceParameterImpl implements DeviceParameter {
     final int id;
-    
+
     public DeviceParameterImpl(int id) {
         this.id = id;
     }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/dictionary/annot/SpellChecker.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/dictionary/annot/SpellChecker.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/dictionary/annot/SpellChecker.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/dictionary/annot/SpellChecker.java Mon Nov  3 09:45:15 2014
@@ -50,7 +50,7 @@ public class SpellChecker {
     /**
      * We'll store all Dictionaries in a concurrent list, in order to avoid method synchronization.
      */
-    @ServiceDependency(service=DictionaryService.class)
+    @ServiceDependency(service = DictionaryService.class)
     private final Iterable<DictionaryService> m_dictionaries = new ConcurrentLinkedQueue<>();
 
     /**

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceConsumer.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceConsumer.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceConsumer.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceConsumer.java Mon Nov  3 09:45:15 2014
@@ -16,21 +16,21 @@ import org.osgi.service.log.LogService;
 @Component
 public class ServiceConsumer {
     @ServiceDependency
-	volatile ServiceProvider service;
-    
+    volatile ServiceProvider service;
+
     @ServiceDependency
     volatile LogService log;
-    
+
     Dictionary<?, ?> conf;
-    
+
     @ConfigurationDependency
     protected void update(Dictionary<?, ?> conf) {
         this.conf = conf;
     }
-    
+
     @Start
-	public void start() {
+    public void start() {
         log.log(LogService.LOG_INFO, "ServiceConsumer.start: calling service.hello() ...");
-		this.service.hello();
-	}
+        this.service.hello();
+    }
 }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceProvider.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceProvider.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceProvider.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceProvider.java Mon Nov  3 09:45:15 2014
@@ -6,5 +6,5 @@ package org.apache.felix.dependencymanag
  * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
  */
 public interface ServiceProvider {
-	public void hello();
+    public void hello();
 }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceProviderImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceProviderImpl.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceProviderImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/annot/ServiceProviderImpl.java Mon Nov  3 09:45:15 2014
@@ -4,7 +4,6 @@ import org.apache.felix.dm.annotation.ap
 import org.apache.felix.dm.annotation.api.ServiceDependency;
 import org.osgi.service.log.LogService;
 
-
 /**
  * The implementation for our service provider.
  * 
@@ -14,9 +13,9 @@ import org.osgi.service.log.LogService;
 public class ServiceProviderImpl implements ServiceProvider {
     @ServiceDependency
     volatile LogService log;
-    
-	@Override
-	public void hello() {
+
+    @Override
+    public void hello() {
         log.log(LogService.LOG_INFO, "ServiceProviderImpl.hello");
-	}
+    }
 }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceConsumer.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceConsumer.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceConsumer.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceConsumer.java Mon Nov  3 09:45:15 2014
@@ -10,16 +10,16 @@ import org.osgi.service.log.LogService;
  * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
  */
 public class ServiceConsumer {
-	volatile ServiceProvider service;
-	volatile LogService log;
-	Dictionary<?, ?> conf;
-	
+    volatile ServiceProvider service;
+    volatile LogService log;
+    Dictionary<?, ?> conf;
+
     protected void update(Dictionary<?, ?> conf) {
         this.conf = conf;
     }
-    
-	public void start() {
+
+    public void start() {
         log.log(LogService.LOG_INFO, "ServiceConsumer.start: calling service.hello()");
-		this.service.hello();
-	}
+        this.service.hello();
+    }
 }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceProvider.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceProvider.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceProvider.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceProvider.java Mon Nov  3 09:45:15 2014
@@ -6,5 +6,5 @@ package org.apache.felix.dependencymanag
  * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
  */
 public interface ServiceProvider {
-	public void hello();
+    public void hello();
 }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceProviderImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceProviderImpl.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceProviderImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/hello/api/ServiceProviderImpl.java Mon Nov  3 09:45:15 2014
@@ -2,7 +2,6 @@ package org.apache.felix.dependencymanag
 
 import org.osgi.service.log.LogService;
 
-
 /**
  * The implementation for our service provider.
  * 
@@ -10,9 +9,9 @@ import org.osgi.service.log.LogService;
  */
 public class ServiceProviderImpl implements ServiceProvider {
     volatile LogService log;
-    
-	@Override
-	public void hello() {
+
+    @Override
+    public void hello() {
         log.log(LogService.LOG_INFO, "ServiceProviderImpl.hello");
-	}
+    }
 }

Modified: felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/tpool/ComponentExecutorFactoryImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/tpool/ComponentExecutorFactoryImpl.java?rev=1636297&r1=1636296&r2=1636297&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/tpool/ComponentExecutorFactoryImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/org.apache.felix.dependencymanager.samples/src/org/apache/felix/dependencymanager/samples/tpool/ComponentExecutorFactoryImpl.java Mon Nov  3 09:45:15 2014
@@ -9,9 +9,9 @@ import org.apache.felix.dm.ComponentExec
 public class ComponentExecutorFactoryImpl implements ComponentExecutorFactory {
     final static int SIZE = Runtime.getRuntime().availableProcessors();
     final static Executor m_threadPool = Executors.newFixedThreadPool(SIZE);
-    
+
     @Override
     public Executor getExecutorFor(Component component) {
         return m_threadPool;
-    } 
+    }
 }



Mime
View raw message