--- old/src/java.xml/share/classes/org/w3c/dom/ls/LSSerializer.java 2017-12-11 12:46:45.792014976 -0800
+++ new/src/java.xml/share/classes/org/w3c/dom/ls/LSSerializer.java 2017-12-11 12:46:44.758914115 -0800
@@ -51,7 +51,8 @@
* output stream. Any changes or fixups made during the serialization affect
* only the serialized data. The Document
object and its
* children are never altered by the serialization operation.
- *
During serialization of XML data, namespace fixup is done as defined in [DOM Level 3 Core] + *
During serialization of XML data, namespace fixup is done as defined in
+ * [DOM Level 3 Core]
* , Appendix B. [DOM Level 2 Core]
* allows empty strings as a real namespace URI. If the
* namespaceURI
of a Node
is empty string, the
@@ -80,12 +81,14 @@
* namespace fixup is done. The resulting output will be valid as an
* external entity.
*
- *
true
, EntityReference
nodes are
+ * true
, EntityReference
nodes are
* serialized as an entity reference of the form "
* &entityName;
" in the output. Child nodes (the expansion)
- * of the entity reference are ignored. If the parameter "
- * entities" is set to false
, only the children of the entity reference
+ * of the entity reference are ignored. If the parameter
+ * "entities"
+ * is set to false
, only the children of the entity reference
* are serialized. EntityReference
nodes with no children (no
* corresponding Entity
node or the corresponding
* Entity
nodes have no children) are always serialized.
@@ -93,15 +96,16 @@
* CDATAsections
containing content characters that cannot be
* represented in the specified output encoding are handled according to the
- * "
- * split-cdata-sections" parameter. If the parameter is set to true
,
+ * "split-cdata-sections"
+ * parameter. If the parameter is set to true
,
* CDATAsections
are split, and the unrepresentable characters
* are serialized as numeric character references in ordinary content. The
* exact position and number of splits is not specified. If the parameter
* is set to false
, unrepresentable characters in a
* CDATAsection
are reported as
- * "wf-invalid-character"
errors if the parameter "
- * well-formed" is set to true
. The error is not recoverable - there is no
+ * "wf-invalid-character"
errors if the parameter
+ * "well-formed"
+ * is set to true
. The error is not recoverable - there is no
* mechanism for supplying alternative characters and continuing with the
* serialization.
* DOMError
fatal error. An example would be serializing
* the element <LaCañada/> with encoding="us-ascii"
.
* This will result with a generation of a DOMError
- * "wf-invalid-character-in-node-name" (as proposed in "
- * well-formed").
- * When requested by setting the parameter "
- * normalize-characters" on LSSerializer
to true, character normalization is
- * performed according to the definition of fully
- * normalized characters included in appendix E of [XML 1.1] on all
+ * "wf-invalid-character-in-node-name" (as proposed in
+ * "well-formed").
+ *
When requested by setting the parameter
+ * "normalize-characters"
+ * on LSSerializer
to true, character normalization is
+ * performed according to the definition of
+ * fully
+ * normalized characters included in appendix E of
+ * [XML 1.1] on all
* data to be serialized, both markup and character data. The character
* normalization process affects only the data as it is being written; it
* does not alter the DOM's view of the document after serialization has
@@ -170,13 +177,15 @@
* inconsistencies are found, the serialized form of the document will be
* altered to remove them. The method used for doing the namespace fixup
* while serializing a document is the algorithm defined in Appendix B.1,
- * "Namespace normalization", of [DOM Level 3 Core]
+ * "Namespace normalization", of
+ * [DOM Level 3 Core]
* .
*
While serializing a document, the parameter "discard-default-content" * controls whether or not non-specified data is serialized. *
While serializing, errors and warnings are reported to the application
- * through the error handler (LSSerializer.domConfig
's "
- * error-handler" parameter). This specification does in no way try to define all possible
+ * through the error handler (LSSerializer.domConfig
's
+ * "error-handler"
+ * parameter). This specification does in no way try to define all possible
* errors and warnings that can occur while serializing a DOM node, but some
* common error and warning cases are defined. The types (
* DOMError.type
) of errors and warnings defined by this
@@ -189,8 +198,9 @@
*
"unbound-prefix-in-entity-reference" [fatal]
true
and an entity whose replacement text
+ * configuration parameter
+ * "namespaces"
+ * is set to true
and an entity whose replacement text
* contains unbound namespace prefixes is referenced in a location where
* there are no bindings for the namespace prefixes. See also the Document Object Model (DOM) Level 3 Load -and Save Specification. + *
See also the
+ *
+Document Object Model (DOM) Level 3 Load and Save Specification.
*
* @since 1.5
*/
@@ -211,8 +222,10 @@
/**
* The DOMConfiguration
object used by the
* LSSerializer
when serializing a DOM node.
- *
In addition to the parameters recognized by the
- * DOMConfiguration interface defined in [DOM Level 3 Core]
+ *
In addition to the parameters recognized by the
+ * DOMConfiguration
+ * interface defined in
+ * [DOM Level 3 Core]
* , the DOMConfiguration
objects for
* LSSerializer
adds, or modifies, the following
* parameters:
@@ -221,9 +234,11 @@
*
true
true
will set the parameters
* "format-pretty-print", "discard-default-content", and "xml-declaration
* ", to false
. Setting one of those parameters to
@@ -267,7 +282,8 @@
* true
"unknown-character-denormalization"
warning (instead of
@@ -281,18 +297,21 @@
* "normalize-characters"
DOMConfiguration
in [DOM Level 3 Core]
+ * the one defined by DOMConfiguration
in
+ * [DOM Level 3 Core]
* . Unlike in the Core, the default value for this parameter is
* true
. While DOM implementations are not required to
* support fully
- * normalizing the characters in the document according to appendix E of [XML 1.1], this
+ * normalizing the characters in the document according to appendix E of
+ * [XML 1.1], this
* parameter must be activated by default if supported. "xml-declaration"
true
Document
, Element
, or Entity
+ * Document
,
+ * Element
, or Entity
* node is serialized, the XML declaration, or text declaration, should
* be included. The version (Document.xmlVersion
if the
* document is a Level 3 document and the version is non-null, otherwise
@@ -303,7 +322,8 @@
* false
* "xml-declaration-needed"
warning if this will cause
- * problems (i.e. the serialized data is of an XML version other than [XML 1.0], or an
+ * problems (i.e. the serialized data is of an XML version other than
+ * [XML 1.0], or an
* encoding would be needed to be able to re-parse the serialized data). DOMConfiguration
parameters have been applied. For
- * example, CDATA sections won't be passed to the filter if "
- * cdata-sections" is set to false
.
+ * example, CDATA sections won't be passed to the filter if
+ * "cdata-sections"
+ * is set to false
.
*/
public LSSerializerFilter getFilter();
/**
@@ -371,8 +392,9 @@
* serialization early.
* DOMConfiguration
parameters have been applied. For
- * example, CDATA sections won't be passed to the filter if "
- * cdata-sections" is set to false
.
+ * example, CDATA sections won't be passed to the filter if
+ * "cdata-sections"
+ * is set to false
.
*/
public void setFilter(LSSerializerFilter filter);
@@ -414,8 +436,9 @@
* @exception LSException
* SERIALIZE_ERR: Raised if the LSSerializer
was unable to
* serialize the node. DOM applications should attach a
- * DOMErrorHandler
using the parameter "
- * error-handler" if they wish to get details on the error.
+ * DOMErrorHandler
using the parameter
+ * "error-handler"
+ * if they wish to get details on the error.
*/
public boolean write(Node nodeArg,
LSOutput destination)
@@ -436,8 +459,9 @@
* @exception LSException
* SERIALIZE_ERR: Raised if the LSSerializer
was unable to
* serialize the node. DOM applications should attach a
- * DOMErrorHandler
using the parameter "
- * error-handler" if they wish to get details on the error.
+ * DOMErrorHandler
using the parameter
+ * "error-handler"
+ * if they wish to get details on the error.
*/
public boolean writeToURI(Node nodeArg,
String uri)
@@ -458,8 +482,9 @@
* @exception LSException
* SERIALIZE_ERR: Raised if the LSSerializer
was unable to
* serialize the node. DOM applications should attach a
- * DOMErrorHandler
using the parameter "
- * error-handler" if they wish to get details on the error.
+ * DOMErrorHandler
using the parameter
+ * "error-handler"
+ * if they wish to get details on the error.
*/
public String writeToString(Node nodeArg)
throws DOMException, LSException;