Page 1 of 1

Is there any way to set parser features for a transformation scenario?

Posted: Fri Apr 26, 2024 12:07 pm
by Martin Honnen
Apache Xerces has parser features documented in https://xerces.apache.org/xerces-j/features.html, so for instance setting http://apache.org/xml/features/nonvalid ... ternal-dtd to false ignores the external DTD completely.

I was wondering whether oXygen somewhere/somehow selectively allows me to set such a parser feature for an XSLT or XQuery transformation scenario?

Re: Is there any way to set parser features for a transformation scenario?

Posted: Mon Apr 29, 2024 12:53 pm
by Mircea
Hello Martin,

Have you tried setting in the 'Edit Scenario" Dialog the "Advanced Options" for the Saxon 12.3 transformer ?
There is a check box called: DTD validation if the source ("-dtd") that can be switched "off".

Hope this helps,
Mircea

Re: Is there any way to set parser features for a transformation scenario?

Posted: Mon Apr 29, 2024 2:46 pm
by Martin Honnen
Thanks for your reply but not doing DTD validation or ignoring the external DTD are different issues, if I have e.g.

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE root SYSTEM "non-existing.dtd">
<root>
    <foo>bar</foo>
</root>
it doesn't help to set DTD validation to off, I nevertheless get an IO error by the parser that the file non-existing.dtd was not found and the whole transformation fails.

When I write Java code to set the parser feature I mentioned the intent to load the DTD is not made and then my transformation runs through.

The question is whether oXygen allows me in its settings/configurations for parsing and/or transformation scenarios to set such a parser feature.

Re: Is there any way to set parser features for a transformation scenario?

Posted: Fri May 03, 2024 6:14 pm
by Martin Honnen
Is there no way to set a parser feature? Is it possible to add that as a feature request for future oXygen versions?

Re: Is there any way to set parser features for a transformation scenario?

Posted: Tue May 07, 2024 11:16 am
by Mircea
Hello Martin,

Currently there is no way to set a parser feature for the transformation scenario.
We will take this into consideration, and let you know if it will be implemented.

Regards,
Mircea.