Hi, I'm Ask INFA!
What would you like to know?
ASK INFAPreview
Please to access Ask INFA.

Table of Contents

Search

  1. Preface
  2. Understanding Data Types and Field Properties
  3. Designing Processes
  4. Using and Displaying Data
  5. Designing Guides
  6. Designing Process Objects
  7. Designing Service Connectors
  8. Using App Connections
  9. System Services, Listeners and Connectors
  10. Designing Human Tasks

Design

Design

node-name

node-name

The node-name function in XQuery returns the QName of the node, which includes the namespace prefix and local name as an
xs:QName
value. It is used to obtain the qualified name of element or attribute nodes.

Syntax

fn:node-name(arg)
The following table describes the argument for this command:
Argument
Required/Optional
Description
arg
Optional
The node whose QName is returned. If omitted, the context item is used.

Return Value

  • Returns the
    xs:QName
    representing the node’s name including namespace, if any.
  • Returns the empty sequence if the input is an empty sequence or if the node has no name, for example, text nodes.
  • Raises an error if no argument is provided and the context item is not a node.

Examples

The following table lists some sample values and return values:
SAMPLE FUNCTION
OUTPUT
fn:node-name(<a:book xmlns:a="http://example.com"/>)
QName("{http://example.com}book")
fn:node-name(text{"Hello"})
()
fn:node-name(())
()
fn:node-name()
(with context node
<ex:item/>
)
QName corresponding to context node

Additional information

  • Applicable primarily to element and attribute nodes.
  • For nodes that do not have a QName, such as text, comment, or processing-instruction, returns empty sequence.
  • It is useful for introspecting the qualified name of nodes programmatically.

0 COMMENTS

We’d like to hear from you!