saxon:current-mode-name

Returns the name of the current mode.

current-mode-name() ➔ xs:QName?

There are no arguments

Result

xs:QName?

Namespace

http://saxon.sf.net/

Notes on the Saxon implementation

Available since Saxon 9.3.

Details

This function, designed for use in XSLT, returns the name of the current mode. If there is no current mode, or if the current mode is the default (unnamed) mode, it returns an empty sequence.

The function is useful where a template belongs to multiple modes, in that it allows the template at run-time to determine in which mode it was activated.