public class XOMNodeWrapper extends net.sf.saxon.tree.wrapper.AbstractNodeWrapper implements net.sf.saxon.tree.wrapper.SiblingCountingNode, net.sf.saxon.tree.util.SteppingNode<XOMNodeWrapper>
Modifier and Type | Field and Description |
---|---|
protected XOMDocumentWrapper |
docWrapper |
protected int |
index |
protected nu.xom.Node |
node |
protected short |
nodeKind |
Modifier and Type | Method and Description |
---|---|
net.sf.saxon.om.AtomicSequence |
atomize()
Get the typed value.
|
int |
compareOrder(net.sf.saxon.om.NodeInfo other)
Determine the relative position of this node and another node, in
document order.
|
int |
comparePosition(net.sf.saxon.om.NodeInfo other)
Determine the relative position of this node and another node, in document order,
distinguishing whether the first node is a preceding, following, descendant, ancestor,
or the same node as the second.
|
void |
copy(net.sf.saxon.event.Receiver out,
int copyOptions,
net.sf.saxon.expr.parser.Location locationId)
Copy this node to a given outputter (deep copy)
|
boolean |
equals(Object other)
The equals() method compares nodes for identity.
|
void |
generateId(net.sf.saxon.tree.util.FastStringBuffer buffer)
Get a character string that uniquely identifies this node.
|
String |
getAttributeValue(String uri,
String local)
Get the string value of a given attribute of this node
|
String |
getBaseURI()
Get the Base URI for the node, that is, the URI used for resolving a
relative URI contained in the node.
|
int |
getColumnNumber()
Get column number
|
net.sf.saxon.Configuration |
getConfiguration()
Get the configuration
|
net.sf.saxon.om.NamespaceBinding[] |
getDeclaredNamespaces(net.sf.saxon.om.NamespaceBinding[] buffer)
Get all namespace undeclarations and undeclarations defined on this element.
|
String |
getDisplayName()
Get the display name of this node.
|
XOMNodeWrapper |
getFirstChild() |
int |
getLineNumber()
Get line number
|
String |
getLocalPart()
Get the local part of the name of this node.
|
net.sf.saxon.om.NamePool |
getNamePool()
Get the name pool for this node
|
XOMNodeWrapper |
getNextSibling() |
int |
getNodeKind()
Return the type of node.
|
XOMNodeWrapper |
getParent()
Get the NodeInfo object representing the parent of this node
|
String |
getPrefix()
Get the prefix of the name of the node.
|
XOMNodeWrapper |
getPreviousSibling() |
net.sf.saxon.om.NodeInfo |
getRoot()
Get the root node of the tree containing this node
|
net.sf.saxon.type.SchemaType |
getSchemaType()
Get the type annotation of this node, if any.
|
int |
getSiblingPosition()
Get the index position of this node among its siblings (starting from 0)
|
String |
getStringValue()
Return the string value of the node.
|
CharSequence |
getStringValueCS()
Get the value of the item as a CharSequence.
|
XOMNodeWrapper |
getSuccessorElement(XOMNodeWrapper anchor,
String uri,
String local) |
String |
getSystemId()
Get the System ID for the node.
|
Object |
getUnderlyingNode()
Get the underlying XOM node, to implement the VirtualNode interface
|
String |
getURI()
Get the URI part of the name of this node.
|
boolean |
hasChildNodes()
Determine whether the node has any children.
|
int |
hashCode()
The hashCode() method obeys the contract for hashCode(): that is, if two objects are equal
(represent the same node) then they must have the same hashCode()
|
boolean |
isId()
Determine whether this node has the is-id property
|
boolean |
isIdref()
Determine whether this node has the is-idref property
|
boolean |
isNilled()
Determine whether the node has the is-nilled property
|
boolean |
isSameNodeInfo(net.sf.saxon.om.NodeInfo other)
Determine whether this is the same node as another node.
|
net.sf.saxon.om.SequenceIterator |
iterate()
To implement
Sequence , this method returns a singleton iterator
that delivers this item in the form of a sequence |
protected net.sf.saxon.tree.iter.AxisIterator |
iterateAttributes(net.sf.saxon.pattern.NodeTest nodeTest) |
protected net.sf.saxon.tree.iter.AxisIterator |
iterateChildren(net.sf.saxon.pattern.NodeTest nodeTest) |
protected net.sf.saxon.tree.iter.AxisIterator |
iterateDescendants(net.sf.saxon.pattern.NodeTest nodeTest,
boolean includeSelf) |
protected net.sf.saxon.tree.iter.AxisIterator |
iterateSiblings(net.sf.saxon.pattern.NodeTest nodeTest,
boolean forwards) |
protected XOMNodeWrapper |
makeWrapper(nu.xom.Node node,
XOMDocumentWrapper docWrapper)
Factory method to wrap a XOM node with a wrapper that implements the
Saxon NodeInfo interface.
|
protected XOMNodeWrapper |
makeWrapper(nu.xom.Node node,
XOMDocumentWrapper docWrapper,
XOMNodeWrapper parent,
int index)
Factory method to wrap a XOM node with a wrapper that implements the
Saxon NodeInfo interface.
|
getFingerprint, getPublicId, getRealNode, getTreeInfo, hasFingerprint, head, isStreamed, iterateAxis, iterateAxis, saveLocation, setSystemId
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
getFingerprint, getPublicId, getTreeInfo, hasFingerprint, isStreamed, iterateAxis, iterateAxis
setSystemId
protected nu.xom.Node node
protected short nodeKind
protected XOMDocumentWrapper docWrapper
protected int index
protected final XOMNodeWrapper makeWrapper(nu.xom.Node node, XOMDocumentWrapper docWrapper)
node
- The XOM nodedocWrapper
- The wrapper for the Document containing this nodeprotected final XOMNodeWrapper makeWrapper(nu.xom.Node node, XOMDocumentWrapper docWrapper, XOMNodeWrapper parent, int index)
node
- The XOM nodedocWrapper
- The wrapper for the Document containing this nodeparent
- The wrapper for the parent of the XOM nodeindex
- The position of this node relative to its siblingspublic net.sf.saxon.om.SequenceIterator iterate()
Sequence
, this method returns a singleton iterator
that delivers this item in the form of a sequenceiterate
in interface net.sf.saxon.om.Sequence
iterate
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public net.sf.saxon.Configuration getConfiguration()
getConfiguration
in interface net.sf.saxon.om.NodeInfo
getConfiguration
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public Object getUnderlyingNode()
getUnderlyingNode
in interface net.sf.saxon.tree.wrapper.VirtualNode
public net.sf.saxon.om.NamePool getNamePool()
getNamePool
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public int getNodeKind()
getNodeKind
in interface net.sf.saxon.om.NodeInfo
public net.sf.saxon.om.AtomicSequence atomize()
atomize
in interface net.sf.saxon.om.Item
atomize
in interface net.sf.saxon.om.NodeInfo
atomize
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public net.sf.saxon.type.SchemaType getSchemaType()
Types derived from a DTD are not reflected in the result of this method.
getSchemaType
in interface net.sf.saxon.om.NodeInfo
getSchemaType
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public boolean isSameNodeInfo(net.sf.saxon.om.NodeInfo other)
isSameNodeInfo
in interface net.sf.saxon.om.NodeInfo
isSameNodeInfo
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public boolean equals(Object other)
equals
in interface net.sf.saxon.om.NodeInfo
equals
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
other
- the node to be compared with this nodepublic int hashCode()
hashCode
in interface net.sf.saxon.om.NodeInfo
hashCode
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public String getSystemId()
getSystemId
in interface Source
getSystemId
in interface SourceLocator
getSystemId
in interface net.sf.saxon.expr.parser.Location
getSystemId
in interface net.sf.saxon.om.NodeInfo
getSystemId
in interface Locator
getSystemId
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public String getBaseURI()
getBaseURI
in interface net.sf.saxon.om.NodeInfo
getBaseURI
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public int getLineNumber()
getLineNumber
in interface SourceLocator
getLineNumber
in interface net.sf.saxon.expr.parser.Location
getLineNumber
in interface net.sf.saxon.om.NodeInfo
getLineNumber
in interface Locator
getLineNumber
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public int getColumnNumber()
getColumnNumber
in interface SourceLocator
getColumnNumber
in interface net.sf.saxon.expr.parser.Location
getColumnNumber
in interface net.sf.saxon.om.NodeInfo
getColumnNumber
in interface Locator
getColumnNumber
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public int compareOrder(net.sf.saxon.om.NodeInfo other)
compareOrder
in interface net.sf.saxon.om.NodeInfo
other
- The other node, whose position is to be compared with this
nodepublic int comparePosition(net.sf.saxon.om.NodeInfo other)
comparePosition
in interface net.sf.saxon.om.NodeInfo
comparePosition
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
other
- The other node, whose position is to be compared with this
nodeAxisInfo.PRECEDING
if this node is on the preceding axis of the other node;
AxisInfo.FOLLOWING
if it is on the following axis; AxisInfo.ANCESTOR
if the first node is an
ancestor of the second; AxisInfo.DESCENDANT
if the first is a descendant of the second;
AxisInfo.SELF
if they are the same node.UnsupportedOperationException
- if either node is an attribute or namespacepublic String getStringValue()
getStringValue
in interface net.sf.saxon.om.Item
getStringValue
in interface net.sf.saxon.om.NodeInfo
getStringValue
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public CharSequence getStringValueCS()
getStringValueCS
in interface net.sf.saxon.om.Item
public String getLocalPart()
getLocalPart
in interface net.sf.saxon.om.NodeInfo
public String getPrefix()
getPrefix
in interface net.sf.saxon.om.NodeInfo
public String getURI()
getURI
in interface net.sf.saxon.om.NodeInfo
public String getDisplayName()
getDisplayName
in interface net.sf.saxon.om.NodeInfo
getDisplayName
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public XOMNodeWrapper getParent()
getParent
in interface net.sf.saxon.om.NodeInfo
getParent
in interface net.sf.saxon.tree.util.SteppingNode<XOMNodeWrapper>
public XOMNodeWrapper getNextSibling()
getNextSibling
in interface net.sf.saxon.tree.util.SteppingNode<XOMNodeWrapper>
public XOMNodeWrapper getPreviousSibling()
getPreviousSibling
in interface net.sf.saxon.tree.util.SteppingNode<XOMNodeWrapper>
public XOMNodeWrapper getFirstChild()
getFirstChild
in interface net.sf.saxon.tree.util.SteppingNode<XOMNodeWrapper>
public XOMNodeWrapper getSuccessorElement(XOMNodeWrapper anchor, String uri, String local)
getSuccessorElement
in interface net.sf.saxon.tree.util.SteppingNode<XOMNodeWrapper>
public int getSiblingPosition()
getSiblingPosition
in interface net.sf.saxon.tree.wrapper.SiblingCountingNode
protected net.sf.saxon.tree.iter.AxisIterator iterateAttributes(net.sf.saxon.pattern.NodeTest nodeTest)
iterateAttributes
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
protected net.sf.saxon.tree.iter.AxisIterator iterateChildren(net.sf.saxon.pattern.NodeTest nodeTest)
iterateChildren
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
protected net.sf.saxon.tree.iter.AxisIterator iterateSiblings(net.sf.saxon.pattern.NodeTest nodeTest, boolean forwards)
iterateSiblings
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
protected net.sf.saxon.tree.iter.AxisIterator iterateDescendants(net.sf.saxon.pattern.NodeTest nodeTest, boolean includeSelf)
iterateDescendants
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public String getAttributeValue(String uri, String local)
getAttributeValue
in interface net.sf.saxon.om.NodeInfo
getAttributeValue
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
uri
- the namespace URI of the attribute name. Supply the empty string for an attribute
that is in no namespacelocal
- the local part of the attribute name.public net.sf.saxon.om.NodeInfo getRoot()
getRoot
in interface net.sf.saxon.om.NodeInfo
getRoot
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public boolean hasChildNodes()
hasChildNodes
in interface net.sf.saxon.om.NodeInfo
hasChildNodes
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public void generateId(net.sf.saxon.tree.util.FastStringBuffer buffer)
generateId
in interface net.sf.saxon.om.NodeInfo
buffer
- a buffer to contain a string that uniquely identifies this node, across all documentspublic void copy(net.sf.saxon.event.Receiver out, int copyOptions, net.sf.saxon.expr.parser.Location locationId) throws net.sf.saxon.trans.XPathException
copy
in interface net.sf.saxon.om.NodeInfo
copy
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
net.sf.saxon.trans.XPathException
public net.sf.saxon.om.NamespaceBinding[] getDeclaredNamespaces(net.sf.saxon.om.NamespaceBinding[] buffer)
getDeclaredNamespaces
in interface net.sf.saxon.om.NodeInfo
getDeclaredNamespaces
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
buffer
- If this is non-null, and the result array fits in this buffer, then the result
may overwrite the contents of this array, to avoid the cost of allocating a new array on the heap.For a node other than an element, the method returns null.
public boolean isId()
isId
in interface net.sf.saxon.om.NodeInfo
isId
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public boolean isIdref()
isIdref
in interface net.sf.saxon.om.NodeInfo
isIdref
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
public boolean isNilled()
isNilled
in interface net.sf.saxon.om.NodeInfo
isNilled
in class net.sf.saxon.tree.wrapper.AbstractNodeWrapper
Copyright © 2018 JBoss by Red Hat. All rights reserved.