|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.compass.core.xml.jdom.JDomXmlObject
public class JDomXmlObject
A dom4j (http://www.dom4j.org) implementation of XmlObject.
| Constructor Summary | |
|---|---|
JDomXmlObject(org.jdom.Attribute attribute)
Constructs a new xml object based on a JDMO Attribute. |
|
JDomXmlObject(org.jdom.Attribute attribute,
Map<String,String> namespaces)
|
|
JDomXmlObject(org.jdom.Document document)
|
|
JDomXmlObject(org.jdom.Document document,
Map<String,String> namespaces)
|
|
JDomXmlObject(org.jdom.Element element)
Constructs a new xml object based on a JDMO Element. |
|
JDomXmlObject(org.jdom.Element element,
Map<String,String> namespaces)
|
|
| Method Summary | |
|---|---|
boolean |
canCompileXpath()
Return true since JDOM supports xml compilation. |
XmlXPathExpression |
compile(String path)
Compiles the given xpath expression using JDMO XPath.newInstance(). |
org.jdom.Attribute |
getAttribute()
Returns the JDMO Attribute. |
org.jdom.Element |
getElement()
Returns the JDMO Element. |
String |
getName()
Returns the JDOM node name. |
Map<String,String> |
getNamespaces()
Returns a lookup map for namespaces (prefix to uri). |
String |
getValue()
Returns the JDOM node text. |
XmlObject[] |
selectPath(String path)
Returns a list of xml objects matching the given xpath expression. |
void |
setNamespaces(Map<String,String> namespaces)
Sets a lookup map for given namespaces (prefix to uri). |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JDomXmlObject(org.jdom.Document document)
public JDomXmlObject(org.jdom.Document document,
Map<String,String> namespaces)
public JDomXmlObject(org.jdom.Element element)
Element.
public JDomXmlObject(org.jdom.Element element,
Map<String,String> namespaces)
public JDomXmlObject(org.jdom.Attribute attribute)
Attribute.
public JDomXmlObject(org.jdom.Attribute attribute,
Map<String,String> namespaces)
| Method Detail |
|---|
public void setNamespaces(Map<String,String> namespaces)
XmlObject
setNamespaces in interface XmlObjectpublic Map<String,String> getNamespaces()
XmlObject
getNamespaces in interface XmlObjectpublic String getName()
getName in interface XmlObjectpublic String getValue()
getValue in interface XmlObject
public XmlObject[] selectPath(String path)
throws Exception
XmlObject
selectPath in interface XmlObjectpath - The xpath expression
Exceptionpublic boolean canCompileXpath()
true since JDOM supports xml compilation.
canCompileXpath in interface XmlObject
public XmlXPathExpression compile(String path)
throws org.jdom.JDOMException
XPath.newInstance().
compile in interface XmlObjectpath - The xpath expression
org.jdom.JDOMExceptionpublic org.jdom.Element getElement()
public org.jdom.Attribute getAttribute()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||