com.icl.saxon.om
public interface NodeInfo extends Source
This is the top class in the interface hierarchy for nodes; see NodeImpl for the implementation hierarchy.
Field Summary | |
---|---|
static short | ATTRIBUTE |
static short | COMMENT |
static short | ELEMENT |
static short | NAMESPACE |
static short | NODE |
static short | NONE |
static short | NUMBER_OF_TYPES |
static short | PI |
static short | ROOT |
static short | TEXT |
Method Summary | |
---|---|
int | compareOrder(NodeInfo other)
Determine the relative position of this node and another node, in document order.
|
void | copy(Outputter out)
Copy this node to a given outputter |
void | copyStringValue(Outputter out)
Copy the string-value of this node to a given outputter |
String | generateId()
Get a character string that uniquely identifies this node. Note: a.isSameNode(b) if and only if generateId(a)==generateId(b) |
String | getAttributeValue(String uri, String localName)
Find the value of a given attribute of this node. |
String | getAttributeValue(int fingerprint)
Get the 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. |
String | getDisplayName()
Get the display name of this node. |
DocumentInfo | getDocumentRoot()
Get the root (document) node |
AxisEnumeration | getEnumeration(byte axisNumber, NodeTest nodeTest)
Return an enumeration over the nodes reached by the given axis from this node |
int | getFingerprint()
Get fingerprint. |
int | getLineNumber()
Get line number |
String | getLocalName()
Get the local part of the name of this node. |
int | getNameCode()
Get name code. |
short | getNodeType()
Return the type of node. |
NodeInfo | getParent()
Get the NodeInfo object representing the parent of this node |
String | getPrefix()
Get the prefix part of the name of this node. |
String | getStringValue()
Return the string value of the node. |
String | getSystemId()
Get the System ID for the node. |
String | getURI()
Get the URI part of the name of this node. |
boolean | hasChildNodes()
Determine whether the node has any children. |
boolean | isSameNodeInfo(NodeInfo other)
Determine whether this is the same node as another node. |
void | outputNamespaceNodes(Outputter out, boolean includeAncestors)
Output all namespace nodes associated with this element. |
Parameters: other The other node, whose position is to be compared with this node
Returns: -1 if this node precedes the other node, +1 if it follows the other node, or 0 if they are the same node. (In this case, isSameNode() will always return true, and the two nodes will produce the same result for generateId())
Returns: a string that uniquely identifies this node, within this document. The calling code prepends information to make the result unique across all documents.
Parameters: uri the namespace uri of an attribute ("" if no namespace) localName the local name of the attribute
Returns: the value of the attribute, if it exists, otherwise null
Parameters: fingerprint The fingerprint of the attribute name
Returns: the attribute value if it exists or null if not
Returns: The display name of this node. For a node with no name, return an empty string.
Returns: the DocumentInfo representing the containing document
Parameters: axisNumber the axis to be followed (a constant in class Axis) nodeTest A pattern to be matched by the returned nodes
Returns: a NodeEnumeration that scans the nodes reached by the axis in turn.
Returns: the line number of the node in its original source document; or -1 if not available
Returns: the local part of the name. For an unnamed node, return an empty string.
See Also: allocate
getFingerprint
Returns: one of the values Node.ELEMENT, Node.TEXT, Node.ATTRIBUTE, etc.
Returns: the prefix part of the name. For an unnamed node, return an empty string.
Returns: the string value of the node
Returns: the System Identifier of the entity in the source document containing the node, or null if not known. Note this is not the same as the base URI: the base URI can be modified by xml:base, but the system ID cannot.
Returns: The URI of the namespace of this node. For an unnamed node, return null. For a node with an empty prefix, return an empty string.
Returns: true if this Node object and the supplied Node object represent the same node in the tree.
Parameters: out The relevant outputter includeAncestors True if namespaces declared on ancestor elements must be output; false if it is known that these are already on the result tree