[xsd-users] XML within XML
Javier Gutierrez
javier.gutierrez at web.de
Tue Aug 6 03:57:01 EDT 2019
Hello there,
currently I am using a different DOM XML parser for my XMLs, with no XSD
support
I would like to switch to a XSD based decoding for better validation and
easy-accessing.
I have below scenario. My challenge is that once the whole document is
parsed, I need to pass their corresponding piece of XML (namely
<config>) to each of the modules, they will have their own XSD for it.
In the main XSD I am trying to do this with <any> for <config>. But then
I am not sure how to pass the decoded item to the modules. I am thinking
about serializing them back and passing them down as text, but I want to
know if there is a better way.
Thank you very much for your time..
<mainConfig>
<somestuff>
</somestuff>
<moduleList>
<module>
<name>module1</name>
<config>
<blahblah>Configuration for module 1</blahblah>
<config>
</module>
<module>
<name>module2</name>
<config>
<blahblah>Configuration for module 2</blahblah>
<config>
</module>
</moduleList>
<someotherstuff>
</someotherstuff>
</mainConfig>
More information about the xsd-users
mailing list