
Hi Sorin,
Now I think I understand. You want to apply an XSLT stylesheet to a stream of XML events generated by a custom parser from a binary file. You call the custom parser from a custom URI resolver that resolves the URL of the input XML file. You set the -u parameter for passing the URL of the input XML file through the custom URI resolver.
That's right.
This cannot be done in the current version of Oxygen because Oxygen passes the URL of the input XML file only through a built-in resolver that tries to resolve the URL of the input XML file with the XML catalogs set in the user preferences. The Saxon custom URI resolver is used by Saxon internally only for URIs from the XSLT stylesheet because the stream of XML events from the input XML file is provided by Oxygen. A future version of Oxygen will pass the URL of the input file also through the Saxon custom URI resolver as if the -u parameter is always set when Saxon is used in Oxygen.
I look forward to that.
There is a very simple workaround: load the input file through your custom URI resolver directly from the XSLT stylesheet with the document() function, something like:
<xsl:template match="/"> <xsl:apply-templates select="document('URI-of-binary-file-resolved-by-custom-UR-resolver')"/> </xsl:template>
Of course you have to set the class name of your custom URI resolver in Options -> Preferences -- XML -- XSLT/FO/XQuery -- XSLT -- Saxon -- Saxon 9 -- Advanced -- URI Resolver class name.
Did that. I tried this but it didn't work either. Still got the "Content not allowed in prolog" message. Thanks Peter