2.3.0 - add CompleteZoneManager, zonedbc to extend timezone year range to [0001,10000)
Major Changes in v2.3: Add CompleteZoneProcessor, CompleteZoneManager,
and the zonedbc database to support all timezones, for all transitions defined
in the IANA TZ database ([1844,2087]), and extending the validity of timezone
calculations from [2000,10000) to [0001,10000).
Migration: MIGRATING.md
Changelog
- 2.3.0 (2023-06-27, TZDB version 2023c)
- Create CustomZoneRegistry example
to illustrate how to use a custom registry. - Update
BasicZoneManagerto detect gaps.- Allows
AceTimeValidation/validationtests to pass. - Still not able to distinguish between exact and overlap though.
- Allows
- Allow multi-character
ZoneRule.letterinBasicZoneProcessor.- Regenerate
zonedbwhich enables 2 more zones:/Africa/Windhoek,
andAmerica/Belize - Increases
zonedbby 150-200 bytes.
- Regenerate
- Rename
BrokerFactorytoZoneInfoStorefor better self-documentation.- This is an internal implementation detail. Downstream clients should
not be affected.
- This is an internal implementation detail. Downstream clients should
ZoneContext- Move
ZoneContext,letters[],fragments[]into PROGMEM. - Move
zonedbXxx::kTzDatabaseVersionstring into PROGMEM, and change
type toconst __FlashString*. - Create
ZoneContextBrokeraroundZoneContext, for consistency
with all other zoneinfo data structures. MergeZoneContext.hinto
ZoneInfo.h. - Add
startYearAccurateanduntilYearAccuratetoZoneContextwhich
define the interval of accurate transitions. - Saves around 150-200 bytes of RAM on AVR processors,
200-350 bytes of RAM on ESP8266.
- Move
- Cleanly separate zoneinfo storage classes from their brokers classes.
- Three storage implementations instead of one:
zoneinfolow,
zoneinfomid,zoneinfohigh, supporting low, middle, and high time
resolutions. zoneinfohighwas created to supportCompleteZoneProcessor,
CompleteZoneManagerand thezonedbcdatabase.zoneinfomidinitially used inExtendedZoneProcessor, but now
unused.- Merge
zoneinfo/ZonePolicy.hintozoneinfo/ZoneInfo.h. - Convert structs in
zoneinfo/ZoneInfo.incinto templates, with
synthetictypename Sselector. MergeZoneInfo.incinto
ZoneInfo.h.
- Three storage implementations instead of one:
- Support timezones before 1972 using
CompleteZoneManager,
CompleteZoneProcessor, andzonedbcdatabase- Before standardizing on UTC around 1970, many timezones had local
times offsets from UTC which require one-second resolution instead of
one-minute resolution. This requires changing many internal variables
fromint16_ttoint32_t. - Change
TimeOffsetto support one-second resolution usingint32_t. - Rename
BasicZone::stdOffseMinutes()toBasicZone::stdOffset()
which returns aTimeOffsetobject. - Rename
ExtendedZone::stdOffseMinutes()to
ExtendedZone::stdOffset()which returns aTimeOffsetobject. - Leave
BasicZoneProcessorusing one-minute resolution because its
algorithm has an inherent limitations which cannot handle many
timezones before 1972, so no need to convertint16_ttoint32_t
fields. - Add
CompleteZoneManager,CompleteZoneProcessor,
CompleteZoneProcessorCache,CompleteZone - Add
zonedbcdatabase which is valid from[1800,10000), which
includes all transitions in the TZDB since the first transition is
1844. - Add
scope=completeto access thezonedbcdatabase.
- Before standardizing on UTC around 1970, many timezones had local
- Zone Processor with graceful degradation
- Remove range checks against
ZoneContext.startYear()and
ZoneContext.untilYear() - Replace with
LocalDate::kMinYearandLocalDate::kMaxYear, mostly
for formatting reasons (prevent negative
years, and years with more than 4 digits). - The zone processors will always return something reasonble across the
entireint16_trange. - Only the accuracy suffers outside of the
startYearAccurate()and
untilYearAccurate()limits. - Along with v2.2 which always generates anchor rules for all zone
policies, thestartYearAccureate()anduntilYearAccurate()allows
for graceful degradation of classes likeZonedDateTimefor years
outside of this accuracy range.
- Remove range checks against
- Rename
src/tzonedb*directories- to
src/zonedb*testingfor consistency with other acetime libraries
- to
- Create CustomZoneRegistry example