getLineNumber function is used to query the location of an internal/C-level
XML node within its original "file". This gives us the line number.
getNodeLocation gives both the line number and the name of the
file in which the node is located, handling XInclude files in a
top-level document and identifying the included file, as appropriate.
getNodePosition returns a simplified version of
combining the file and line number into a string and ignoring the
This is useful when we identify a node with a particular charactestic and want to view/edit the original document, e.g. when authoring an Docbook article.
the node whose location or line number is of interest
additional parameters for methods should they be defined.
a logical value that controls whether the full path of the nested includes is returned or just the path in the immediate XInclude element.
a logical value which if
getLineNumber returns an integer.
getNodeLocation returns a list with two elements -
line which are a character string
and the integer line number.
For text nodes, the line number is taken from the previous sibling nodes or the parent node.
Duncan Temple Lang
1 2 3 4