Details
-
Improvement
-
Status: Closed
-
Major
-
Resolution: Invalid
-
1.6
-
None
-
Java Linux
Description
I am using a CombinedConfiguration Object to load a configuration definition file and load all the configuration sources from it.
I use a config.xml file to load multiple Configuration Sources
Ex:
<configuration> <header/> <override> <properties fileName="db.properties" autoSave="true" config-name="properties1"/> <properties fileName="jms.properties" autoSave="true" config-name="properties2"/> <xml fileName="test.xml" autoSave="true" config-name="properties3"/> </override> <additional/> </configuration>
My test.xml(XML Properties File) file looks like this
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd"> <properties> <comment>Description of the property list</comment> <entry key="key1">value1</entry> <entry key="key2">value2</entry> <entry key="key3">value3</entry> </properties>
What tag should be used in the configuration definition file so that I can Load the XML Properties File from a CombinedConfiguration Object. I tried both <xml/> and <properties/>
When I do :
//Intialize the Combined Configuration Object combinedConfig combinedConfig.getConfiguration("properties3");
I am getting a XMLConfiguration Object instead of a XMLPropertiesConfiguration Object . Please advice.