[
https://issues.apache.org/jira/browse/XERCESJ-1712?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Olivier Cailloux updated XERCESJ-1712:
--------------------------------------
Description:
Calling {{createLSSerializer}} on a {{DOMImplementationLS}} instance returns an
instance of {{org.apache.xml.serialize.DOMSerializerImpl}}. The javadoc of that
class (using {{xerces:xercesImpl:2.12.0}}) says: “@deprecated Replaced by
org.apache.xml.serializer.dom3.LSSerializerImpl in Xerces 2.9.0”.
I spent two hours trying to solve that problem because I thought this was the
cause for some error I was observing when serializing an XML document. I
realized later that the error was a mistake in my code. But still, the new
class {{LSSerializerImpl}} should, I suppose, be used instead of the old one
{{DOMSerializerImpl}}, or the documentation is misleading if the intent is not
to fully replace the {{DOMSerializerImpl}} class by {{LSSerializerImpl}}.
A sample project that exhibits the instance of
{{org.apache.xml.serialize.DOMSerializerImpl}} being used is available at
[https://github.com/oliviercailloux/xerces-user] (code
[here|https://github.com/oliviercailloux/xerces-user/blob/master/src/main/java/io/github/oliviercailloux/XercesUser.java]).
was:
Calling {{createLSSerializer}} on a {{DOMImplementationLS}} instance returns an
instance of {{org.apache.xml.serialize.DOMSerializerImpl}}. The javadoc of that
class (using {{xerces:xercesImpl:2.12.0}}) says: “@deprecated Replaced by
org.apache.xml.serializer.dom3.LSSerializerImpl in Xerces 2.9.0”.
I spent two hours trying to solve that problem because I thought this was the
cause for some error I was observing when serializing an XML document. I
realized later that the error was a mistake in my code. But still, the new
class {{LSSerializerImpl}} should, I suppose, be used instead of the old one
{{DOMSerializerImpl}}, or the documentation is misleading if the intent is not
to fully replace the {{DOMSerializerImpl}} class by {{LSSerializerImpl}}.
A sample project that exhibits the instance of
{{org.apache.xml.serialize.DOMSerializerImpl}} being used is available at
[https://github.com/oliviercailloux/xerces-user].
> Class org.apache.xml.serialize.DOMSerializerImpl should not be used, or
> misleading doc
> --------------------------------------------------------------------------------------
>
> Key: XERCESJ-1712
> URL: https://issues.apache.org/jira/browse/XERCESJ-1712
> Project: Xerces2-J
> Issue Type: Bug
> Reporter: Olivier Cailloux
> Priority: Minor
>
> Calling {{createLSSerializer}} on a {{DOMImplementationLS}} instance returns
> an instance of {{org.apache.xml.serialize.DOMSerializerImpl}}. The javadoc of
> that class (using {{xerces:xercesImpl:2.12.0}}) says: “@deprecated Replaced
> by org.apache.xml.serializer.dom3.LSSerializerImpl in Xerces 2.9.0”.
> I spent two hours trying to solve that problem because I thought this was the
> cause for some error I was observing when serializing an XML document. I
> realized later that the error was a mistake in my code. But still, the new
> class {{LSSerializerImpl}} should, I suppose, be used instead of the old one
> {{DOMSerializerImpl}}, or the documentation is misleading if the intent is
> not to fully replace the {{DOMSerializerImpl}} class by {{LSSerializerImpl}}.
> A sample project that exhibits the instance of
> {{org.apache.xml.serialize.DOMSerializerImpl}} being used is available at
> [https://github.com/oliviercailloux/xerces-user] (code
> [here|https://github.com/oliviercailloux/xerces-user/blob/master/src/main/java/io/github/oliviercailloux/XercesUser.java]).
--
This message was sent by Atlassian JIRA
(v7.6.14#76016)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]