public class DomReader
extends java.lang.Object
Constructor and Description |
---|
DomReader() |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
getAttributeValue(org.w3c.dom.Node node,
java.lang.String attributeName)
Fetches the value of a given attribute
|
protected static org.w3c.dom.Node |
getChildByAttribute(org.w3c.dom.Node node,
java.lang.String attributeName,
java.lang.String attributeValue)
Searches for children that have the given attribute
|
protected static org.w3c.dom.Node |
getChildByName(org.w3c.dom.Node node,
java.lang.String name)
Searches (recursively) for the first child that has the given name
|
protected static org.w3c.dom.Node |
getChildByNameAndAttribute(org.w3c.dom.Node node,
java.lang.String name,
java.lang.String attributeName,
java.lang.String attributeValue)
Searches for children that have the given name and attribute
|
protected static java.util.List<org.w3c.dom.Node> |
getChildrenByName(org.w3c.dom.Node node,
java.lang.String name)
Searches for all immediate children with the given name
|
static org.w3c.dom.Document |
readDocument(java.io.File f)
Constructs one Document from an XML file
|
protected static org.w3c.dom.Node getChildByName(org.w3c.dom.Node node, java.lang.String name)
protected static java.util.List<org.w3c.dom.Node> getChildrenByName(org.w3c.dom.Node node, java.lang.String name)
protected static org.w3c.dom.Node getChildByAttribute(org.w3c.dom.Node node, java.lang.String attributeName, java.lang.String attributeValue)
protected static org.w3c.dom.Node getChildByNameAndAttribute(org.w3c.dom.Node node, java.lang.String name, java.lang.String attributeName, java.lang.String attributeValue)
public static java.lang.String getAttributeValue(org.w3c.dom.Node node, java.lang.String attributeName)
public static org.w3c.dom.Document readDocument(java.io.File f) throws java.io.IOException, org.xml.sax.SAXException, javax.xml.parsers.ParserConfigurationException
java.io.IOException
org.xml.sax.SAXException
javax.xml.parsers.ParserConfigurationException