Class XmlUtilities
-
- All Implemented Interfaces:
public final class XmlUtilitiesCommonly used XML utilities.
Griefed
-
-
Constructor Summary
Constructors Constructor Description XmlUtilities(DocumentBuilderFactory documentBuilderFactory)
-
Method Summary
Modifier and Type Method Description final DocumentgetXml(File manifest)Reads the file into a Document and Document.normalize it. final DocumentgetXml(String string)Reads the string into a Document and Document.normalize it. final DocumentgetXml(InputStream manifest)Reads the input-stream into a Document and Document.normalize it. -
-
Constructor Detail
-
XmlUtilities
XmlUtilities(DocumentBuilderFactory documentBuilderFactory)
- Parameters:
documentBuilderFactory- used for parsing XML-files.
-
-
Method Detail
-
getXml
final Document getXml(File manifest)
Reads the file into a Document and Document.normalize it.
- Parameters:
manifest- The xml-file to parse into a Document.- Returns:
The parsed and normalized document.
-
getXml
final Document getXml(String string)
Reads the string into a Document and Document.normalize it.
- Parameters:
string- The xml-string to parse into a Document.- Returns:
The parsed and normalized document.
-
getXml
final Document getXml(InputStream manifest)
Reads the input-stream into a Document and Document.normalize it.
- Parameters:
manifest- The xml-input-stream to parse into a Document.- Returns:
The parsed and normalized document.
-
-
-
-