commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ohe...@apache.org
Subject svn commit: r1502868 - /commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/PropertiesConfiguration.java
Date Sat, 13 Jul 2013 19:42:58 GMT
Author: oheger
Date: Sat Jul 13 19:42:57 2013
New Revision: 1502868

URL: http://svn.apache.org/r1502868
Log:
Reworked the handling of the reserved include property.

The ListDelimiterHandler is now used to split the string into multiple values.

Modified:
    commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/PropertiesConfiguration.java

Modified: commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/PropertiesConfiguration.java
URL: http://svn.apache.org/viewvc/commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/PropertiesConfiguration.java?rev=1502868&r1=1502867&r2=1502868&view=diff
==============================================================================
--- commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/PropertiesConfiguration.java
(original)
+++ commons/proper/configuration/trunk/src/main/java/org/apache/commons/configuration/PropertiesConfiguration.java
Sat Jul 13 19:42:57 2013
@@ -24,6 +24,7 @@ import java.io.Reader;
 import java.io.Writer;
 import java.net.URL;
 import java.util.ArrayList;
+import java.util.Collection;
 import java.util.List;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
@@ -552,18 +553,11 @@ public class PropertiesConfiguration ext
         {
             if (isIncludesAllowed())
             {
-                String[] files;
-                if (!isDelimiterParsingDisabled())
-                {
-                    files = StringUtils.split(value, getListDelimiter());
-                }
-                else
-                {
-                    files = new String[]{value};
-                }
+                Collection<String> files =
+                        getListDelimiterHandler().split(value, true);
                 for (String f : files)
                 {
-                    loadIncludeFile(interpolate(f.trim()));
+                    loadIncludeFile(interpolate(f));
                 }
             }
             result = false;



Mime
View raw message