Companion

object Companion

Properties

Link copied to clipboard
const val BEHAB: Int = 37

The Monday, Thursday and Monday after the first Shabbos after Rosh Chodesh Cheshvan and Iyar) are BeHab days. This constant is not actively in use.

Link copied to clipboard
const val CHANUKAH: Int = 21

The holiday of Chanukah. 8 days starting on the 25th day Kislev.

Link copied to clipboard
const val CHOL_HAMOED_PESACH: Int = 2

Chol Hamoed (interim days) of Pesach (Passover)

Link copied to clipboard
const val CHOL_HAMOED_SUCCOS: Int = 16

Chol Hamoed (interim days) of Succos/Sukkos (Tabernacles)

Link copied to clipboard
const val EREV_PESACH: Int = 0

The 14th day of Nissan, the day before of Pesach (Passover).

Link copied to clipboard
const val EREV_ROSH_HASHANA: Int = 9

Erev Rosh Hashana (the day before Rosh Hashana), the 29th of Elul

Link copied to clipboard
const val EREV_SHAVUOS: Int = 4

Erev Shavuos (the day before Shavuos), the 5th of Sivan

Link copied to clipboard
const val EREV_SUCCOS: Int = 14

The 14th day of Tishrei, the day before of Succos/Sukkos (Tabernacles).

Link copied to clipboard
const val EREV_YOM_KIPPUR: Int = 12

The 9th day of Tishrei, the day before of Yom Kippur.

Link copied to clipboard
const val FAST_OF_ESTHER: Int = 24

The fast of Esther, usually on the 13th day of Adar (or Adar II on leap years). It is earlier on some years.

Link copied to clipboard
const val FAST_OF_GEDALYAH: Int = 11

The fast of Gedalyah, the 3rd of Tishrei.

Link copied to clipboard
const val FRIDAY: Int = 6

Value of the .DAY_OF_WEEK field indicating Friday.

Link copied to clipboard
const val HOSHANA_RABBA: Int = 17

Hoshana Rabba, the 7th day of Succos/Sukkos that occurs on the 21st of Tishrei.

Link copied to clipboard
const val ISRU_CHAG: Int = 35

The day following the last day of Pesach, Shavuos and Sukkos.

Link copied to clipboard
const val LAG_BAOMER: Int = 33

The 33rd day of the Omer, the 18th of Iyar, a minor holiday.

Link copied to clipboard
const val MONDAY: Int = 2

Value of the .DAY_OF_WEEK field indicating Monday.

Link copied to clipboard
const val NO_HOLIDAY: Int

value returned by yomTovIndex to indicate no holiday.

Link copied to clipboard

An array of parshiyos in the 17 possible combinations.

Link copied to clipboard
const val PESACH: Int = 1

The holiday of Pesach (Passover) on the 15th (and 16th out of Israel) day of Nissan.

Link copied to clipboard
const val PESACH_SHENI: Int = 3

Pesach Sheni, the 14th day of Iyar, a minor holiday.

Link copied to clipboard
const val PURIM: Int = 25

The holiday of Purim on the 14th day of Adar (or Adar II on leap years).

Link copied to clipboard
const val PURIM_KATAN: Int = 27

The holiday of Purim Katan on the 14th day of Adar I on a leap year when Purim is on Adar II, a minor holiday.

Link copied to clipboard
const val ROSH_CHODESH: Int = 28

Rosh Chodesh, the new moon on the first day of the Jewish month, and the 30th day of the previous month in the case of a month with 30 days.

Link copied to clipboard
const val ROSH_HASHANA: Int = 10

Rosh Hashana, the first of Tishrei.

Link copied to clipboard
const val SATURDAY: Int = 7

Value of the .DAY_OF_WEEK field indicating Saturday.

Link copied to clipboard
const val SEVENTEEN_OF_TAMMUZ: Int = 6

The fast of the 17th day of Tamuz

Link copied to clipboard
const val SHAVUOS: Int = 5

Shavuos (Pentecost), the 6th of Sivan

Link copied to clipboard
const val SHEMINI_ATZERES: Int = 18

Shmini Atzeres, the 8th day of Succos/Sukkos is an independent holiday that occurs on the 22nd of Tishrei.

Link copied to clipboard
const val SHUSHAN_PURIM: Int = 26

The holiday of Shushan Purim on the 15th day of Adar (or Adar II on leap years).

Link copied to clipboard
const val SHUSHAN_PURIM_KATAN: Int = 34

The holiday of Purim Katan on the 15th day of Adar I on a leap year when Purim is on Adar II, a minor holiday.

Link copied to clipboard
const val SIMCHAS_TORAH: Int = 19

Simchas Torah, the 9th day of Succos/Sukkos, or the second day of Shmini Atzeres that is celebrated .getInIsrael on the 23rd of Tishrei.

Link copied to clipboard
const val SUCCOS: Int = 15

The holiday of Succos/Sukkos (Tabernacles), the 15th (and 16th out of Israel) day of Tishrei

Link copied to clipboard
const val SUNDAY: Int = 1

Value of the .DAY_OF_WEEK field indicating Sunday.

Link copied to clipboard
const val TENTH_OF_TEVES: Int = 22

The fast of the 10th day of Teves.

Link copied to clipboard
const val THURSDAY: Int = 5

Value of the .DAY_OF_WEEK field indicating Thursday.

Link copied to clipboard
const val TISHA_BEAV: Int = 7

The fast of the 9th of Av

Link copied to clipboard
const val TU_BEAV: Int = 8

The 15th day of Av, a minor holiday

Link copied to clipboard
const val TU_BESHVAT: Int = 23

Tu Bishvat on the 15th day of Shevat, a minor holiday.

Link copied to clipboard
const val TUESDAY: Int = 3

Value of the .DAY_OF_WEEK field indicating Tuesday.

Link copied to clipboard
const val WEDNESDAY: Int = 4

Value of the .DAY_OF_WEEK field indicating Wednesday.

Link copied to clipboard
const val YOM_HAATZMAUT: Int = 31

Yom Ha'atzmaut, Israel Independence Day, the 5th of Iyar, but if it occurs on a Friday or Saturday, the holiday is moved back to Thursday, the 3rd of 4th of Iyar, and if it falls on a Monday, it is moved forward to Tuesday the 6th of Iyar. A .isUseModernHolidays.

Link copied to clipboard
const val YOM_HASHOAH: Int = 29

Yom HaShoah, Holocaust Remembrance Day, usually held on the 27th of Nissan. If it falls on a Friday, it is moved to the 26th, and if it falls on a Sunday it is moved to the 28th. A .isUseModernHolidays.

Link copied to clipboard
const val YOM_HAZIKARON: Int = 30

Yom HaZikaron, Israeli Memorial Day, held a day before Yom Ha'atzmaut. A .isUseModernHolidays.

Link copied to clipboard
const val YOM_KIPPUR: Int = 13

The holiday of Yom Kippur, the 10th day of Tishrei

Link copied to clipboard
const val YOM_KIPPUR_KATAN: Int = 36

The day before Rosh Chodesh (moved to Thursday if Rosh Chodesh is on a Friday or Shabbos) in most months. This constant is not actively in use.

Link copied to clipboard
const val YOM_YERUSHALAYIM: Int = 32

Yom Yerushalayim or Jerusalem Day, on 28 Iyar. A .isUseModernHolidays.

Functions

Link copied to clipboard
fun DayOfWeek.toJewishDayOfWeek(): Int

kotlinx.datetime.DayOfWeek is ordered according to ISO-8601, where Monday is 1 and Sunday is 7. java.util.Calendar's day of week constants are ordered with Sunday is 1 and Saturday is 7. This function converts between the two. It is called toJewishDayOfWeek because the Torah describes Saturday as the 7th day. Note: The caller should prefer to compare DayOfWeeks directly, instead of converting to day numbers. This is to improve readability and possible future-proofing.