A few Swift functions for converting Jalaali (Jalali, Persian, Khayyami, Khorshidi, Shamsi) and Gregorian calendar systems to each other.
Jalali calendar is a solar calendar that was used in Persia, variants of which today are still in use in Iran as well as Afghanistan. Read more on Wikipedia or see Calendar Converter.
Calendar conversion is based on the algorithm provided by Kazimierz M. Borkowski and has a very good performance.
Use Carthage to build and install.
Converts a Gregorian date to Jalaali.
Converts a Jalaali date to Gregorian.
Checks whether a Jalaali date is valid or not.
Is this a leap year or not?
Number of days in a given month in a Jalaali year.
A tuple for a Jalaali date.
A tuple for a Gregorian date.
An Int representing a Jalaali year.
An Int representing a Jalaali month (1-based).
An Int representing a Jalaali day.
An Int representing a Gregorian year.
An Int representing a Gregorian month (1-based).
An Int representing a Gregorian day.
An Int representing a Julian Day Number
MIT