felix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gno...@apache.org
Subject svn commit: r952615 - /felix/trunk/bundlerepository/src/main/java/org/apache/felix/bundlerepository/impl/LocalResourceImpl.java
Date Tue, 08 Jun 2010 11:26:43 GMT
Author: gnodet
Date: Tue Jun  8 11:26:43 2010
New Revision: 952615

URL: http://svn.apache.org/viewvc?rev=952615&view=rev
Log:
FELIX-2385: Execution environment property is not correctly exposed

Modified:
    felix/trunk/bundlerepository/src/main/java/org/apache/felix/bundlerepository/impl/LocalResourceImpl.java

Modified: felix/trunk/bundlerepository/src/main/java/org/apache/felix/bundlerepository/impl/LocalResourceImpl.java
URL: http://svn.apache.org/viewvc/felix/trunk/bundlerepository/src/main/java/org/apache/felix/bundlerepository/impl/LocalResourceImpl.java?rev=952615&r1=952614&r2=952615&view=diff
==============================================================================
--- felix/trunk/bundlerepository/src/main/java/org/apache/felix/bundlerepository/impl/LocalResourceImpl.java
(original)
+++ felix/trunk/bundlerepository/src/main/java/org/apache/felix/bundlerepository/impl/LocalResourceImpl.java
Tue Jun  8 11:26:43 2010
@@ -21,6 +21,7 @@ package org.apache.felix.bundlerepositor
 import java.util.Dictionary;
 import java.util.HashSet;
 import java.util.Set;
+import java.util.StringTokenizer;
 
 import org.apache.felix.bundlerepository.Capability;
 import org.osgi.framework.Bundle;
@@ -72,9 +73,12 @@ public class LocalResourceImpl extends R
             String ee = m_bundle.getBundleContext().getProperty(Constants.FRAMEWORK_EXECUTIONENVIRONMENT);
             if (ee != null)
             {
-                CapabilityImpl cap = new CapabilityImpl(Capability.EXECUTIONENVIRONMENT);
-                cap.addProperty(Capability.EXECUTIONENVIRONMENT, ee);
-                addCapability(cap);
+                StringTokenizer tokens = new StringTokenizer(ee, ",");
+                while (tokens.hasMoreTokens()) {
+                    CapabilityImpl cap = new CapabilityImpl(Capability.EXECUTIONENVIRONMENT);
+                    cap.addProperty(Capability.EXECUTIONENVIRONMENT, tokens.nextToken().trim());
+                    addCapability(cap);
+                }
             }
 
 /* TODO: OBR - Fix system capabilities.



Mime
View raw message