TDcal::timezone(3) | FreeBSD Library Functions Manual | TDcal::timezone(3) |
TDcal::timezone
—
use TDcal::timezone;
$tz =
tzmstoolson
($tzms);
$tz =
tzname
();
$tz =
tzvalid
($tz);
TDcal::timezone
provides support functions for timezone
lookup, name validation and name conversion.
In these functions, all $tz arguments and
return values have the form of a string containing an Olson standard
timezone name such as:
‘America/New_York
’,
‘Europe/Paris
’ or
‘Asia/Bangkok
’, etc.
tzmstoolson
() is used to convert the wild
and wonderful timezone names often received from Microsoft calendar users
into standard Olson timezone names.
tzname
() returns the system timezone name.
This is determined by examining in order:
TZ
environment variable.TZ=
’ variable in the
/etc/TIMEZONE file.Names found are validated to ensure they exist in the zoneinfo
database and are skipped if they do not. tzname
()
returns ‘undef
’ if no valid timezone
name can be identified.
tzvalid
() is used to validate that a
timezone name exists in the zoneinfo database. It returns the input value if
valid, else ‘undef
’.
TDcal::timezone
:
TZ
December 3, 2022 | FreeBSD 13.1-RELEASE-p3 |