felix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clem...@apache.org
Subject svn commit: r939354 [1/2] - in /felix/trunk/ipojo: core/src/main/java/org/apache/felix/ipojo/handlers/dependency/ core/src/main/java/org/apache/felix/ipojo/util/ junit4osgi/maven-junit4osgi-plugin/ tests/api/ tests/api/src/test/java/org/apache/felix/ip...
Date Thu, 29 Apr 2010 15:53:59 GMT
Author: clement
Date: Thu Apr 29 15:53:58 2010
New Revision: 939354

URL: http://svn.apache.org/viewvc?rev=939354&view=rev
Log:
Fix FELIX-2308
Fix FELIX-2309
Update versions

Added:
    felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/component/FooProviderWithAnonymousClass.java
    felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/ps/PropertiesInAnonymousClassTest.java
Modified:
    felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/handlers/dependency/Dependency.java
    felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/DependencyModel.java
    felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/Tracker.java
    felix/trunk/ipojo/junit4osgi/maven-junit4osgi-plugin/pom.xml
    felix/trunk/ipojo/tests/api/pom.xml
    felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/CompositeTest.java
    felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/ExternalHandlerTest.java
    felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/PrimitiveComponentTest.java
    felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/SingletonComponentTest.java
    felix/trunk/ipojo/tests/bundleAsiPOJO/bundleAsiPOJO/pom.xml
    felix/trunk/ipojo/tests/bundleAsiPOJO/helpers/pom.xml
    felix/trunk/ipojo/tests/bundleAsiPOJO/tests/pom.xml
    felix/trunk/ipojo/tests/composite/composite-runtime/pom.xml
    felix/trunk/ipojo/tests/composite/import-export/pom.xml
    felix/trunk/ipojo/tests/composite/service-instance/pom.xml
    felix/trunk/ipojo/tests/composite/service-providing/pom.xml
    felix/trunk/ipojo/tests/core/annotations/pom.xml
    felix/trunk/ipojo/tests/core/bad-configurations/pom.xml
    felix/trunk/ipojo/tests/core/configadmin/pom.xml
    felix/trunk/ipojo/tests/core/configuration/pom.xml
    felix/trunk/ipojo/tests/core/external-handlers/pom.xml
    felix/trunk/ipojo/tests/core/factories/pom.xml
    felix/trunk/ipojo/tests/core/factory-version/pom.xml
    felix/trunk/ipojo/tests/core/handler/pom.xml
    felix/trunk/ipojo/tests/core/lifecycle-callback/pom.xml
    felix/trunk/ipojo/tests/core/lifecycle-controller/pom.xml
    felix/trunk/ipojo/tests/core/logger/pom.xml
    felix/trunk/ipojo/tests/core/service-dependency-bindingpolicy/pom.xml
    felix/trunk/ipojo/tests/core/service-dependency-comparator/pom.xml
    felix/trunk/ipojo/tests/core/service-dependency-filter/pom.xml
    felix/trunk/ipojo/tests/core/service-dependency-optional/pom.xml
    felix/trunk/ipojo/tests/core/service-dependency/pom.xml
    felix/trunk/ipojo/tests/core/service-providing-inheritance/pom.xml
    felix/trunk/ipojo/tests/core/service-providing-strategies/pom.xml
    felix/trunk/ipojo/tests/core/service-providing/pom.xml
    felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/ps/ProvidedServiceTestSuite.java
    felix/trunk/ipojo/tests/core/service-providing/src/main/resources/metadata.xml
    felix/trunk/ipojo/tests/handler/eventadmin/pom.xml
    felix/trunk/ipojo/tests/handler/temporal/pom.xml
    felix/trunk/ipojo/tests/handler/transaction/pom.xml
    felix/trunk/ipojo/tests/handler/whiteboard/pom.xml
    felix/trunk/ipojo/tests/integration-tests/pom.xml
    felix/trunk/ipojo/tests/manipulator/creation/pom.xml
    felix/trunk/ipojo/tests/manipulator/manipulation/pom.xml
    felix/trunk/ipojo/tests/manipulator/manipulator-java5/pom.xml
    felix/trunk/ipojo/tests/manipulator/metadata/pom.xml
    felix/trunk/ipojo/tests/manipulator/primitives/pom.xml
    felix/trunk/ipojo/tests/online-manipulator/pom.xml

Modified: felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/handlers/dependency/Dependency.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/handlers/dependency/Dependency.java?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/handlers/dependency/Dependency.java (original)
+++ felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/handlers/dependency/Dependency.java Thu Apr 29 15:53:58 2010
@@ -1,4 +1,4 @@
-/* 
+/*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
  * distributed with this work for additional information
@@ -231,7 +231,7 @@ public class Dependency extends Dependen
      * @param pojo : pojo instance on which calling the bind method.
      */
     protected void onObjectCreation(Object pojo) {
-                
+
         ServiceReference[] refs;
         synchronized (this) {
             if (!m_isStarted) { return; }
@@ -333,6 +333,31 @@ public class Dependency extends Dependen
         }
     }
 
+    private Object createNullableObject() {
+    	 // To load the proxy we use the POJO class loader. Indeed, this classloader imports iPOJO (so can access to Nullable) and has
+        // access to the service specification.
+    	try {
+            ClassLoader cl = new NullableClassLoader(
+                    getHandler().getInstanceManager().getClazz().getClassLoader(),
+                    getSpecification().getClassLoader());
+
+            m_nullable =
+                Proxy.newProxyInstance(cl, new Class[] {
+                        getSpecification(), Nullable.class }, new NullableObject()); // NOPMD
+
+        } catch (NoClassDefFoundError e) {
+            // A NoClassDefFoundError is thrown if the specification uses a class not accessible by the actual instance.
+            // It generally comes from a missing import.
+            throw new IllegalStateException("Cannot create the Nullable object, a referenced class cannot be loaded: " + e.getMessage());
+        } catch (Throwable e) { // Catch any other exception that can occurs
+            throw new IllegalStateException(
+                    "Cannot create the Nullable object, an unexpected error occurs: "
+                            + e.getMessage());
+        }
+
+        return m_nullable;
+    }
+
     /**
      * Start the dependency.
      */
@@ -342,26 +367,7 @@ public class Dependency extends Dependen
             if (m_di == null) {
                 // If nullable are supported, create the nullable object.
                 if (m_supportNullable) {
-                    // To load the proxy we use the POJO class loader. Indeed, this classloader imports iPOJO (so can access to Nullable) and has
-                    // access to the service specification.
-                    try {
-                        ClassLoader cl = new NullableClassLoader(
-                                getHandler().getInstanceManager().getClazz().getClassLoader(), 
-                                getSpecification().getClassLoader());
-                        
-                        m_nullable =
-                            Proxy.newProxyInstance(cl, new Class[] {
-                                    getSpecification(), Nullable.class }, new NullableObject()); // NOPMD
-                        
-                    } catch (NoClassDefFoundError e) {
-                        // A NoClassDefFoundError is thrown if the specification uses a class not accessible by the actual instance.
-                        // It generally comes from a missing import.
-                        throw new IllegalStateException("Cannot create the Nullable object, a referenced class cannot be loaded: " + e.getMessage());
-                    } catch (Throwable e) { // Catch any other exception that can occurs
-                        throw new IllegalStateException(
-                                "Cannot create the Nullable object, an unexpected error occurs: "
-                                        + e.getMessage());
-                    }
+                	createNullableObject();
                 }
             } else {
                 // Create the default-implementation object.
@@ -617,6 +623,7 @@ public class Dependency extends Dependen
             if (refs == null) {
                 if (m_nullable == null && m_supportNullable) {
                     m_handler.warn("[" + m_handler.getInstanceManager().getInstanceName() + "] The dependency is not optional, however no service object can be injected in " + m_field + " -> " + getSpecification().getName());
+                    createNullableObject();
                 }
                 usage.m_object = m_nullable; // Add null if the Nullable pattern is disable.
             } else {
@@ -783,21 +790,21 @@ public class Dependency extends Dependen
         setAggregate(true);
         m_type = type;
     }
-    
+
     /**
      * Classloader for nullable objects.
      */
     private class NullableClassLoader extends ClassLoader {
        /**
-        * Component classloader. 
+        * Component classloader.
         */
         private ClassLoader m_component;
-       
+
        /**
-        * Specification classloader. 
+        * Specification classloader.
         */
         private ClassLoader m_specification;
-       
+
         /**
          * Creates a NullableClassLoader.
          * @param cmp the component class loader.
@@ -807,7 +814,7 @@ public class Dependency extends Dependen
             m_component = cmp;
             m_specification = spec;
         }
-        
+
         /**
          * Loads the given class.
          * This method uses the classloader of the component class
@@ -824,8 +831,8 @@ public class Dependency extends Dependen
                 return m_specification.loadClass(name);
             }
         }
-        
-       
+
+
     }
 
     /**
@@ -904,17 +911,17 @@ public class Dependency extends Dependen
          * HashCode method.
          */
         private Method m_hashCodeMethod;
-        
+
         /**
          * Equals method.
          */
         private Method m_equalsMethod;
-        
+
         /**
-         * toStirng method. 
+         * toStirng method.
          */
         private Method m_toStringMethod;
-        
+
         /**
          * Creates a DynamicProxyFactory.
          */
@@ -928,7 +935,7 @@ public class Dependency extends Dependen
                 throw new NoSuchMethodError(e.getMessage());
             }
         }
-        
+
         /**
          * Creates a proxy object for the given specification. The proxy
          * uses the given dependency to get the service object.
@@ -967,7 +974,7 @@ public class Dependency extends Dependen
                             "Unexpected Object method dispatched: " + method);
                 }
             }
-            
+
             return method.invoke(svc, args);
         }
 

Modified: felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/DependencyModel.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/DependencyModel.java?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/DependencyModel.java (original)
+++ felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/DependencyModel.java Thu Apr 29 15:53:58 2010
@@ -1,4 +1,4 @@
-/* 
+/*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
  * distributed with this work for additional information
@@ -38,7 +38,7 @@ import org.osgi.framework.ServiceReferen
 
 /**
  * Abstract dependency model.
- * This class is the parent class of every service dependency. It manages the most 
+ * This class is the parent class of every service dependency. It manages the most
  * part of dependency management. This class creates an interface between the service
  * tracker and the concrete dependency.
  * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
@@ -60,29 +60,29 @@ public abstract class DependencyModel im
     public static final int UNRESOLVED = 0;
 
     /**
-     * Dependency state : RESOLVED. 
+     * Dependency state : RESOLVED.
      * A dependency is resolved if the dependency is optional or at least one
      * provider is available.
      */
     public static final int RESOLVED = 1;
 
     /**
-     * Binding policy : Dynamic. 
+     * Binding policy : Dynamic.
      * In this policy, services can appears and departs without special treatment.
      */
     public static final int DYNAMIC_BINDING_POLICY = 0;
 
     /**
-     * Binding policy : Static. 
+     * Binding policy : Static.
      * Once a service is used, if this service disappears the dependency becomes
      * {@link DependencyModel#BROKEN}. The instance needs to be recreated.
      */
     public static final int STATIC_BINDING_POLICY = 1;
 
     /**
-     * Binding policy : Dynamic-Priority. 
+     * Binding policy : Dynamic-Priority.
      * In this policy, services can appears and departs. However, once a service
-     * with a highest ranking (according to the used comparator) appears, this 
+     * with a highest ranking (according to the used comparator) appears, this
      * new service is re-injected.
      */
     public static final int DYNAMIC_PRIORITY_BINDING_POLICY = 2;
@@ -109,7 +109,7 @@ public abstract class DependencyModel im
     private Comparator m_comparator;
 
     /**
-     * The LDAP filter object selecting service references 
+     * The LDAP filter object selecting service references
      * from the set of providers providing the required specification.
      */
     private Filter m_filter;
@@ -121,7 +121,7 @@ public abstract class DependencyModel im
     private BundleContext m_context;
 
     /**
-     * Listener object on which invoking the {@link DependencyStateListener#validate(DependencyModel)} 
+     * Listener object on which invoking the {@link DependencyStateListener#validate(DependencyModel)}
      * and {@link DependencyStateListener#invalidate(DependencyModel)} methods.
      */
     private final DependencyStateListener m_listener;
@@ -143,12 +143,12 @@ public abstract class DependencyModel im
     private Tracker m_tracker;
 
     /**
-     * The list of matching service references. This list is a 
-     * subset of tracked references. This set is computed according 
+     * The list of matching service references. This list is a
+     * subset of tracked references. This set is computed according
      * to the filter and the {@link DependencyModel#match(ServiceReference)} method.
      */
     private final List m_matchingRefs = new ArrayList();
-    
+
     /**
      * The instance requiring the service.
      */
@@ -165,7 +165,7 @@ public abstract class DependencyModel im
      * Creates a DependencyModel.
      * If the dependency has no comparator and follows the
      * {@link DependencyModel#DYNAMIC_PRIORITY_BINDING_POLICY} policy
-     * the OSGi Service Reference Comparator is used. 
+     * the OSGi Service Reference Comparator is used.
      * @param specification the required specification
      * @param aggregate is the dependency aggregate ?
      * @param optional is the dependency optional ?
@@ -221,7 +221,7 @@ public abstract class DependencyModel im
         ungetAllServices();
         m_state = UNRESOLVED;
     }
-    
+
     /**
      * Ungets all 'get' service references.
      * This also clears the service object map.
@@ -244,19 +244,19 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Is the reference set frozen (cannot change anymore)? 
+     * Is the reference set frozen (cannot change anymore)?
      * This method must be override by concrete dependency to support
      * the static binding policy. In fact, this method allows optimizing
      * the static dependencies to become frozen only when needed.
-     * This method returns <code>false</code> by default. 
+     * This method returns <code>false</code> by default.
      * The method must always return <code>false</code> for non-static dependencies.
      * @return <code>true</code> if the reference set is frozen.
      */
     public boolean isFrozen() {
         return false;
     }
-    
-    
+
+
     /**
      * Unfreezes the dependency.
      * This method must be overide by concrete dependency to support
@@ -269,7 +269,7 @@ public abstract class DependencyModel im
     /**
      * Does the service reference match ? This method must be override by
      * concrete dependencies if they need advanced testing on service reference
-     * (that cannot be expressed in the LDAP filter). By default this method 
+     * (that cannot be expressed in the LDAP filter). By default this method
      * returns <code>true</code>.
      * @param ref the tested reference.
      * @return <code>true</code> if the service reference matches.
@@ -313,7 +313,7 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Service tracker adding service callback. 
+     * Service tracker adding service callback.
      * It accepts the service only if the dependency isn't broken or frozen.
      * @param ref the arriving service reference.
      * @return <code>true</code> if the reference must be tracked.
@@ -324,7 +324,7 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Service Tracker added service callback. 
+     * Service Tracker added service callback.
      * If the service matches (against the filter and the {@link DependencyModel#match(ServiceReference)},
      * manages the provider arrival.
      * @param ref : new references.
@@ -336,10 +336,10 @@ public abstract class DependencyModel im
         }
         // Do not store the service if it doesn't match.
     }
-    
+
     /**
      * Checks if the given service reference match the current filter.
-     * This method aims to avoid calling {@link Filter#match(ServiceReference)} 
+     * This method aims to avoid calling {@link Filter#match(ServiceReference)}
      * method when manipulating a composite reference. In fact, this method thrown
      * a {@link ClassCastException} on Equinox.
      * @param ref the service reference to check.
@@ -359,7 +359,7 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Manages the arrival of a new service reference. 
+     * Manages the arrival of a new service reference.
      * The reference is valid and matches the filter and the {@link DependencyModel#match(ServiceReference)}
      * method. This method has different behavior according to the binding policy.
      * @param ref the new reference
@@ -412,8 +412,8 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Service tracker removed service callback. 
-     * A service provider goes away. The depart needs to be managed only if the 
+     * Service tracker removed service callback.
+     * A service provider goes away. The depart needs to be managed only if the
      * reference was used.
      * @param ref the leaving service reference
      * @param arg1 the service object if the service was already get
@@ -433,7 +433,7 @@ public abstract class DependencyModel im
     private void manageDeparture(ServiceReference ref, Object obj) {
         // Unget the service reference
         ungetService(ref);
-        
+
         // If we already get this service and the binding policy is static, the dependency becomes broken
         if (isFrozen() && obj != null) {
             if (m_state != BROKEN) {
@@ -478,10 +478,10 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Service tracker modified service callback. 
-     * This method must handle if the modified service should be considered as 
+     * Service tracker modified service callback.
+     * This method must handle if the modified service should be considered as
      * a depart or an arrival.
-     * According to the dependency filter, a service can now match or can no match 
+     * According to the dependency filter, a service can now match or can no match
      * anymore.
      * @param ref the modified reference
      * @param arg1 the service object if already get.
@@ -507,7 +507,7 @@ public abstract class DependencyModel im
 
     /**
      * Gets the next matching service reference.
-     * @return <code>null</code> if no more provider is available, 
+     * @return <code>null</code> if no more provider is available,
      * else returns the first reference from the matching set.
      */
     public ServiceReference getServiceReference() {
@@ -522,7 +522,7 @@ public abstract class DependencyModel im
 
     /**
      * Gets matching service references.
-     * @return the sorted (if a comparator is used) array of matching service 
+     * @return the sorted (if a comparator is used) array of matching service
      * references, <code>null</code> if no references are available.
      */
     public ServiceReference[] getServiceReferences() {
@@ -572,22 +572,22 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Concrete dependency callback. 
-     * This method is called when a new service needs to be 
+     * Concrete dependency callback.
+     * This method is called when a new service needs to be
      * re-injected in the underlying concrete dependency.
      * @param ref the service reference to inject.
      */
     public abstract void onServiceArrival(ServiceReference ref);
 
     /**
-     * Concrete dependency callback. 
+     * Concrete dependency callback.
      * This method is called when a used service (already injected) is leaving.
      * @param ref the leaving service reference.
      */
     public abstract void onServiceDeparture(ServiceReference ref);
-    
+
     /**
-     * Concrete dependency callback. 
+     * Concrete dependency callback.
      * This method is called when a used service (already injected) is modified.
      * @param ref the modified service reference.
      */
@@ -609,7 +609,7 @@ public abstract class DependencyModel im
                 onServiceDeparture((ServiceReference) m_matchingRefs.get(1));
                 onServiceArrival(ref);
             }
-            
+
         } else {
             // It's a modification...
             onServiceModification(ref);
@@ -617,7 +617,7 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Concrete dependency callback. 
+     * Concrete dependency callback.
      * This method is called when the dependency is reconfigured and when this
      * reconfiguration implies changes on the matching service set ( and by the
      * way on the injected service).
@@ -627,7 +627,7 @@ public abstract class DependencyModel im
     public abstract void onDependencyReconfiguration(ServiceReference[] departs, ServiceReference[] arrivals);
 
     /**
-     * Calls the listener callback to notify the new state of the current 
+     * Calls the listener callback to notify the new state of the current
      * dependency.
      */
     private void invalidate() {
@@ -635,7 +635,7 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Calls the listener callback to notify the new state of the current 
+     * Calls the listener callback to notify the new state of the current
      * dependency.
      */
     private void validate() {
@@ -659,7 +659,7 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Sets the required specification of this service dependency. 
+     * Sets the required specification of this service dependency.
      * This operation is not supported if the dependency tracking has already begun.
      * @param specification the required specification.
      */
@@ -791,7 +791,7 @@ public abstract class DependencyModel im
 
     /**
      * Returns the dependency filter (String form).
-     * @return the String form of the LDAP filter used by this dependency, 
+     * @return the String form of the LDAP filter used by this dependency,
      * <code>null</code> if not set.
      */
     public String getFilter() {
@@ -803,7 +803,7 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Sets the aggregate attribute of the current dependency. 
+     * Sets the aggregate attribute of the current dependency.
      * If the tracking is opened, it will call arrival and departure callbacks.
      * @param isAggregate the new aggregate attribute value.
      */
@@ -863,7 +863,7 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Sets the binding policy. 
+     * Sets the binding policy.
      * Not yet supported.
      */
     public void setBindingPolicy() {
@@ -875,7 +875,7 @@ public abstract class DependencyModel im
         m_comparator = cmp;
         // NOTE: the array will be sorted at the next get.
     }
-    
+
     /**
      * Gets the used comparator name.
      * <code>Null</code> if no comparator (i.e. the OSGi one is used).
@@ -911,31 +911,30 @@ public abstract class DependencyModel im
         Object svc =  m_tracker.getService(ref);
         if (svc instanceof IPOJOServiceFactory) {
             Object obj =  ((IPOJOServiceFactory) svc).getService(m_instance);
-            m_serviceObjects.put(ref, obj);
+            m_serviceObjects.put(ref, svc); // We store the factory !
             return obj;
         } else {
             m_serviceObjects.put(ref, svc);
             return svc;
         }
     }
-    
+
     /**
      * Ungets a used service reference.
      * @param ref the reference to unget.
      */
     public void ungetService(ServiceReference ref) {
-        Object svc = m_tracker.getService(ref); // Get the service object
         m_tracker.ungetService(ref);
         Object obj = m_serviceObjects.remove(ref);  // Remove the service object
-        if (svc instanceof IPOJOServiceFactory) {
-            ((IPOJOServiceFactory) svc).ungetService(m_instance, obj);
+        if (obj != null  && obj instanceof IPOJOServiceFactory) {
+            ((IPOJOServiceFactory) obj).ungetService(m_instance, obj);
         }
     }
 
     /**
      * Helper method parsing the comparator attribute and returning the
      * comparator object. If the 'comparator' attribute is not set, this method
-     * returns null. If the 'comparator' attribute is set to 'osgi', this method 
+     * returns null. If the 'comparator' attribute is set to 'osgi', this method
      * returns the normal OSGi comparator. In other case, it tries to create
      * an instance of the declared comparator class.
      * @param dep the Element describing the dependency
@@ -984,9 +983,9 @@ public abstract class DependencyModel im
     }
 
     /**
-     * Helper method parsing the binding policy. 
-     * If the 'policy' attribute is not set in the dependency, the method returns 
-     * the 'DYNAMIC BINDING POLICY'. Accepted policy values are : dynamic, 
+     * Helper method parsing the binding policy.
+     * If the 'policy' attribute is not set in the dependency, the method returns
+     * the 'DYNAMIC BINDING POLICY'. Accepted policy values are : dynamic,
      * dynamic-priority and static.
      * @param dep the Element describing the dependency
      * @return the policy attached to this dependency

Modified: felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/Tracker.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/Tracker.java?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/Tracker.java (original)
+++ felix/trunk/ipojo/core/src/main/java/org/apache/felix/ipojo/util/Tracker.java Thu Apr 29 15:53:58 2010
@@ -1,4 +1,4 @@
-/* 
+/*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
  * distributed with this work for additional information
@@ -64,31 +64,31 @@ public class Tracker implements TrackerC
     protected String m_listenerFilter;
 
     /**
-     * The class name to be tracked. If this field is set, then we are 
+     * The class name to be tracked. If this field is set, then we are
      * tracking by class name.
      */
     private String m_trackClass;
 
     /**
-     * The reference to be tracked. If this field is set, then we are 
+     * The reference to be tracked. If this field is set, then we are
      * tracking a single ServiceReference.
      */
     private ServiceReference m_trackReference;
 
     /**
-     * The tracked services: ServiceReference object -> customized. 
+     * The tracked services: ServiceReference object -> customized.
      *Object and ServiceListener object
      */
     private Tracked m_tracked;
 
     /**
-     * The cached ServiceReference for getServiceReference. 
+     * The cached ServiceReference for getServiceReference.
      * This field is volatile since it is accessed by multiple threads.
      */
     private volatile ServiceReference m_cachedReference;
 
     /**
-     * The cached service object for getService. This field is volatile 
+     * The cached service object for getService. This field is volatile
      * since it is accessed by multiple threads.
      */
     private volatile Object m_cachedService;
@@ -124,7 +124,7 @@ public class Tracker implements TrackerC
      * @param context the BundleContext object against which the tracking is done.
      * @param clazz the Class name of the services to be tracked.
      * @param customizer the customizer object to call when services are added, modified, or removed in this Tracker object. If customizer is null, then this Tracker object will be used as
-     *            the TrackerCustomizer object and the Tracker object will call the TrackerCustomizer methods on itself.    
+     *            the TrackerCustomizer object and the Tracker object will call the TrackerCustomizer methods on itself.
      */
     public Tracker(BundleContext context, String clazz, TrackerCustomizer customizer) {
         // Security Check
@@ -132,7 +132,7 @@ public class Tracker implements TrackerC
             throw new SecurityException("The bundle " + context.getBundle().getBundleId()
                     + " does not have the permission to get the service " + clazz);
         }
-        
+
         this.m_context = context;
         this.m_trackReference = null;
         this.m_trackClass = clazz;
@@ -158,7 +158,7 @@ public class Tracker implements TrackerC
      * @param context the BundleContext object against which the tracking is done.
      * @param filter the Filter object to select the services to be tracked.
      * @param customizer The customizer object to call when services are added, modified, or removed in this Tracker object. If customizer is null, then this Tracker object will be used as the
-     *            TrackerCustomizer object and the Tracker object will call the TrackerCustomizer methods on itself.   
+     *            TrackerCustomizer object and the Tracker object will call the TrackerCustomizer methods on itself.
      */
     public Tracker(BundleContext context, Filter filter, TrackerCustomizer customizer) {
         this.m_context = context;
@@ -263,7 +263,7 @@ public class Tracker implements TrackerC
     }
 
     /**
-     * Default implementation of the TrackerCustomizer.addedService method.  
+     * Default implementation of the TrackerCustomizer.addedService method.
      * @param reference the added reference.
      * @see org.apache.felix.ipojo.util.TrackerCustomizer#addedService(org.osgi.framework.ServiceReference)
      */
@@ -341,7 +341,7 @@ public class Tracker implements TrackerC
             Iterator keys = tracked.keySet().iterator();
             for (int i = 0; i < length; i++) {
                 references[i] = (ServiceReference) keys.next();
-            }            
+            }
             return references;
         }
     }
@@ -367,7 +367,7 @@ public class Tracker implements TrackerC
             return references;
         }
     }
-    
+
     /**
      * Returns the list of references used by the tracker.
      * A reference becomes used when the dependency has already
@@ -418,17 +418,17 @@ public class Tracker implements TrackerC
     /**
      * Returns the service object for the specified ServiceReference object if the referenced service is being tracked by this Tracker object.
      * @param reference the Reference to the desired service.
-     * @return the Service object or <code>null</code> if the service referenced by the specified ServiceReference object is not being tracked.
+     * @return the Service object. Try to get the service if not yet tracked.
      */
     public Object getService(ServiceReference reference) {
         // Security Check
-        if (! SecurityHelper.hasPermissionToGetServices((String[]) reference.getProperty(Constants.OBJECTCLASS), 
+        if (! SecurityHelper.hasPermissionToGetServices((String[]) reference.getProperty(Constants.OBJECTCLASS),
                 m_context)) {
             throw new SecurityException("The bundle " + m_context.getBundle().getBundleId() + " does not have"
-                    + " the permission to get the services " 
+                    + " the permission to get the services "
                     + Arrays.asList((String[]) reference.getProperty(Constants.OBJECTCLASS)));
         }
-        
+
         Tracked tracked = this.m_tracked; // use local var since we are not synchronized
         if (tracked == null) { /* if Tracker is not open */
             return null;
@@ -445,8 +445,8 @@ public class Tracker implements TrackerC
             } else { // The object was already get.
                 return object;
             }
-            // Not already tracked.
-            return m_context.getService(reference);
+
+            return  m_context.getService(reference);
         }
     }
 
@@ -687,7 +687,7 @@ public class Tracker implements TrackerC
         }
 
         /**
-         * Common logic to add a service to the tracker used by track and trackInitialServices. 
+         * Common logic to add a service to the tracker used by track and trackInitialServices.
          * The specified reference must have been placed in the adding list before calling this method.
          * @param reference the Reference to a service to be tracked.
          */
@@ -703,7 +703,7 @@ public class Tracker implements TrackerC
                     if (m_adding.remove(reference)) { // if the service was not untracked during the customizer callback
                         if (mustBeTracked) {
                             this.put(reference, null);
-                            modified(); 
+                            modified();
                             mustCallAdded = true;
                             notifyAll(); // notify any waiters in waitForService
                         }
@@ -742,7 +742,7 @@ public class Tracker implements TrackerC
                     return; // in case the service is untracked while in the process of adding
                 }
 
-                boolean isTraked = this.containsKey(reference); // Check if we was tracking the reference 
+                boolean isTraked = this.containsKey(reference); // Check if we was tracking the reference
                 object = this.remove(reference); // must remove from tracker before calling customizer callback
 
                 if (!isTraked) { return; }

Modified: felix/trunk/ipojo/junit4osgi/maven-junit4osgi-plugin/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/junit4osgi/maven-junit4osgi-plugin/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/junit4osgi/maven-junit4osgi-plugin/pom.xml (original)
+++ felix/trunk/ipojo/junit4osgi/maven-junit4osgi-plugin/pom.xml Thu Apr 29 15:53:58 2010
@@ -61,7 +61,7 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>1.5.0-SNAPSHOT</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>

Modified: felix/trunk/ipojo/tests/api/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/api/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/api/pom.xml (original)
+++ felix/trunk/ipojo/tests/api/pom.xml Thu Apr 29 15:53:58 2010
@@ -59,29 +59,29 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.api</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.composite</artifactId>
-      <version>${pom.version}</version>
+      <version>1.6.0</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.manipulator</artifactId>
-      <version>${pom.version}</version>
+      <version>1.6.0</version>
     </dependency>
 
-    <!-- For external handlermanagement -->
+    <!-- For external handler management -->
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.handler.whiteboard</artifactId>
-      <version>${pom.version}</version>
+      <version>1.4.0</version>
     </dependency>
 
   <!--

Modified: felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/CompositeTest.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/CompositeTest.java?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/CompositeTest.java (original)
+++ felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/CompositeTest.java Thu Apr 29 15:53:58 2010
@@ -65,7 +65,6 @@ public class CompositeTest {
         Option[] opt =  options(
                 felix(),
                 equinox(),
-                knopflerfish(),
                 provision(
                         mavenBundle().groupId("org.apache.felix").artifactId("org.apache.felix.ipojo").version(asInProject()),
                         mavenBundle().groupId("org.apache.felix").artifactId("org.apache.felix.ipojo.composite").version(asInProject()),

Modified: felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/ExternalHandlerTest.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/ExternalHandlerTest.java?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/ExternalHandlerTest.java (original)
+++ felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/ExternalHandlerTest.java Thu Apr 29 15:53:58 2010
@@ -54,7 +54,6 @@ public class ExternalHandlerTest {
         Option[] opt =  options(
                 felix(),
                 equinox(),
-                knopflerfish(),
                 provision(
                         mavenBundle().groupId("org.apache.felix").artifactId("org.apache.felix.ipojo").version(asInProject()),
                         mavenBundle().groupId("org.apache.felix").artifactId("org.apache.felix.ipojo.api").version(asInProject()),

Modified: felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/PrimitiveComponentTest.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/PrimitiveComponentTest.java?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/PrimitiveComponentTest.java (original)
+++ felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/PrimitiveComponentTest.java Thu Apr 29 15:53:58 2010
@@ -62,7 +62,6 @@ public class PrimitiveComponentTest {
         Option[] opt =  options(
                 felix(),
                 equinox(),
-                knopflerfish(),
                 provision(
                         mavenBundle().groupId("org.apache.felix").artifactId("org.apache.felix.ipojo").version(asInProject()),
                         mavenBundle().groupId("org.apache.felix").artifactId("org.apache.felix.ipojo.api").version(asInProject())

Modified: felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/SingletonComponentTest.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/SingletonComponentTest.java?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/SingletonComponentTest.java (original)
+++ felix/trunk/ipojo/tests/api/src/test/java/org/apache/felix/ipojo/tests/api/SingletonComponentTest.java Thu Apr 29 15:53:58 2010
@@ -64,7 +64,6 @@ public class SingletonComponentTest {
         Option[] opt =  options(
                 felix(),
                 equinox(),
-                knopflerfish(),
                 provision(
                         mavenBundle().groupId("org.apache.felix").artifactId("org.apache.felix.ipojo").version(asInProject()),
                         mavenBundle().groupId("org.apache.felix").artifactId("org.apache.felix.ipojo.api").version(asInProject())

Modified: felix/trunk/ipojo/tests/bundleAsiPOJO/bundleAsiPOJO/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/bundleAsiPOJO/bundleAsiPOJO/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/bundleAsiPOJO/bundleAsiPOJO/pom.xml (original)
+++ felix/trunk/ipojo/tests/bundleAsiPOJO/bundleAsiPOJO/pom.xml Thu Apr 29 15:53:58 2010
@@ -13,7 +13,7 @@
     <groupId>org.apache.felix</groupId>
     <version>1.2.1</version>
   </parent>
-  
+
   <dependencies>
     <dependency>
       <groupId>junit</groupId>
@@ -29,7 +29,7 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.manipulator</artifactId>
-      <version>1.4.0</version>
+      <version>1.6.0</version>
     </dependency>
     <dependency>
       <groupId>xerces</groupId>
@@ -51,7 +51,7 @@
     </plugins>
   </build>
 
-<repositories>	
+<repositories>
   <repository>
     <id>aQute</id>
     <url>http://www.aQute.biz/repo</url>

Modified: felix/trunk/ipojo/tests/bundleAsiPOJO/helpers/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/bundleAsiPOJO/helpers/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/bundleAsiPOJO/helpers/pom.xml (original)
+++ felix/trunk/ipojo/tests/bundleAsiPOJO/helpers/pom.xml Thu Apr 29 15:53:58 2010
@@ -7,18 +7,18 @@
   <version>1.5.0-SNAPSHOT</version>
   <name>iPOJO Test Helpers</name>
 
-  
+
 
   <dependencies>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>1.4.0</version>
+      <version>1.6.0</version>
     </dependency>
     <dependency>
       <groupId>org.osgi</groupId>
       <artifactId>org.osgi.core</artifactId>
-      <version>4.0.0</version>
+      <version>4.2.0</version>
     </dependency>
     <dependency>
       <groupId>junit</groupId>

Modified: felix/trunk/ipojo/tests/bundleAsiPOJO/tests/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/bundleAsiPOJO/tests/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/bundleAsiPOJO/tests/pom.xml (original)
+++ felix/trunk/ipojo/tests/bundleAsiPOJO/tests/pom.xml Thu Apr 29 15:53:58 2010
@@ -109,12 +109,12 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.annotations</artifactId>
-      <version>${pom.version}</version>
+      <version>1.6.0</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.6.0</version>
     </dependency>
 
   </dependencies>

Modified: felix/trunk/ipojo/tests/composite/composite-runtime/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/composite/composite-runtime/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/composite/composite-runtime/pom.xml (original)
+++ felix/trunk/ipojo/tests/composite/composite-runtime/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,17 +27,17 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.composite</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.metadata</artifactId>
-      <version>${pom.version}</version>
+      <version>1.4.0</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
@@ -82,7 +82,7 @@
       <plugin>
         <groupId>org.apache.felix</groupId>
         <artifactId>maven-ipojo-plugin</artifactId>
-        <version>${pom.version}</version>
+        <version>1.6.0</version>
         <executions>
           <execution>
             <goals>

Modified: felix/trunk/ipojo/tests/composite/import-export/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/composite/import-export/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/composite/import-export/pom.xml (original)
+++ felix/trunk/ipojo/tests/composite/import-export/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,17 +27,17 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.composite</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.metadata</artifactId>
-      <version>${pom.version}</version>
+      <version>1.4.0</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>

Modified: felix/trunk/ipojo/tests/composite/service-instance/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/composite/service-instance/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/composite/service-instance/pom.xml (original)
+++ felix/trunk/ipojo/tests/composite/service-instance/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,17 +27,17 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.composite</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -85,7 +85,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/composite/service-providing/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/composite/service-providing/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/composite/service-providing/pom.xml (original)
+++ felix/trunk/ipojo/tests/composite/service-providing/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,17 +27,17 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.composite</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -84,7 +84,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/core/annotations/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/annotations/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/annotations/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/annotations/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,13 +27,13 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.metadata
       </artifactId>
-      <version>${pom.version}</version>
+      <version>1.4.0</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
@@ -53,21 +53,21 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.annotations</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.handler.eventadmin</artifactId>
-      <version>${pom.version}</version>
+      <version>1.5.0-SNAPSHOT</version>
     </dependency>
-    
+
      <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.eventadmin</artifactId>
       <version>1.0.0</version>
       <scope>test</scope>
     </dependency>
-    
+
   </dependencies>
 
   <build>
@@ -105,7 +105,7 @@
       <plugin>
         <groupId>org.apache.felix</groupId>
         <artifactId>maven-ipojo-plugin</artifactId>
-        <version>${pom.version}</version>
+        <version>1.6.0</version>
         <executions>
           <execution>
             <goals>
@@ -114,8 +114,8 @@
           </execution>
         </executions>
       </plugin>
-      
-      
+
+
        <plugin>
         <groupId>org.apache.felix</groupId>
         <artifactId>maven-junit4osgi-plugin</artifactId>

Modified: felix/trunk/ipojo/tests/core/bad-configurations/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/bad-configurations/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/bad-configurations/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/bad-configurations/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -77,7 +77,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/core/configadmin/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/configadmin/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/configadmin/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/configadmin/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -69,14 +69,15 @@
 							org.apache.felix.ipojo.test*
 						</Private-Package>
 						<Test-Suite>
-							org.apache.felix.ipojo.test.scenarios.configadmin.ConfigurationTestSuite						</Test-Suite>
+							org.apache.felix.ipojo.test.scenarios.configadmin.ConfigurationTestSuite
+						</Test-Suite>
 					</instructions>
 				</configuration>
 			</plugin>
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/core/configuration/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/configuration/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/configuration/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/configuration/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.metadata</artifactId>
-      <version>${pom.version}</version>
+      <version>1.4.0</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
@@ -77,7 +77,7 @@
       <plugin>
         <groupId>org.apache.felix</groupId>
         <artifactId>maven-ipojo-plugin</artifactId>
-        <version>${pom.version}</version>
+        <version>1.6.0</version>
         <executions>
           <execution>
             <goals>

Modified: felix/trunk/ipojo/tests/core/external-handlers/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/external-handlers/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/external-handlers/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/external-handlers/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -77,7 +77,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/core/factories/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/factories/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/factories/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/factories/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -77,7 +77,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/core/factory-version/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/factory-version/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/factory-version/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/factory-version/pom.xml Thu Apr 29 15:53:58 2010
@@ -45,7 +45,7 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
 
   <!--
@@ -101,7 +101,7 @@
       <artifactId>org.apache.felix.ipojo.test.helpers</artifactId>
       <version>${pom.version}</version>
     </dependency>
-    
+
    <dependency>
     <groupId>org.ops4j.base</groupId>
     <artifactId>ops4j-base-io</artifactId>

Modified: felix/trunk/ipojo/tests/core/handler/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/handler/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/handler/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/handler/pom.xml Thu Apr 29 15:53:58 2010
@@ -35,7 +35,7 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
 
   <!-- Pax Exam API: -->
@@ -103,7 +103,7 @@
       <version>1.7</version>
       <scope>test</scope>
     </dependency>
-  
+
   <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.tinybundles.bundleAsiPOJO

Modified: felix/trunk/ipojo/tests/core/lifecycle-callback/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/lifecycle-callback/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/lifecycle-callback/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/lifecycle-callback/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -77,7 +77,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/core/lifecycle-controller/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/lifecycle-controller/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/lifecycle-controller/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/lifecycle-controller/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -77,7 +77,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/core/logger/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/logger/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/logger/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/logger/pom.xml Thu Apr 29 15:53:58 2010
@@ -58,7 +58,7 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>

Modified: felix/trunk/ipojo/tests/core/service-dependency-bindingpolicy/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-dependency-bindingpolicy/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/service-dependency-bindingpolicy/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/service-dependency-bindingpolicy/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -79,7 +79,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/core/service-dependency-comparator/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-dependency-comparator/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/service-dependency-comparator/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/service-dependency-comparator/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -80,7 +80,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/core/service-dependency-filter/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-dependency-filter/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/service-dependency-filter/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/service-dependency-filter/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.metadata</artifactId>
-      <version>${pom.version}</version>
+      <version>1.4.0</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
@@ -79,7 +79,7 @@
       <plugin>
         <groupId>org.apache.felix</groupId>
         <artifactId>maven-ipojo-plugin</artifactId>
-        <version>${pom.version}</version>
+        <version>1.6.0</version>
         <executions>
           <execution>
             <goals>
@@ -99,7 +99,7 @@
           <target>1.4</target>
         </configuration>
       </plugin>
-      
+
        <plugin>
         <groupId>org.apache.felix</groupId>
         <artifactId>maven-junit4osgi-plugin</artifactId>

Modified: felix/trunk/ipojo/tests/core/service-dependency-optional/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-dependency-optional/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/service-dependency-optional/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/service-dependency-optional/pom.xml Thu Apr 29 15:53:58 2010
@@ -36,12 +36,12 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.annotations</artifactId>
-      <version>${pom.version}</version>
+      <version>1.6.0</version>
     </dependency>
     <!--
       <dependency> <groupId>org.apache.felix</groupId>

Modified: felix/trunk/ipojo/tests/core/service-dependency/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-dependency/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/service-dependency/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/service-dependency/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.metadata</artifactId>
-      <version>${pom.version}</version>
+      <version>1.4.0</version>
     </dependency>
     <dependency>
         <groupId>org.osgi</groupId>
@@ -77,7 +77,7 @@
       <plugin>
         <groupId>org.apache.felix</groupId>
         <artifactId>maven-ipojo-plugin</artifactId>
-        <version>${pom.version}</version>
+        <version>1.6.0</version>
         <executions>
           <execution>
             <goals>
@@ -97,7 +97,7 @@
           <target>1.4</target>
         </configuration>
       </plugin>
-      
+
       <plugin>
         <groupId>org.apache.felix</groupId>
         <artifactId>maven-junit4osgi-plugin</artifactId>

Modified: felix/trunk/ipojo/tests/core/service-providing-inheritance/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-providing-inheritance/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/service-providing-inheritance/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/service-providing-inheritance/pom.xml Thu Apr 29 15:53:58 2010
@@ -53,7 +53,7 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.osgi</groupId>
@@ -140,11 +140,11 @@
       <version>1.5.0-SNAPSHOT</version>
       <scope>test</scope>
     </dependency>
-    
+
   <dependency>
     <groupId>org.apache.felix</groupId>
     <artifactId>org.apache.felix.ipojo.annotations</artifactId>
-    <version>1.5.0-SNAPSHOT</version>
+    <version>1.7.0-SNAPSHOT</version>
     <scope>compile</scope>
   </dependency>
   </dependencies>

Modified: felix/trunk/ipojo/tests/core/service-providing-strategies/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-providing-strategies/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/service-providing-strategies/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/service-providing-strategies/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -79,7 +79,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/core/service-providing/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-providing/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/service-providing/pom.xml (original)
+++ felix/trunk/ipojo/tests/core/service-providing/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo</artifactId>
-      <version>${pom.version}</version>
+      <version>1.7.0-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
       <artifactId>org.apache.felix.ipojo.metadata</artifactId>
-      <version>${pom.version}</version>
+      <version>1.4.0</version>
     </dependency>
     <dependency>
       <groupId>org.apache.felix</groupId>
@@ -77,7 +77,7 @@
       <plugin>
         <groupId>org.apache.felix</groupId>
         <artifactId>maven-ipojo-plugin</artifactId>
-        <version>${pom.version}</version>
+        <version>1.6.0</version>
         <executions>
           <execution>
             <goals>
@@ -97,7 +97,7 @@
           <target>1.4</target>
         </configuration>
       </plugin>
-      
+
        <plugin>
         <groupId>org.apache.felix</groupId>
         <artifactId>maven-junit4osgi-plugin</artifactId>

Added: felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/component/FooProviderWithAnonymousClass.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/component/FooProviderWithAnonymousClass.java?rev=939354&view=auto
==============================================================================
--- felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/component/FooProviderWithAnonymousClass.java (added)
+++ felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/component/FooProviderWithAnonymousClass.java Thu Apr 29 15:53:58 2010
@@ -0,0 +1,77 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.felix.ipojo.test.scenarios.component;
+
+import java.util.Properties;
+
+import org.apache.felix.ipojo.test.scenarios.ps.service.FooService;
+
+public class FooProviderWithAnonymousClass implements FooService {
+
+	private int intProp;
+	private String strProp;
+	private String[] strAProp;
+	private int[] intAProp;
+	private boolean boolProp;
+
+	public boolean foo() {
+		Runnable runnable = new Runnable() {
+			public void run() {
+				intProp = 3;
+				boolProp = true;
+				if(strProp.equals("foo")) { strProp = "bar"; }
+				else { strProp = "foo"; }
+				strAProp = new String[] {"foo", "bar", "baz"};
+				intAProp = new int[] {3, 2, 1};
+			}
+		};
+		new Thread(runnable).start();
+
+		try {
+			Thread.sleep(500);
+		} catch (InterruptedException e) {
+			e.printStackTrace();
+		}
+
+		return true;
+	}
+
+	public Properties fooProps() {
+		Properties p = new Properties();
+		p.put("intProp", new Integer(intProp));
+		p.put("boolProp", new Boolean(boolProp));
+		p.put("strProp", strProp);
+		p.put("strAProp", strAProp);
+		p.put("intAProp", intAProp);
+		return p;
+	}
+
+	public boolean getBoolean() { return true; }
+
+	public double getDouble() { return 1.0; }
+
+	public int getInt() { return 1; }
+
+	public long getLong() { return 1; }
+
+	public Boolean getObject() { return new Boolean(true); }
+
+
+
+}

Added: felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/ps/PropertiesInAnonymousClassTest.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/ps/PropertiesInAnonymousClassTest.java?rev=939354&view=auto
==============================================================================
--- felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/ps/PropertiesInAnonymousClassTest.java (added)
+++ felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/ps/PropertiesInAnonymousClassTest.java Thu Apr 29 15:53:58 2010
@@ -0,0 +1,77 @@
+package org.apache.felix.ipojo.test.scenarios.ps;
+
+import org.apache.felix.ipojo.junit4osgi.OSGiTestCase;
+import org.apache.felix.ipojo.junit4osgi.helpers.IPOJOHelper;
+import org.apache.felix.ipojo.test.scenarios.ps.service.FooService;
+import org.osgi.framework.ServiceReference;
+
+public class PropertiesInAnonymousClassTest extends OSGiTestCase {
+
+	IPOJOHelper helper;
+
+	public void setUp() {
+	    helper = new IPOJOHelper(this);
+		String type = "PS-FooProviderTypeAnonymous-Dyn";
+		helper.createComponentInstance(type, "FooProviderAno-1");
+
+	}
+
+	public void tearDown() {
+		helper.dispose();
+	}
+
+	public void testProperties1() {
+		ServiceReference sr = helper.getServiceReferenceByName(FooService.class.getName(), "FooProviderAno-1");
+		assertNotNull("Check the availability of the FS service", sr);
+
+		// Check service properties
+		Integer intProp = (Integer) sr.getProperty("int");
+		Boolean boolProp = (Boolean) sr.getProperty("boolean");
+		String strProp = (String) sr.getProperty("string");
+		String[] strAProp = (String[]) sr.getProperty("strAProp");
+		int[] intAProp = (int[]) sr.getProperty("intAProp");
+
+		assertEquals("Check intProp equality (1)", intProp, new Integer(2));
+		assertEquals("Check longProp equality (1)", boolProp, new Boolean(false));
+		assertEquals("Check strProp equality (1)", strProp, new String("foo"));
+		assertNotNull("Check strAProp not nullity (1)", strAProp);
+		String[] v = new String[] {"foo", "bar"};
+		for (int i = 0; i < strAProp.length; i++) {
+			if(!strAProp[i].equals(v[i])) { fail("Check the strAProp Equality (1)"); }
+		}
+		assertNotNull("Check intAProp not nullity", intAProp);
+		int[] v2 = new int[] {1, 2, 3};
+		for (int i = 0; i < intAProp.length; i++) {
+			if(intAProp[i] != v2[i]) { fail("Check the intAProp Equality (1)"); }
+		}
+
+		// Invoke
+		FooService fs = (FooService) getServiceObject(sr);
+		assertTrue("invoke fs", fs.foo());
+
+		sr = helper.getServiceReferenceByName(FooService.class.getName(), "FooProviderAno-1");
+		// Re-check the property (change)
+		intProp = (Integer) sr.getProperty("int");
+		boolProp = (Boolean) sr.getProperty("boolean");
+		strProp = (String) sr.getProperty("string");
+		strAProp = (String[]) sr.getProperty("strAProp");
+		intAProp = (int[]) sr.getProperty("intAProp");
+
+		assertEquals("Check intProp equality (2)", intProp, new Integer(3));
+		assertEquals("Check longProp equality (2)", boolProp, new Boolean(true));
+		assertEquals("Check strProp equality (2)", strProp, new String("bar"));
+		assertNotNull("Check strAProp not nullity (2)", strAProp);
+		v = new String[] {"foo", "bar", "baz"};
+		for (int i = 0; i < strAProp.length; i++) {
+			if(!strAProp[i].equals(v[i])) { fail("Check the strAProp Equality (2)"); }
+		}
+		assertNotNull("Check intAProp not nullity (2)", intAProp);
+		v2 = new int[] {3, 2, 1};
+		for (int i = 0; i < intAProp.length; i++) {
+			if(intAProp[i] != v2[i]) { fail("Check the intAProp Equality (2)"); }
+		}
+
+		fs = null;
+	}
+
+}

Modified: felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/ps/ProvidedServiceTestSuite.java
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/ps/ProvidedServiceTestSuite.java?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/ps/ProvidedServiceTestSuite.java (original)
+++ felix/trunk/ipojo/tests/core/service-providing/src/main/java/org/apache/felix/ipojo/test/scenarios/ps/ProvidedServiceTestSuite.java Thu Apr 29 15:53:58 2010
@@ -1,4 +1,4 @@
-/* 
+/*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
  * distributed with this work for additional information
@@ -40,6 +40,7 @@ public class ProvidedServiceTestSuite ex
         ots.addTestSuite(OSGiPropertiesTest.class);
         ots.addTestSuite(NullCheck.class);
         ots.addTestSuite(ServiceControllerTest.class);
+        ots.addTestSuite(PropertiesInAnonymousClassTest.class);
         return ots;
     }
 

Modified: felix/trunk/ipojo/tests/core/service-providing/src/main/resources/metadata.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/core/service-providing/src/main/resources/metadata.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/core/service-providing/src/main/resources/metadata.xml (original)
+++ felix/trunk/ipojo/tests/core/service-providing/src/main/resources/metadata.xml Thu Apr 29 15:53:58 2010
@@ -9,14 +9,14 @@
     name="PS-FooProviderType-1" architecture="true">
     <provides />
   </component>
-  
+
   <component
     classname="org.apache.felix.ipojo.test.scenarios.component.FooProviderType1"
     name="PS-FooProviderType-itf" architecture="true">
     <provides
       specifications="org.apache.felix.ipojo.test.scenarios.ps.service.FooService" />
   </component>
-  
+
   <component
     classname="org.apache.felix.ipojo.test.scenarios.component.FooProviderType1"
     name="PS-FooProviderType-3" architecture="true">
@@ -30,7 +30,7 @@
       <property name="bar" field="m_bar" />
     </properties>
   </component>
-  
+
   <!-- Providers providing 2 services -->
   <component
     classname="org.apache.felix.ipojo.test.scenarios.component.FooBarProviderType1"
@@ -55,7 +55,7 @@
       <property name="baz" type="java.lang.String" value="bar" />
     </provides>
   </component>
-  
+
 
   <!-- Provider with dynamic property -->
   <component
@@ -70,7 +70,7 @@
       <property name="intAProp" field="intAProp" value="{1,2,3}" />
     </provides>
   </component>
-  
+
   <component
     classname="org.apache.felix.ipojo.test.scenarios.component.FooProviderType1"
     name="PS-FooProviderType-2" architecture="true">
@@ -83,7 +83,7 @@
       <property name="intAProp" type="int[]" value="{1,2,3}" />
     </provides>
   </component>
-  
+
   <component
     classname="org.apache.felix.ipojo.test.scenarios.component.FooProviderTypeDyn2"
     name="PS-FooProviderType-Dyn2" architecture="true">
@@ -96,7 +96,7 @@
         value="{1, 2,3 }" />
     </provides>
   </component>
-  
+
   <!--  Inherited Provides -->
   <component
     classname="org.apache.felix.ipojo.test.scenarios.component.inherited.ProcessImplementation1"
@@ -136,7 +136,7 @@
     name="PS-PI3" architecture="true">
     <provides />
   </component>
-  
+
   <!-- Concrete and abstract class -->
   <component
     classname="org.apache.felix.ipojo.test.scenarios.component.inherited.ProcessParentImplementation"
@@ -156,10 +156,10 @@
   <component
     classname="org.apache.felix.ipojo.test.scenarios.component.inherited.ProcessImplementation3"
     name="PS-PI7" architecture="true">
-    <provides specifications="[org.apache.felix.ipojo.test.scenarios.component.inherited.ProcessParentImplementation, 
+    <provides specifications="[org.apache.felix.ipojo.test.scenarios.component.inherited.ProcessParentImplementation,
           org.apache.felix.ipojo.test.scenarios.ps.service.FooService]"/>
   </component>
-  
+
   <!--  Null Check -->
   <component classname="org.apache.felix.ipojo.test.scenarios.component.NullCheckServiceProvider" immediate="true"
     name="PS-Null">
@@ -168,7 +168,7 @@
       <property field="prop2"/>
     </provides>
   </component>
-  
+
   <!--  Service Controller -->
   <component classname="org.apache.felix.ipojo.test.scenarios.component.controller.ControllerCheckService"
     name="PS-Controller-1-default">
@@ -210,4 +210,18 @@
         <controller field="controllerCS" value="true"/>
     </provides>
   </component>
+
+  <!-- Anonymous classes -->
+  <component
+    classname="org.apache.felix.ipojo.test.scenarios.component.FooProviderWithAnonymousClass"
+    name="PS-FooProviderTypeAnonymous-Dyn" architecture="true">
+    <provides>
+      <property name="int" field="intProp" value="2" />
+      <property name="boolean" field="boolProp" value="false" />
+      <property name="string" field="strProp" value="foo" />
+      <property name="strAProp" field="strAProp"
+        value="{foo, bar}" />
+      <property name="intAProp" field="intAProp" value="{1,2,3}" />
+    </provides>
+  </component>
 </ipojo>

Modified: felix/trunk/ipojo/tests/handler/eventadmin/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/handler/eventadmin/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/handler/eventadmin/pom.xml (original)
+++ felix/trunk/ipojo/tests/handler/eventadmin/pom.xml Thu Apr 29 15:53:58 2010
@@ -12,7 +12,7 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -22,7 +22,7 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.handler.eventadmin</artifactId>
-			<version>${pom.version}</version>
+			<version>1.5.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>junit</groupId>
@@ -55,7 +55,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>

Modified: felix/trunk/ipojo/tests/handler/temporal/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/ipojo/tests/handler/temporal/pom.xml?rev=939354&r1=939353&r2=939354&view=diff
==============================================================================
--- felix/trunk/ipojo/tests/handler/temporal/pom.xml (original)
+++ felix/trunk/ipojo/tests/handler/temporal/pom.xml Thu Apr 29 15:53:58 2010
@@ -27,12 +27,12 @@
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo</artifactId>
-			<version>${pom.version}</version>
+			<version>1.7.0-SNAPSHOT</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.ipojo.metadata</artifactId>
-			<version>${pom.version}</version>
+			<version>1.4.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.apache.felix</groupId>
@@ -79,7 +79,7 @@
 			<plugin>
 				<groupId>org.apache.felix</groupId>
 				<artifactId>maven-ipojo-plugin</artifactId>
-				<version>${pom.version}</version>
+				<version>1.6.0</version>
 				<executions>
 					<execution>
 						<goals>



Mime
View raw message