This week's book giveaway is in the Mac OS forum. We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line! See this thread for details.
I know a schema can include an .xsd in its definition, but can an XML file include actual elements from another XML document? Basically, I have an XML config file, part of which needs to be shared between subsystems (a shared folder location for writing files). The file builder classes I'm working with need to know this path, but they also need some other information which is only related to them; the other subsystem doesn't need to know about these extra configurations. So I'd like to share an XML file between systems for a common configuration, but also have a separate XML file for my file builders, but have that XML file include the information in the shared one. *begins to babble incoherently*
I think it might make sense to have each of the (separate) XML config files, have the name of the common one. Then, have the code that processes the config file interpret the reference to the common file and read that one as well.
Chicken Farmer ()
Joined: May 08, 2001
That's a good option, David. Didn't even think about that *baps himself over the head* Thanks!
If you are doing ant build, the common part as XML fragnent is stored in a file, then the build.xml will include an external system entity. This is a kind of standard way to do it. If it is configuration, we use component replacement to include other well-formed xml files.