Top Description Fields Methods
com.fasterxml.jackson.dataformat.xml

public Interface XmlPrettyPrinter

extends PrettyPrinter
Known Direct Implementers
com.fasterxml.jackson.dataformat.xml.util.DefaultXmlPrettyPrinter
Imports
java.math.BigDecimal, .BigInteger, javax.xml.stream.XMLStreamException, org.codehaus.stax2.XMLStreamWriter2, com.fasterxml.jackson.core.PrettyPrinter

There are some XML-specific quirks that need extra TLC when indenting: so we will use a refinement of general purpose one.

Field Summary

Inherited from com.fasterxml.jackson.core.PrettyPrinter:
DEFAULT_ROOT_VALUE_SEPARATORDEFAULT_SEPARATORS

Method Summary

Modifier and TypeMethod and Description
public void
writeEndElement(XMLStreamWriter2 sw, int nrOfEntries)

Method for forcibly writing an end element, without going through Jackson generator (and thus, without updating currently active element stack)

public void
writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, String text, boolean isCData)

public void
writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, char[] buffer, int offset, int len, boolean isCData)

public void
writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, boolean value)

public void
writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, int value)

public void
writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, long value)

public void
writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, double value)

public void
writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, float value)

public void
public void
public void
writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, Base64Variant base64variant, byte[] data, int offset, int len)

public void
public void
writePrologLinefeed(XMLStreamWriter2 sw)

Method for trying to write a linefeed to separate entities outside of the root element (that is, in prolog or epilog), most often called to separate XML declaration from the root element.

public void
writeStartElement(XMLStreamWriter2 sw, String nsURI, String localName)

Method for forcibly writing a start element, without going through Jackson generator (and thus, without updating currently active element stack)

Inherited from com.fasterxml.jackson.core.PrettyPrinter:
beforeArrayValuesbeforeObjectEntrieswriteArrayValueSeparatorwriteEndArraywriteEndObjectwriteObjectEntrySeparatorwriteObjectFieldValueSeparatorwriteRootValueSeparatorwriteStartArraywriteStartObject

Method Detail

writeEndElementback to summary
public void writeEndElement(XMLStreamWriter2 sw, int nrOfEntries) throws XMLStreamException

Method for forcibly writing an end element, without going through Jackson generator (and thus, without updating currently active element stack)

Since
2.1
writeLeafElementback to summary
public void writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, String text, boolean isCData) throws XMLStreamException
writeLeafElementback to summary
public void writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, char[] buffer, int offset, int len, boolean isCData) throws XMLStreamException
writeLeafElementback to summary
public void writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, boolean value) throws XMLStreamException
writeLeafElementback to summary
public void writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, int value) throws XMLStreamException
writeLeafElementback to summary
public void writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, long value) throws XMLStreamException
writeLeafElementback to summary
public void writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, double value) throws XMLStreamException
writeLeafElementback to summary
public void writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, float value) throws XMLStreamException
writeLeafElementback to summary
public void writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, BigInteger value) throws XMLStreamException
writeLeafElementback to summary
public void writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, BigDecimal value) throws XMLStreamException
writeLeafElementback to summary
public void writeLeafElement(XMLStreamWriter2 sw, String nsURI, String localName, Base64Variant base64variant, byte[] data, int offset, int len) throws XMLStreamException
writeLeafNullElementback to summary
public void writeLeafNullElement(XMLStreamWriter2 sw, String nsURI, String localName) throws XMLStreamException
writePrologLinefeedback to summary
public void writePrologLinefeed(XMLStreamWriter2 sw) throws XMLStreamException

Method for trying to write a linefeed to separate entities outside of the root element (that is, in prolog or epilog), most often called to separate XML declaration from the root element.

Since
2.7
writeStartElementback to summary
public void writeStartElement(XMLStreamWriter2 sw, String nsURI, String localName) throws XMLStreamException

Method for forcibly writing a start element, without going through Jackson generator (and thus, without updating currently active element stack)

Since
2.1