Package org.gjt.xpp.impl.format
Class Formatter
- java.lang.Object
-
- org.gjt.xpp.impl.format.Recorder
-
- org.gjt.xpp.impl.format.Formatter
-
- All Implemented Interfaces:
XmlFormatter,XmlRecorder
public class Formatter extends Recorder implements XmlFormatter
Implementatin of Recorder that is simply writing XML to output sink.- Author:
- Aleksander Slominski
-
-
Field Summary
-
Fields inherited from class org.gjt.xpp.impl.format.Recorder
declaredNs, declaredPrefixes, out
-
-
Constructor Summary
Constructors Constructor Description Formatter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanisEndTagNewLine()Should new line be added after end tag?voidsetEndTagNewLine(boolean enable)Should new line be added after end tag?voidwriteEndTag(XmlEndTag etag)voidwriteStartTagAsEndTag(XmlStartTag stag)-
Methods inherited from class org.gjt.xpp.impl.format.Recorder
getOutput, setOutput, write, writeContent, writeEscaped, writeNode, writeStartTag, writeStartTagStart, writeXml
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.gjt.xpp.XmlRecorder
getOutput, setOutput, write, writeContent, writeNode, writeStartTag, writeStartTagStart, writeXml
-
-
-
-
Method Detail
-
isEndTagNewLine
public boolean isEndTagNewLine()
Description copied from interface:XmlFormatterShould new line be added after end tag?- Specified by:
isEndTagNewLinein interfaceXmlFormatter- See Also:
XmlFormatter.setEndTagNewLine(boolean)
-
setEndTagNewLine
public void setEndTagNewLine(boolean enable)
Should new line be added after end tag?- Specified by:
setEndTagNewLinein interfaceXmlFormatter
-
writeEndTag
public void writeEndTag(XmlEndTag etag) throws java.io.IOException, XmlPullParserException
- Specified by:
writeEndTagin interfaceXmlRecorder- Overrides:
writeEndTagin classRecorder- Throws:
java.io.IOExceptionXmlPullParserException
-
writeStartTagAsEndTag
public void writeStartTagAsEndTag(XmlStartTag stag) throws java.io.IOException, XmlPullParserException
- Specified by:
writeStartTagAsEndTagin interfaceXmlRecorder- Overrides:
writeStartTagAsEndTagin classRecorder- Throws:
java.io.IOExceptionXmlPullParserException
-
-