| Extracted from Pike v7.8 release 700 at 2013-06-08.

[Top]
Calendar
Calendar.TZnames

# Module Calendar.TZnames

Description

  This module contains listnings of available timezones, in some different ways

Constant zones

  `constant Calendar.TZnames.zones = mapping(string:array(string))`

Description

  This constant is a mapping that can be used to loop over to get all the region-based timezones.

  It looks like this:

      ([ "America": ({ "Los_Angeles", "Chicago", [...] }),
         "Europe":  ({ "Stockholm", [...] }),
         [...] }),

  Please note that loading all the timezones can take some time, since they are generated and compiled on the fly.

Constant abbr2zones

  `constant Calendar.TZnames.abbr2zones = mapping(string:array(string))`

Description

  This mapping is used to look up abbreviation to the possible regional zones.

  It looks like this:

      ([ "CET": ({ "Europe/Stockholm", [...] }),
         "CST": ({ "America/Chicago", "Australia/Adelaide", [...] }),
         [...] }),

  Note this: Just because it's noted "CST" doesn't mean it's a unique timezone. There is about 7 *different* timezones that uses "CST" as abbreviation; not at the same time, though, so the DWIM routines checks this before it's satisfied. Same with some other timezones.

  For most timezones, there is a number of region timezones that for the given time are equal. This is because region timezones include rules about local summer time shifts and possible historic shifts.

  The YMD.parse functions can handle timezone abbreviations by guessing.