IranianHijri constructor
- Map<
(int, int), PersianDate> monthStarts = const {},
Creates the calendar. monthStarts maps a Hijri (year, month) to
the Jalali day it starts on, for months where an announcement differs
from the calculation; it wins over everything else.
Implementation
IranianHijri({Map<(int, int), PersianDate> monthStarts = const {}})
: monthStarts = Map.unmodifiable(monthStarts),
_corrections = {
for (final MapEntry(key: (year, month), :value)
in monthStarts.entries)
year * 12 + month - 1: j2d(value.year, value.month, value.day),
};