< prev index next >

jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Serializer.java

Print this page




  45  * To serialize a DOM document or DOM element, create a compatible
  46  * serializer and call it's {@link
  47  * DOMSerializer#serialize(Document)} or {@link DOMSerializer#serialize(Element)} methods.
  48  * Both methods would produce a full XML document, to serizlie only
  49  * the portion of the document use {@link OutputFormat#setOmitXMLDeclaration}
  50  * and specify no document type.
  51  * <p>
  52  * The {@link OutputFormat} dictates what underlying serialized is used
  53  * to serialize the document based on the specified method. If the output
  54  * format or method are missing, the default is an XML serializer with
  55  * UTF-8 encoding and now indentation.
  56  *
  57  *
  58  * @author <a href="mailto:arkin@intalio.com">Assaf Arkin</a>
  59  * @author <a href="mailto:Scott_Boag/CAM/Lotus@lotus.com">Scott Boag</a>
  60  * @see DocumentHandler
  61  * @see ContentHandler
  62  * @see OutputFormat
  63  * @see DOMSerializer
  64  *
  65  * @deprecated As of JDK 1.9, Xerces 2.9.0, Xerces DOM L3 Serializer implementation
  66  * is replaced by that of Xalan. Main class
  67  * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced
  68  * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}.
  69  */
  70 public interface Serializer
  71 {
  72 
  73 
  74     /**
  75      * Specifies an output stream to which the document should be
  76      * serialized. This method should not be called while the
  77      * serializer is in the process of serializing a document.
  78      */
  79     public void setOutputByteStream(OutputStream output);
  80 
  81 
  82     /**
  83      * Specifies a writer to which the document should be serialized.
  84      * This method should not be called while the serializer is in
  85      * the process of serializing a document.




  45  * To serialize a DOM document or DOM element, create a compatible
  46  * serializer and call it's {@link
  47  * DOMSerializer#serialize(Document)} or {@link DOMSerializer#serialize(Element)} methods.
  48  * Both methods would produce a full XML document, to serizlie only
  49  * the portion of the document use {@link OutputFormat#setOmitXMLDeclaration}
  50  * and specify no document type.
  51  * <p>
  52  * The {@link OutputFormat} dictates what underlying serialized is used
  53  * to serialize the document based on the specified method. If the output
  54  * format or method are missing, the default is an XML serializer with
  55  * UTF-8 encoding and now indentation.
  56  *
  57  *
  58  * @author <a href="mailto:arkin@intalio.com">Assaf Arkin</a>
  59  * @author <a href="mailto:Scott_Boag/CAM/Lotus@lotus.com">Scott Boag</a>
  60  * @see DocumentHandler
  61  * @see ContentHandler
  62  * @see OutputFormat
  63  * @see DOMSerializer
  64  *
  65  * @deprecated As of JDK 9, Xerces 2.9.0, Xerces DOM L3 Serializer implementation
  66  * is replaced by that of Xalan. Main class
  67  * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced
  68  * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}.
  69  */
  70 public interface Serializer
  71 {
  72 
  73 
  74     /**
  75      * Specifies an output stream to which the document should be
  76      * serialized. This method should not be called while the
  77      * serializer is in the process of serializing a document.
  78      */
  79     public void setOutputByteStream(OutputStream output);
  80 
  81 
  82     /**
  83      * Specifies a writer to which the document should be serialized.
  84      * This method should not be called while the serializer is in
  85      * the process of serializing a document.


< prev index next >