HierarchicalConfiguration.subset(...) misses an entry with the key equal to the 
subset prefix.
----------------------------------------------------------------------------------------------

                 Key: CONFIGURATION-295
                 URL: https://issues.apache.org/jira/browse/CONFIGURATION-295
             Project: Commons Configuration
          Issue Type: Bug
    Affects Versions: 1.4
         Environment: Commons configuration V1.4
Loaded configuration: An ordinary commons config XML file referring to two 
property files.
            Reporter: Eduard Rindt


Having a HierarchicalConfiguration with entries alike:
    test.sample = subset title
    test.sample.boolean = true
    test.sample.int = 123456
    test.sample.text = I wish it worked!

When performing subset("test.sample"), I get a configuration of only three 
entries, the "subset title" value is not present (should have an empty string 
key).

The behaviour is in contradiction to Javadoc of the Configuration interface 
http://commons.apache.org/configuration/apidocs/org/apache/commons/configuration/Configuration.html#subset(java.lang.String)

Seems to me, that the bug is hidden in iterating the cloned configuration, 
where only children of the clone are processed, but not the root itself.

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

Reply via email to