org.codehaus.plexus.util.xml
public class XmlUtil extends Object
Since: 1.5.7
Version: $Id: XmlUtil.java 8010 2009-01-07 12:59:50Z vsiveton $
| Field Summary | |
|---|---|
| static int | DEFAULT_INDENTATION_SIZE The default line indenter size i.e. |
| static String | DEFAULT_LINE_SEPARATOR The default line separator ("\n" on UNIX) |
| Method Summary | |
|---|---|
| static boolean | isXml(File f)
Determines if a given File shall be handled as XML.
|
| static void | prettyFormat(Reader reader, Writer writer)
Pretty format the input reader. |
| static void | prettyFormat(Reader reader, Writer writer, int indentSize, String lineSeparator)
Pretty format the input reader. |
| static void | prettyFormat(InputStream is, OutputStream os)
Pretty format the input stream. |
| static void | prettyFormat(InputStream is, OutputStream os, int indentSize, String lineSeparator)
Pretty format the input stream. |
Parameters: f not null file
Returns: true if the given file has XML content, false otherwise.
<div><b>content</b></div>becomes
<div> <b>content</b> </div>
Parameters: reader not null writer not null
Throws: IOException if any or invalid xml content
See Also: XmlUtil to read an xml content to write an xml content
<div><b>content</b></div>becomes
<div> <b>content</b> </div>
Parameters: reader not null writer not null indentSize positive number for the indentation lineSeparator the wanted line separator
Throws: IOException if any or invalid xml content
<div><b>content</b></div>becomes
<div> <b>content</b> </div>
Parameters: is not null os not null
Throws: IOException if any or invalid xml content
See Also: XmlUtil
<div><b>content</b></div>becomes
<div> <b>content</b> </div>
Parameters: is not null os not null indentSize positive number for the indentation lineSeparator the wanted line separator
Throws: IOException if any or invalid xml content