getXMLWriter

Returns an XmlWriter interface that can be used to serialize an XML document.

NDS Version:8.5

Syntax

C++

 #include "NativeInterface.h"
 
 XmlWriter * METHOD_CALL getXmlWriter (
    OutputStream   *outputStream);
 

Java

 public XmlWriter getXmlWriter (
      java.io.OutputStream   outputStream,
      java.lang.String        encoding)
 
 
 throws   java.io.UnsupportedEncodingException
 

Parameters

outputStream
Points to the stream to which to write. This parameter cannot be zero (0).
encoding
Specifies the character encoding to use in writing to the outputStream such as "ASCII", "US-ASCII", "UTF-8", or "UTF-16".

Remarks

The XmlWriter interface has methods for closely controlling how the XML is output. For example, if the document contains only text, the XML output escaping can be disabled.

After you set the various attributes, calling the XmlWriter's write method causes the serialization to occur.