fn:boolean

Obtains the effective boolean value of the supplied argument. The result is true if the argument value is a sequence starting with a node, or the singleton boolean true(), a singleton non-zero number, or a singleton non-zero-length string (or untypedAtomic). The result is false if the argument is an empty sequence, the singleton boolean false(), a singleton number zero or NaN, or a singleton zero-length string (or untypedAtomic). In all other cases the result is an error.

boolean($arg as item()*) ➔ xs:boolean

Arguments

 

$arg

item()*

The sequence whose effective boolean value is required

Result

xs:boolean

Namespace

http://www.w3.org/2005/xpath-functions

Links to W3C specifications

XPath 2.0 Functions and Operators

XPath 3.0 Functions and Operators

XPath 3.1 Functions and Operators