Class | TZInfo::TZDataParser |
In: |
lib/tzinfo/tzdataparser.rb
|
Parent: | Object |
Parses tzdata from elsie.nci.nih.gov/pub/ and transforms it into a set of Ruby modules that can be used through Timezone and Country.
Normally, this class wouldn‘t be used. It is only run to update the timezone data and index modules.
MIN_YEAR | = | 1800 | Minimum year that will be considered. | |
MAX_YEAR | = | 2050 | Maximum year that will be considered. |
exclude_zones | [RW] | Zones to exclude from generation when not using only_zones (set to an array containing zone identifiers). |
generate_countries | [RW] | Whether to generate country definitions (set to false to stop countries being generated). |
generate_zones | [RW] | Whether to generate zone definitions (set to false to stop zones being generated). |
only_zones | [RW] | Limit the set of zones to generate (set to an array containing zone identifiers). |
Initializes a new TZDataParser. input_dir must contain the extracted tzdata tarball. output_dir is the location to output the modules (in definitions and indexes directories).
Parses a month specified in the tz data and converts it to a number between 1 and 12 representing January to December.