Package org.mycore.common.xml
Class MCRNodeBuilder
java.lang.Object
org.mycore.common.xml.MCRNodeBuilder
- Author:
- Frank Lützenkirchen
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuildAttribute
(String xPath, String value, Parent parent) buildElement
(String xPath, String value, Parent parent) getValueOf
(String xPath, Parent parent) Resolves the first match for the given XPath and returns its value as a Stringstatic String
Removes obsolete child:: and attribute:: axis prefixes from given XPath
-
Constructor Details
-
MCRNodeBuilder
public MCRNodeBuilder() -
MCRNodeBuilder
-
-
Method Details
-
getFirstNodeBuilt
-
buildElement
public Element buildElement(String xPath, String value, Parent parent) throws org.jaxen.JaxenException - Throws:
org.jaxen.JaxenException
-
buildAttribute
public Attribute buildAttribute(String xPath, String value, Parent parent) throws org.jaxen.JaxenException - Throws:
org.jaxen.JaxenException
-
buildNode
- Throws:
org.jaxen.JaxenException
-
getValueOf
Resolves the first match for the given XPath and returns its value as a String- Parameters:
xPath
- the XPath expressionparent
- the context element or document- Returns:
- the value of the element or attribute as a String
-
simplify
Removes obsolete child:: and attribute:: axis prefixes from given XPath
-