fn:current-time

Returns the current time.

Signature

fn:current-time() as xs:time

Properties

This function is deterministic, context-dependent, and focus-independent. It depends on implicit timezone.

Rules

Returns xs:time(fn:current-dateTime()). This is an xs:time (with timezone) that is current at some time during the evaluation of a query or transformation in which fn:current-time is executed.

This function is deterministic. The precise instant during the query or transformation represented by the value of fn:current-time() is implementation-dependent.

Notes

The returned time will always have an associated timezone, which will always be the same as the implicit timezone in the dynamic context

Examples

fn:current-time() returns an xs:time corresponding to the current time. For example, a call of fn:current-time() might return 23:17:00.000-05:00.