|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.xpath.DOMHelper
Constructor Summary | |
DOMHelper()
|
Method Summary | |
Document |
createDocument()
Used as a helper for handling DOM issues. |
Document |
getDOMFactory()
Get the factory object required to create DOM nodes in the result tree. |
Element |
getElementByID(java.lang.String id,
Document doc)
Given an ID, return the element. |
java.lang.String |
getExpandedAttributeName(Attr attr)
Returns the attribute name with the namespace expanded. |
java.lang.String |
getExpandedElementName(Element elem)
Returns the element name with the namespace expanded. |
short |
getLevel(Node n)
**For internal use only** Get the depth level of this node in the tree (count from 1). |
java.lang.String |
getLocalNameOfNode(Node n)
Returns the local name of the given node. |
java.lang.String |
getNamespaceForPrefix(java.lang.String prefix,
Element namespaceContext)
Given a prefix and a namespace context, return the expanded namespace. |
java.lang.String |
getNamespaceOfNode(Node n)
Returns the namespace of the given node. |
static java.lang.String |
getNodeData(Node node)
Get the textual contents of the node. |
static void |
getNodeData(Node node,
FastStringBuffer buf)
Get the textual contents of the node. |
Node |
getParentOfNode(Node node)
I have to write this silly, and expensive function, because the DOM WG decided that attributes don't have parents. |
Node |
getRoot(Node node)
Deprecated. |
Node |
getRootNode(Node n)
Get the root node of the document tree, regardless of whether or not the node passed in is a document node. |
java.lang.String |
getUniqueID(Node node)
|
java.lang.String |
getUnparsedEntityURI(java.lang.String name,
Document doc)
The getUnparsedEntityURI function returns the URI of the unparsed entity with the specified name in the same document as the context node (see [3.3 Unparsed Entities]). |
boolean |
isIgnorableWhitespace(Text node)
Deprecated. |
boolean |
isNamespaceNode(Node n)
Tell if the given node is a namespace decl node. |
boolean |
isNodeAfter(Node node1,
Node node2)
Figure out if node2 should be placed after node1 in document order (returns node1 <= node2). |
void |
setDOMFactory(Document domFactory)
Get the factory object required to create DOM nodes in the result tree. |
boolean |
shouldStripSourceNode(Node textNode)
**For advanced use only** Tells, through the combination of the default-space attribute on xsl:stylesheet, xsl:strip-space, xsl:preserve-space, and the xml:space attribute, whether or not extra whitespace should be stripped from the node. |
Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public DOMHelper()
Method Detail |
public Document createDocument()
public boolean shouldStripSourceNode(Node textNode) throws SAXException
textNode
- A text node from the source tree.public java.lang.String getUniqueID(Node node)
public boolean isNodeAfter(Node node1, Node node2)
public short getLevel(Node n)
public java.lang.String getNamespaceForPrefix(java.lang.String prefix, Element namespaceContext)
public java.lang.String getNamespaceOfNode(Node n)
public java.lang.String getLocalNameOfNode(Node n)
public java.lang.String getExpandedElementName(Element elem)
public java.lang.String getExpandedAttributeName(Attr attr)
public boolean isIgnorableWhitespace(Text node)
public Node getRoot(Node node)
public Node getRootNode(Node n)
public boolean isNamespaceNode(Node n)
public Node getParentOfNode(Node node) throws java.lang.RuntimeException
public Element getElementByID(java.lang.String id, Document doc)
public java.lang.String getUnparsedEntityURI(java.lang.String name, Document doc)
public void setDOMFactory(Document domFactory)
public Document getDOMFactory()
public static java.lang.String getNodeData(Node node)
public static void getNodeData(Node node, FastStringBuffer buf)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |