MarkLogic Server 11.0 Product Documentation
xdmp.nodeKind

xdmp.nodeKind(
   node as Node
) as String

Summary

Returns an String representing the node's kind: either "document", "element", "attribute", "text", "namespace", "processing-instruction", "binary", or "comment".

The fn:node-kind builtin was dropped from the final XQuery 1.0 spec. This is the equivalent function in the xdmp. namespace carried over for MarkLogic 1.0 dialects.

Parameters
node The node whose kind is to be returned.

Example

var x = {hello: "goodbye"};
xdmp.nodeKind(x);

=> object
Powered by MarkLogic Server | Terms of Use | Privacy Policy