|
| DOMElement (XPath xpath, Element element) |
|
Element | getW3CElement () |
|
String | getElementName () |
|
String | getContent () |
|
DOMElement< CHILD, PARENT > | setContent (String content) |
|
String | getAttribute (String attribute) |
|
DOMElement | setAttribute (String attribute, String value) |
|
PARENT | getParent () |
|
CHILD[] | getChildren () |
|
CHILD[] | getChildren (String name) |
|
CHILD | getRequiredChild (String name) throws ParserException |
|
CHILD[] | findChildren (String name) |
|
CHILD | findChildWithIdentifier (final String id) |
|
CHILD | getFirstChild (String name) |
|
CHILD | createChild (String name) |
|
CHILD | createChild (String name, String namespaceURI) |
|
CHILD | appendChild (CHILD el, boolean copy) |
|
CHILD | replaceChild (CHILD original, CHILD replacement, boolean copy) |
|
void | replaceEqualChild (DOMElement source, String identifier) |
|
void | removeChild (CHILD el) |
|
void | removeChildren () |
|
String | toSimpleXMLString () |
|
String | toString () |
|
XPath | getXpath () |
|
Collection< PARENT > | getXPathParentElements (Builder< CHILD > builder, String expr) |
|
Collection< CHILD > | getXPathChildElements (Builder< CHILD > builder, String expr) |
|
PARENT | getXPathParentElement (Builder< PARENT > builder, String expr) |
|
CHILD | getXPathChildElement (Builder< CHILD > builder, String expr) |
|
Collection | getXPathElements (Builder builder, String expr) |
|
String | getXPathString (XPath xpath, String expr) |
|
Object | getXPathResult (String expr, QName result) |
|
Object | getXPathResult (Node context, String expr, QName result) |
|
Wraps a W3C element.
Using XPath for simple queries like "get all children with attribute value X" is actually slower than iterating with the W3C API. We still use XPath because there is a small chance that the authors of the XML implementation in the JDK will not get forced by Larry to fix their ugly code and APIs. Yes, it' s unlikely but one can dream...
- Author
- Christian Bauer