|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.ebmwebsourcing.easycommons.xml.XMLPrettyPrinter
public class XMLPrettyPrinter
An util class to prettify XML document
| Constructor Summary | |
|---|---|
XMLPrettyPrinter()
|
|
| Method Summary | |
|---|---|
static java.lang.String |
getEncoding(org.w3c.dom.Document xmlDocument)
|
static javax.xml.transform.Transformer |
getTransformer(javax.xml.transform.Source stylesheetSource)
Get a transformer from a stylesheet source |
static void |
prettify(java.io.InputStream in,
java.io.OutputStream out)
Prettify the xml input stream into the output stream. |
static void |
prettify(org.w3c.dom.Node node,
java.io.OutputStream out)
Prettify the node into the output stream. |
static void |
prettify(org.w3c.dom.Node node,
java.io.OutputStream out,
java.lang.String encoding)
Prettify the node into the output stream. |
static java.lang.String |
prettyPrint(org.w3c.dom.Document xmlDocument)
parse the xml Document and return it pretty-printed (with correct indentations, etc..). |
static java.lang.String |
prettyPrint(org.w3c.dom.Element node)
parse the xml Document and return it pretty-printed (with correct indentations, etc..). |
static java.lang.String |
prettyPrint(org.w3c.dom.Node node)
parse the xml Document and return it pretty-printed (with correct indentations, etc..). |
static java.lang.String |
prettyPrint(org.w3c.dom.Node xmlDocument,
java.lang.String encoding)
parse the xml String and return it pretty-printed (with correct indentations, etc..) |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public XMLPrettyPrinter()
| Method Detail |
|---|
public static java.lang.String prettyPrint(org.w3c.dom.Node xmlDocument,
java.lang.String encoding)
xmlDocument - the xml document to pretty print. Must be non nullencoding - the encoding to use
public static java.lang.String prettyPrint(org.w3c.dom.Document xmlDocument)
xmlDocument - the xml document to pretty print. Must be non null
public static java.lang.String prettyPrint(org.w3c.dom.Element node)
xmlDocument - the xml document to pretty print. Must be non null
public static java.lang.String prettyPrint(org.w3c.dom.Node node)
xmlDocument - the xml document to pretty print. Must be non null
public static void prettify(org.w3c.dom.Node node,
java.io.OutputStream out,
java.lang.String encoding)
throws java.lang.Exception
java.lang.Exception
public static void prettify(org.w3c.dom.Node node,
java.io.OutputStream out)
throws java.lang.Exception
java.lang.Exception
public static void prettify(java.io.InputStream in,
java.io.OutputStream out)
throws java.lang.Exception
java.lang.Exception
public static javax.xml.transform.Transformer getTransformer(javax.xml.transform.Source stylesheetSource)
throws javax.xml.transform.TransformerConfigurationException
stylesheetSource - a stylesheet source
javax.xml.transform.TransformerConfigurationException - if there is transformer configuration errorpublic static java.lang.String getEncoding(org.w3c.dom.Document xmlDocument)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||