Is it possible to set references in the XML file to XSLT and XSD files which are packed into some archive? If so, how can you do it?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
From what I can tell, there is no generic, platform independent, interoperable way to set this up.
Each framework (Java, .NET, etc.) would have its own out of box approaches (or not), which is typically linked with:
It also depends a lot on how you expect these references to work for you, how you want the references to look like, which drives how those can be resolved at parsing time.
If you want everything done by the XML parser, you may want to look at XInclude and alike, using a URI scheme supported for your archive; if there is one, e.g. in Java you could try jar://, then this is your solution.
If your scheme is not supported but your platform allows to define new handlers, or override existing ones, for URI schemes, then it might be solved simply with your custome handler.
Another alternative is to build you own helper “service” that augments the standard parsing, and while at it, it scans the XML for your specific external reference nodes, and it replaces those reference nodes with content pulled from your external references, coming from your archive.
The only other serious problem I see is when your XSLT and XSD are authored across multiple files.