RFR: 8306632: Add a JDK Property for specifying DTD support

Lance Andersen lancea at openjdk.org
Tue Sep 5 19:31:37 UTC 2023


On Fri, 28 Jul 2023 18:41:48 GMT, Joe Wang <joehw at openjdk.org> wrote:

> Add a JDK Impl specific property 'jdk.xml.dtd.support' for applications to specify how DTDs are handled. This property is uniformly supported across the JDK XML libraries. It complements, rather than replaces, the existing properties that are supportDTD for StAX and disallow-doctype-decl for DOM and SAX processors, which means the later will continue to work as they were and that if they are set, the new property will have no effect. Applications that use the existing properties continue to work as expected.
> 
>    This patch continues the path made previously with Xalan and XPath in which functions were moved into the jdk/xml classes. Similar changes are now made with the Xerces and XML classes, consolidating functions into the jdk/xml classes, reducing duplicate code for easier future maintenance.
> 
> Tests: new tests are added to cover the various processors.
>        Existing tests pass. Only one was updated due to the change to the property impl.

Hi Joe,

I have made a few passes through the code and overall I think it is OK.

Nothing jumped out and was glaringly wrong given you have touched a large number  of classes and added a fair amount of additional tests

-------------

Marked as reviewed by lancea (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/15075#pullrequestreview-1611789294


More information about the core-libs-dev mailing list