Package net.sf.saxon.om
Class AbsolutePath
java.lang.Object
net.sf.saxon.om.AbsolutePath
Represents the path from the root of an XDM tree to a specific node, as a sequence of (name, position) pairs
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classInner class representing one step in the path -
Constructor Summary
ConstructorsConstructorDescriptionCreate an absolute path given a list of path elements -
Method Summary
Modifier and TypeMethodDescriptionvoidappendAttributeName(NodeName attributeName) Append an attribute name to the pathbooleanGet the path as a list ofAbsolutePath.PathElementobjectsGet a string representing the path using abbreviated namespace URIs to represent QNamesGet a string representing the path using namespace prefixes to represent QNamesGet a string representing the path using namespace URIs to represent QNamesinthashCode()static AbsolutePathpathToNode(NodeInfo node) Create an absolute path given a NodevoidsetSystemId(String systemId) toString()
-
Constructor Details
-
AbsolutePath
Create an absolute path given a list of path elements- Parameters:
path- the list of path elements, starting from the root. It is not necessary to include a path element for the document node.
-
-
Method Details
-
appendAttributeName
Append an attribute name to the path- Parameters:
attributeName- the name of the attribute
-
pathToNode
Create an absolute path given a Node- Parameters:
node- the node whose path is required- Returns:
- the absolute path
-
getPathUsingPrefixes
Get a string representing the path using namespace prefixes to represent QNames- Returns:
- the path in the form
/prefix:local[n]/prefix:local[m]/...
-
getPathUsingUris
Get a string representing the path using namespace URIs to represent QNames- Returns:
- the path in the form
/Q{uri}local[n]/Q{uri}local[m]/...
-
getPathUsingAbbreviatedUris
Get a string representing the path using abbreviated namespace URIs to represent QNames- Returns:
- the path in the form
/Q{uri}local[n]/Q{uri}local[m]/..., with the URIs shortened
-
toString
-
equals
-
hashCode
public int hashCode() -
setSystemId
-
getSystemId
-
getPathElements
Get the path as a list ofAbsolutePath.PathElementobjects- Returns:
- a list of PathElements giving the names and positions of ancestor elements of the invalid element, starting at the root.
-