Modifications required for web
authorMathieu Baudier <mbaudier@argeo.org>
Sun, 16 Dec 2007 20:42:20 +0000 (20:42 +0000)
committerMathieu Baudier <mbaudier@argeo.org>
Sun, 16 Dec 2007 20:42:20 +0000 (20:42 +0000)
git-svn-id: https://svn.argeo.org/slc/trunk@869 4cfe0d0a-d680-48aa-b62c-e0a02a3f76cc

org.argeo.slc.core/src/main/java/org/argeo/slc/ant/SlcAntConfig.java

index 61ca74774a51dbcc1dc4822271aea9b135323206..11fdd64310494515431cb0c6384c4ce362a5b55a 100644 (file)
@@ -153,7 +153,9 @@ public class SlcAntConfig {
 \r
                // pass the project properties through the System properties\r
                System.getProperties().putAll((Map<?, ?>) project.getUserProperties());\r
-               Properties all = prepareAllProperties(slcRootFile);\r
+               Properties all = new Properties();\r
+               all.putAll(System.getProperties());\r
+               prepareAllProperties(slcRootFile,all);\r
 \r
                Log log = LogFactory.getLog(this.getClass());\r
                for (Object o : all.keySet()) {\r
@@ -177,12 +179,10 @@ public class SlcAntConfig {
         * @return the prepared properties. Note that it also contains the System\r
         *         and Ant properties which had previously been set.\r
         */\r
-       protected Properties prepareAllProperties(File slcRootFile) {\r
+       public void prepareAllProperties(File slcRootFile, Properties all) {\r
                try {\r
                        final String fileUrlPrefix = "";\r
 \r
-                       Properties all = new Properties();\r
-                       all.putAll(System.getProperties());\r
                        all.put(ROOT_FILE_PROPERTY, slcRootFile.getCanonicalPath());\r
                        // Remove basedir property in order to avoid conflict with Maven\r
                        if (all.containsKey("basedir"))\r
@@ -258,8 +258,6 @@ public class SlcAntConfig {
                                Log4jConfigurer.initLogging(confDir.getCanonicalPath()\r
                                                + File.separator + "log4j.properties");\r
                        }\r
-\r
-                       return all;\r
                } catch (Exception e) {\r
                        throw new SlcAntException("Unexpected exception while configuring",\r
                                        e);\r