public final class XMLUtil extends Object
Modifier and Type | Class and Description |
---|---|
static interface |
XMLUtil.ElementHandler |
Modifier and Type | Method and Description |
---|---|
static DocumentBuilder |
createDocumentBuilder() |
static int |
handleChildElements(Element rootElement,
XMLUtil.ElementHandler handler) |
static int |
handleElements(NodeList nodeList,
XMLUtil.ElementHandler handler) |
static int |
handleElementsByTagName(Element rootElement,
String tagName,
XMLUtil.ElementHandler handler) |
static Document |
loadDocument(DocumentBuilder documentBuilder,
File file) |
static Element |
loadRootElement(DocumentBuilder documentBuilder,
File file) |
public static DocumentBuilder createDocumentBuilder() throws ParserConfigurationException
ParserConfigurationException
public static Element loadRootElement(DocumentBuilder documentBuilder, File file) throws Exception
Exception
public static Document loadDocument(DocumentBuilder documentBuilder, File file) throws SAXException, IOException
SAXException
IOException
public static int handleElements(NodeList nodeList, XMLUtil.ElementHandler handler) throws Exception
Exception
public static int handleChildElements(Element rootElement, XMLUtil.ElementHandler handler) throws Exception
Exception
public static int handleElementsByTagName(Element rootElement, String tagName, XMLUtil.ElementHandler handler) throws Exception
Exception
Copyright (c) 2011-2015 Eike Stepper (Berlin, Germany) and others.