Crate zoneinfo_parse [] [src]

Rust library for reading the text files comprising the zoneinfo database, which records time zone changes and offsets across the world from multiple sources.

The zoneinfo database is distributed in one of two formats: a raw text format with one file per continent, and a compiled binary format with one file per time zone. This crate deals with the former; for the latter, see the zoneinfo_compiled crate instead.

The database itself is maintained by IANA. For more information, see IANA’s page on the time zone database. You can also find the text files themselves in the tz repository.


Reading a zoneinfo text file is split into three stages:

  • Parsing individual lines of text into Lines is done by the line module;
  • Interpreting these lines into a complete Table is done by the table module;
  • Calculating transitions from this table is done by the transitions module.



Parsing zoneinfo data files, line-by-line.


Determining the structure of a set of ruleset names.


Collecting parsed zoneinfo data lines into a set of time zone data.


Generating timespan sets from a built Table.