Class EncodingXmlWriter

java.lang.Object
com.ctc.wstx.sw.XmlWriter
com.ctc.wstx.sw.EncodingXmlWriter
Direct Known Subclasses:
AsciiXmlWriter, ISOLatin1XmlWriter

public abstract class EncodingXmlWriter extends XmlWriter
Intermediate base class used when outputting to streams that use an encoding that is compatible with 7-bit single-byte Ascii encoding. That means it can be used for UTF-8, ISO-Latin1 and pure Ascii.

Implementation notes:

Parts of surrogate handling are implemented here in the base class: storage for the first part of a split surrogate (only possible when character content is output split in multiple calls) is within base class. Also, simple checks for unmatched surrogate pairs are in writeAscii method, since it is the most convenient place to catch cases where a text segment ends with an unmatched surrogate pair half.