Skip to main content

Module tz

Module tz 

Source
Expand description

The time zones of the vendored IANA data (spec/07 section 7.9).

The names and the rules come from vendor/tzdata, so TimeZone takes the same zones as the PostgreSQL pin and gives the same offsets. The build of PostgreSQL compiles tzdata.zi with its copy of zic and installs a file for each zone. Here zic is a port that runs when a zone is first loaded, and its result is equal to those files, byte for byte. The reader of that result is a port of localtime.c, and load is a port of pg_tzset, which also takes a POSIX zone string such as EST5EDT or <+05>-05.

Structs§

TzDatabase
The ZoneLookup of the time zone database: load.
Zone
A zone of the time zone database or of a POSIX zone string, with the name that pg_get_timezone_name gives.

Functions§

load
pg_tzset: the zone of a name of the data without regard to case, or of a POSIX zone string, or None. GMT is always the zone string, and a name that starts with : is only a name of the data.
zone_name
The name of a zone or a link as the data spells it, found without regard to case, as pg_tzset finds it.
zone_names
Every name of a zone or a link, sorted by the name in lower case.
zones
pg_tzenumerate_next: each zone of the data that Zone::acceptable takes, in the order of zone_names. The zones do not go into the cache of load.