public class FleetingElementNode extends FleetingParentNode
root
IS_DTD_TYPE, IS_NILLED
Constructor and Description |
---|
FleetingElementNode(NodeName name,
SchemaType type) |
FleetingElementNode(NodeName name,
SchemaType type,
AttributeMap attributes,
NamespaceMap namespaces) |
Modifier and Type | Method and Description |
---|---|
int |
compareAttributeOrder(NodeName one,
NodeName two) |
void |
copy(Receiver out,
int copyOptions,
Location locationId)
Copy this node to a given Receiver.
|
NamespaceMap |
getAllNamespaces()
Get all the namespace bindings that are in-scope for this element.
|
int |
getAttributeIndex(java.lang.String uri,
java.lang.String local)
Get the index position of an attribute with given local name and fingerprint
|
AttributeMap |
getAttributes()
Get the attributes defined on this element
|
java.lang.String |
getAttributeValue(java.lang.String uri,
java.lang.String local)
Get the string value of a given attribute of this node
|
NamespaceMap |
getInScopeNamespaces()
Get all in-scope namespaces defined on this element.
|
int |
getNamespaceNodeIndex(java.lang.String prefix)
Get the index position of a namespace node with given local name (=prefix
|
AxisIterator |
iterateAxis(int axisNumber,
java.util.function.Predicate<? super NodeInfo> nodeTest)
Return an iteration over all the nodes reached by the given axis from this node
that match a given NodeTest
|
void |
notify(Receiver out)
Notify the event to a Receiver
|
void |
setAttributes(AttributeMap attributes)
Set the attributes that appear on this element
|
void |
setNamespaceMap(NamespaceMap namespaces)
Set the in-scope namespaces for this element
|
hasChildNodes, setHasChildren
atomize, compareOrder, equals, generateId, getBaseURI, getConfiguration, getDeclaredNamespaces, getDepth, getDisplayName, getFingerprint, getLocalPart, getNamePool, getNodeKind, getNodeName, getNodeNumber, getParent, getPrefix, getRoot, getSchemaType, getStringValue, getStringValueCS, getSystemId, getTreeInfo, getURI, hasFingerprint, head, isStreamed, saveLocation, setNodeKind, setNodeName, setParent, setStringValue, setSystemId, setTypeAnnotation
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
attributes, children, children, getColumnNumber, getGenre, getLineNumber, getPublicId, hashCode, isId, isIdref, isNilled, isSameNodeInfo, iterateAxis, toShortString
getLength, itemAt, iterate, reduce, subsequence, toGroundedValue
asIterable, concatenate, containsNode, effectiveBooleanValue, materialize
makeRepeatable
public FleetingElementNode(NodeName name, SchemaType type)
public FleetingElementNode(NodeName name, SchemaType type, AttributeMap attributes, NamespaceMap namespaces)
public void setNamespaceMap(NamespaceMap namespaces)
namespaces
- the in-scope namespaces. This includes all namespace bindings that are
in scope, not just the local namespace declarationspublic NamespaceMap getAllNamespaces()
FleetingNode
For an element return all the prefix-to-uri bindings that are in scope. This may include a binding to the default namespace (represented by a prefix of ""). It will never include "undeclarations" - that is, the namespace URI will never be empty; the effect of an undeclaration is to remove a binding from the in-scope namespaces, not to add anything.
For a node other than an element, returns null.
getAllNamespaces
in interface NodeInfo
getAllNamespaces
in class FleetingNode
public void setAttributes(AttributeMap attributes)
attributes
- the element's attributespublic void copy(Receiver out, int copyOptions, Location locationId) throws XPathException
This method is primarily for internal use. It should not be considered a stable part of the Saxon API.
out
- the Receiver to which the node should be copied. It is the caller's
responsibility to ensure that this Receiver is open before the method is called
(or that it is self-opening), and that it is closed after use.copyOptions
- a selection of the options defined in CopyOptions
locationId
- If non-zero, identifies the location of the instruction
that requested this copy. If zero, indicates that the location information
for the original node is to be copied; in this case the Receiver must bejava.lang.UnsupportedOperationException
- (always)XPathException
- if any downstream error occurspublic AxisIterator iterateAxis(int axisNumber, java.util.function.Predicate<? super NodeInfo> nodeTest)
iterateAxis
in interface NodeInfo
iterateAxis
in class FleetingNode
axisNumber
- an integer identifying the axis; one of the constants
defined in class AxisInfo
nodeTest
- A condition to be satisfied by the returned nodes; nodes
that do not satisfy this condition are not included in the resultjava.lang.UnsupportedOperationException
- if the namespace axis is
requested and this axis is not supported for this implementation.AxisInfo
public AttributeMap getAttributes()
public NamespaceMap getInScopeNamespaces()
getInScopeNamespaces
in class FleetingNode
NamespaceMap
containing all the in-scope namespaces for an element (not just
those declared locally on the element itself). Returns null if the node is
not an element.public java.lang.String getAttributeValue(java.lang.String uri, java.lang.String local)
getAttributeValue
in interface NodeInfo
getAttributeValue
in class FleetingNode
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 int getAttributeIndex(java.lang.String uri, java.lang.String local)
public int getNamespaceNodeIndex(java.lang.String prefix)
public void notify(Receiver out) throws XPathException
notify
in class FleetingParentNode
out
- the receiver to be notifiedXPathException
Copyright (c) 2004-2020 Saxonica Limited. All rights reserved.