home contribute faq download

FunctX XSLT Functions

fn:timezone-from-time

The timezone portion of a time

Google
Webdatypic.com

Description

The fn:timezone-from-time function returns the time zone of an xs:time value, offset from UTC, as an xs:dayTimeDuration value between -PT14H and PT14H. If the time zone is UTC, the value PT0S is returned.

This description is © Copyright 2007, Priscilla Walmsley. It is excerpted from the book XQuery by Priscilla Walmsley, O'Reilly, 2007. For a complete explanation of this function, please refer to Appendix A of the book.

Arguments and Return Type

NameType
$arg xs:time?
return value xs:dayTimeDuration?

Examples

XPath ExampleResults
timezone-from-time(
   xs:time('09:54:00-05:00'))
-PT5H
timezone-from-time(
   xs:time('09:54:00+05:00'))
PT5H
timezone-from-time(
   xs:time('09:54:00Z'))
PT0S
timezone-from-time(
   xs:time('09:54:00'))
()

See Also

fn:timezone-from-dateThe timezone portion of a date
fn:timezone-from-dateTimeThe timezone portion of a date/time
functx:timezone-from-durationConverts an xs:dayTimeDuration into a timezone like "-05:00" or "Z"

History

Published OnLast UpdatedContributor(s)
2006-06-272007-02-26W3C, XQuery 1.0 and XPath 2.0 Functions and Operators, http://www.w3.org/TR/xpath-functions/
Datypic XSLT Services

Recommended Reading:

XQuery