commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jon Smith <jons26...@gmail.com>
Subject [configuration] XInclude support in xml files
Date Thu, 10 Feb 2011 18:49:34 GMT
Hi,

I have searched through the archive as well as documentation but couldn't
find if Commons Configuration's XML format supports XInclude.

I know Digester has added this support but XMLConfiguration doesn't seem to
be using it or, at least, does not allow XInclude awareness to be set to
true.

I also tried giving my own XInclude and Namespace aware DocumentBuilder to
DefaultConfigurationBuilder but didn't seem to get XInclude to work.

Following is what I am trying to do:

configuration.xml snippet:

<additional>
   <xml fileName="file1.xml"/>
</additional>

file1.xml snippet:

<!-- namespaces declared in header -->
<myconfig>
   <config1 name="something"/>
   <xi:include href="file2.xml" parse="text"/>
</myconfig>

Any pointers?

The intent is to not to let users touch configuration.xml but include more
files to the already included (e.g. file1.xml) file.

thanks

J

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message