Package org.eclipse.net4j.util
Class XMLUtil
- java.lang.Object
-
- org.eclipse.net4j.util.XMLUtil
-
public final class XMLUtil extends java.lang.Object
- Since:
- 3.4
- Author:
- Eike Stepper
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
XMLUtil.ElementHandler
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static javax.xml.parsers.DocumentBuilder
createDocumentBuilder()
static int
handleChildElements(org.w3c.dom.Element rootElement, XMLUtil.ElementHandler handler)
static int
handleElements(org.w3c.dom.NodeList nodeList, XMLUtil.ElementHandler handler)
static int
handleElementsByTagName(org.w3c.dom.Element rootElement, java.lang.String tagName, XMLUtil.ElementHandler handler)
static org.w3c.dom.Document
loadDocument(javax.xml.parsers.DocumentBuilder documentBuilder, java.io.File file)
static org.w3c.dom.Element
loadRootElement(javax.xml.parsers.DocumentBuilder documentBuilder, java.io.File file)
-
-
-
Method Detail
-
createDocumentBuilder
public static javax.xml.parsers.DocumentBuilder createDocumentBuilder() throws javax.xml.parsers.ParserConfigurationException
- Throws:
javax.xml.parsers.ParserConfigurationException
-
loadRootElement
public static org.w3c.dom.Element loadRootElement(javax.xml.parsers.DocumentBuilder documentBuilder, java.io.File file) throws java.lang.Exception
- Throws:
java.lang.Exception
-
loadDocument
public static org.w3c.dom.Document loadDocument(javax.xml.parsers.DocumentBuilder documentBuilder, java.io.File file) throws org.xml.sax.SAXException, java.io.IOException
- Throws:
org.xml.sax.SAXException
java.io.IOException
-
handleElements
public static int handleElements(org.w3c.dom.NodeList nodeList, XMLUtil.ElementHandler handler) throws java.lang.Exception
- Throws:
java.lang.Exception
-
handleChildElements
public static int handleChildElements(org.w3c.dom.Element rootElement, XMLUtil.ElementHandler handler) throws java.lang.Exception
- Throws:
java.lang.Exception
-
handleElementsByTagName
public static int handleElementsByTagName(org.w3c.dom.Element rootElement, java.lang.String tagName, XMLUtil.ElementHandler handler) throws java.lang.Exception
- Throws:
java.lang.Exception
-
-