PrettyPrinter
Class for pretty printing. After instantiating, you can use the format() and formatNode() methods to convert XML to a formatted string. The class can be reused to pretty print any number of XML nodes.
Value parameters
- minimizeEmpty
-
self-close empty tags
- step
-
indentation
- width
-
the width to fit the output into
Attributes
- Note
-
This class is not threadsafe and should not be accessed by multiple threads at the same time.
- Graph
-
- Supertypes
Members list
Type members
Classlikes
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Itemclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
Value members
Concrete methods
Try to cut at whitespace.
Try to cut at whitespace.
Attributes
Appends a formatted string containing well-formed XML with given namespace to prefix mapping to the given string buffer.
Appends a formatted string containing well-formed XML with given namespace to prefix mapping to the given string buffer.
Value parameters
- n
-
the node to be serialized
- sb
-
the stringbuffer to append to
Attributes
Returns a formatted string containing well-formed XML with given namespace to prefix mapping.
Returns a formatted string containing well-formed XML with given namespace to prefix mapping.
Value parameters
- n
-
the node to be serialized
- pscope
-
the namespace to prefix mapping
Attributes
- Returns
-
the formatted string
Returns a formatted string containing well-formed XML.
Returns a formatted string containing well-formed XML.
Value parameters
- nodes
-
the sequence of nodes to be serialized
- pscope
-
the namespace to prefix mapping
Attributes
Appends a formatted string containing well-formed XML with the given namespace to prefix mapping to the given stringbuffer.
Appends a formatted string containing well-formed XML with the given namespace to prefix mapping to the given stringbuffer.
Value parameters
- nodes
-
the nodes to be serialized
- pscope
-
the namespace to prefix mapping
- sb
-
the string buffer to which to append to
Attributes
Try to make indented box, if possible, else para.
Try to make indented box, if possible, else para.