felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ali Naddaf (JIRA)" <j...@apache.org>
Subject [jira] Created: (FELIX-1055) Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible
Date Thu, 23 Apr 2009 18:17:30 GMT
Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible

                 Key: FELIX-1055
                 URL: https://issues.apache.org/jira/browse/FELIX-1055
             Project: Felix
          Issue Type: Improvement
          Components: File Install
         Environment: All
            Reporter: Ali Naddaf
            Priority: Minor

A minor change will make File Install bundle compatible with the CDC-1.1/Foundation-1.1 compatible:

Index: src/main/java/org/apache/felix/fileinstall/FileInstall.java
--- src/main/java/org/apache/felix/fileinstall/FileInstall.java (revision 761715)
+++ src/main/java/org/apache/felix/fileinstall/FileInstall.java (working copy)
@@ -68,7 +68,7 @@
         Object o = context.getProperty(key);
         if (o == null)
-            o = System.getenv(key.toUpperCase().replaceAll(".", "_"));
+           o = System.getProperty(key.toUpperCase().replace('.', '_'));
             if (o == null)

The only needed change is in the FileInstall class:
1. replacing String.replaceAll(String, String) with String.replace(char, char) (since replaceAll
is not part of that profile and we are only making one char replacement). If a more robust
replaceAll functionality is required, please let me know and I provide a simple implementation.
2. Using System.getProperty(..) instead of System.getenv(...)


This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message