|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.calitha.xml.XMLUtil
public final class XMLUtil
The XMLUtil class provides several convenience methods to work with XML and related documents.
| Method Summary | |
|---|---|
static Element |
getChildElement(Element parent)
Gets the first child element. |
static Element |
getChildElement(Element parent,
String tagName)
Gets the first child element with a specified tag name |
static List<Element> |
getChildElements(Element parent)
Gets all child elements. |
static List<Element> |
getChildElements(Element parent,
String tagName)
Gets the child elements. |
static Element |
getLastChildElement(Element parent)
Gets the last child element. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static List<Element> getChildElements(Element parent,
String tagName)
The child elements are selected by a specified tag name or all of them if tagName is null.
parent - element of which the children will be examinedtagName - tag name or null
IllegalArgumentException - if the parent argument is nullpublic static List<Element> getChildElements(Element parent)
parent - element of which the children will be examined
IllegalArgumentException - if the parent argument is nullpublic static Element getChildElement(Element parent)
parent - parent of which the first element will be selected
IllegalArgumentException - if the parent argument is nullpublic static Element getLastChildElement(Element parent)
parent - parent of which the last element will be selected
IllegalArgumentException - if the parent argument is null
public static Element getChildElement(Element parent,
String tagName)
parent - parent of which the element will be selectedtagName - tag name or null if the first element should be selected
IllegalArgumentException - if the parent argument is null
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||