From 149f1d342f4dff36d0ac88c332f418b2047625d1 Mon Sep 17 00:00:00 2001 From: Moshe Dicker Date: Fri, 1 May 2026 11:43:53 -0400 Subject: [PATCH 1/7] Revert "fix RegressionTestFileWriter for recent sunrise / sunset method name changes" This reverts commit 242deaa87367c6ae06033a4775ec08b31c573166. --- .../zmanim/hebrewcalendar/RegressionTestFileWriter.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/test/java/com/kosherjava/zmanim/hebrewcalendar/RegressionTestFileWriter.java b/src/test/java/com/kosherjava/zmanim/hebrewcalendar/RegressionTestFileWriter.java index ea275fc6..c98a7535 100644 --- a/src/test/java/com/kosherjava/zmanim/hebrewcalendar/RegressionTestFileWriter.java +++ b/src/test/java/com/kosherjava/zmanim/hebrewcalendar/RegressionTestFileWriter.java @@ -55,7 +55,7 @@ public static void main(String[] args) throws IOException { zcal.getAlos18Degrees(), zcal.getAlos19Degrees(), zcal.getAlos19Point8Degrees(), zcal.getAlos16Point1Degrees(), zcal.getMisheyakir11Point5Degrees(), zcal.getMisheyakir11Degrees(), zcal.getMisheyakir10Point2Degrees(), zcal.getMisheyakir7Point65Degrees(), - zcal.getMisheyakir9Point5Degrees(), zcal.getSunrise(), zcal.getSeaLevelSunrise(), + zcal.getMisheyakir9Point5Degrees(), zcal.getSunriseWithElevation(), zcal.getSeaLevelSunrise(), zcal.getSofZmanShmaMGA16Point1Degrees(), zcal.getSofZmanShmaMGA72Minutes(), zcal.getSofZmanShmaMGA72MinutesZmanis(), zcal.getSofZmanShmaMGA90Minutes(), zcal.getSofZmanShmaMGA90MinutesZmanis(), zcal.getSofZmanShmaMGA96Minutes(), From 02416815dbd6308134c49c01cdcddaddacb80961 Mon Sep 17 00:00:00 2001 From: Moshe Dicker Date: Fri, 1 May 2026 11:44:02 -0400 Subject: [PATCH 2/7] Revert "fix test case for recent sunrise/sunset name changes" This reverts commit 37cb93b03206c2bdc80dbf540a6de8e32f9acf21. --- .../com/kosherjava/zmanim/util/SerializationRegressionTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/test/java/com/kosherjava/zmanim/util/SerializationRegressionTest.java b/src/test/java/com/kosherjava/zmanim/util/SerializationRegressionTest.java index 58d2218f..b69bb94c 100644 --- a/src/test/java/com/kosherjava/zmanim/util/SerializationRegressionTest.java +++ b/src/test/java/com/kosherjava/zmanim/util/SerializationRegressionTest.java @@ -41,7 +41,7 @@ public void astronomicalCalendarPreservesSubSecondPrecision() { double utcSunrise = astronomicalCalendar.getUTCSunrise(AstronomicalCalendar.GEOMETRIC_ZENITH); long expectedEpochMillis = Math.round(utcSunrise * AstronomicalCalendar.HOUR_MILLIS); - long actualEpochMillis = astronomicalCalendar.getSunrise().toEpochMilli() + long actualEpochMillis = astronomicalCalendar.getSunriseWithElevation().toEpochMilli() % (24 * AstronomicalCalendar.HOUR_MILLIS); assertTrue(expectedEpochMillis % 1000 != 0); From 9d4880d19c0dcad94b31e52136d11496f1de1c78 Mon Sep 17 00:00:00 2001 From: Moshe Dicker Date: Fri, 1 May 2026 11:44:04 -0400 Subject: [PATCH 3/7] Revert "ComprehensiveZmanimCalendar - Remove getSunriseWithElevation() and getSunsetWithElevation()" This reverts commit 628328ac27b94ce3594b4af392982bf61783a951. --- .../zmanim/ComprehensiveZmanimCalendar.java | 202 +++++++++--------- 1 file changed, 101 insertions(+), 101 deletions(-) diff --git a/src/main/java/com/kosherjava/zmanim/ComprehensiveZmanimCalendar.java b/src/main/java/com/kosherjava/zmanim/ComprehensiveZmanimCalendar.java index 72f4f72d..e4650d95 100644 --- a/src/main/java/com/kosherjava/zmanim/ComprehensiveZmanimCalendar.java +++ b/src/main/java/com/kosherjava/zmanim/ComprehensiveZmanimCalendar.java @@ -30,7 +30,7 @@ * API. The real power of this API is the ease in calculating zmanim that are not part of the library. The methods for * zmanim calculations not present in this class or it's superclass {@link ZmanimCalendar} are contained in the * {@link AstronomicalCalendar}, the base class of the calendars in our API since they are generic methods for calculating - * time based on degrees or time before or after {@link getSunrise() sunrise} and {@link getSunset() + * time based on degrees or time before or after {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() * sunset} and are of interest for calculation beyond zmanim calculations. Here are some examples. *

First create the Calendar for the location you would like to calculate: * @@ -422,11 +422,11 @@ public long getShaahZmanis60Minutes() { /** * Method to return a shaah zmanis (temporal hour) according to the opinion of the Magen Avraham (MGA) based on alos being - * {@link getAlos72Zmanis() 72} minutes zmaniyos before {@link getSunrise() sunrise}. This calculation + * {@link getAlos72Zmanis() 72} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This calculation * divides the day based on the opinion of the MGA that the day runs from dawn to dusk. Dawn for this calculation * is 72 minutes zmaniyos before sunrise and dusk is 72 minutes zmaniyos after sunset. This day * is split into 12 equal parts with each part being a shaah zmanis. This is identical to 1/10th of the day - * from {@link getSunrise() sunrise} to {@link getSunset() sunset}. + * from {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset}. * * @return the long millisecond length of a shaah zmanis. If the calculation can't be computed * such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one @@ -457,11 +457,11 @@ public long getShaahZmanis90Minutes() { /** * Method to return a shaah zmanis (temporal hour) according to the opinion of the Magen Avraham (MGA) based on alos being {@link - * getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunrise() sunrise}. This calculation divides + * getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This calculation divides * the day based on the opinion of the MGA that the day runs from dawn to dusk. Dawn for this calculation is 90 minutes * zmaniyos before sunrise and dusk is 90 minutes zmaniyos after sunset. This day is split into 12 equal - * parts with each part being a shaah zmanis. This is 1/8th of the day from {@link getSunrise() sunrise} - * to {@link getSunset() sunset}. + * parts with each part being a shaah zmanis. This is 1/8th of the day from {@link getSunriseWithElevation() sunrise} + * to {@link getSunsetWithElevation() sunset}. * * @return the long millisecond length of a shaah zmanis. If the calculation can't be computed * such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one @@ -477,11 +477,11 @@ public long getShaahZmanis90MinutesZmanis() { /** * Method to return a shaah zmanis (temporal hour) according to the opinion of the Magen Avraham (MGA) based on alos being {@link - * getAlos96Zmanis() 96} minutes zmaniyos before {@link getSunrise() sunrise}. This calculation divides + * getAlos96Zmanis() 96} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This calculation divides * the day based on the opinion of the MGA that the day runs from dawn to dusk. Dawn for this calculation is 96 minutes * zmaniyos before sunrise and dusk is 96 minutes zmaniyos after sunset. This day is split into 12 equal * parts with each part being a shaah zmanis. This is identical to 1/7.5th of the day from {@link - * getSunrise() sunrise} to {@link getSunset() sunset}. + * getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset}. * * @return the long millisecond length of a shaah zmanis. If the calculation can't be computed * such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one @@ -498,8 +498,8 @@ public long getShaahZmanis96MinutesZmanis() { * Method to return a shaah zmanis (temporal hour) according to the opinion of the * Chacham Yosef Harari-Raful of Yeshivat Ateret Torah calculated with alos being 1/10th * of sunrise to sunset day, or {@link getAlos72Zmanis() 72} minutes zmaniyos of such a day before - * {@link getSunrise() sunrise}, and tzais is usually calculated as {@link getTzaisAteretTorah() 40 - * minutes} (configurable to any offset via {@link setAteretTorahSunsetOffset(double)}) after {@link getSunset() + * {@link getSunriseWithElevation() sunrise}, and tzais is usually calculated as {@link getTzaisAteretTorah() 40 + * minutes} (configurable to any offset via {@link setAteretTorahSunsetOffset(double)}) after {@link getSunsetWithElevation() * sunset}. This day is split into 12 equal parts with each part being a shaah zmanis. Note that with this * system, chatzos (midday) will not be the point that the sun is {@link getSunTransit() halfway across * the sky}. @@ -600,11 +600,11 @@ public long getShaahZmanis120Minutes() { /** * Method to return a shaah zmanis (temporal hour) according to the opinion of the Magen Avraham (MGA) based on alos being {@link - * getAlos120Zmanis() 120} minutes zmaniyos before {@link getSunrise() sunrise}. This calculation divides + * getAlos120Zmanis() 120} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This calculation divides * the day based on the opinion of the MGA that the day runs from dawn to dusk. Dawn for this calculation is 120 minutes * zmaniyos before sunrise and dusk is 120 minutes zmaniyos after sunset. This day is split into 12 equal * parts with each part being a shaah zmanis. This is identical to 1/6th of the day from {@link - * getSunrise() sunrise} to {@link getSunset() sunset}. Since zmanim that use this method are + * getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset}. Since zmanim that use this method are * extremely late or early and at a point when the sky is a long time past the 18° point where the darkest point is reached, * zmanim that use this should only be used lechumra such as delaying the start of nighttime mitzvos. * @@ -673,7 +673,7 @@ public Instant getPlagHamincha120Minutes() { } /** - * Method to return alos (dawn) calculated as 60 minutes before {@link getSunrise() sunrise} or + * Method to return alos (dawn) calculated as 60 minutes before {@link getSunriseWithElevation() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting). This is the * time to walk the distance of 4 mil at 15 minutes a mil. This seems to be the opinion of the mil so the time for 4 mil is * 72 minutes which is 1/10th of a day (12 * 60 = 720) based on the day being from {@link getSeaLevelSunrise() sea - * level sunrise} to {@link getSeaLevelSunset() sea level sunset} or {@link getSunrise() sunrise} to {@link - * getSunset() sunset} (depending on the {@link isUseElevation()} setting). The actual calculation is {@link - * getSunrise()} - ({@link getShaahZmanisGRA()} * 1.2). This calculation is used in the calendars + * level sunrise} to {@link getSeaLevelSunset() sea level sunset} or {@link getSunriseWithElevation() sunrise} to {@link + * getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()} setting). The actual calculation is {@link + * getSunriseBasedOnElevationSetting()} - ({@link getShaahZmanisGRA()} * 1.2). This calculation is used in the calendars * published by the Hisachdus Harabanim D'Artzos Habris * Ve'Canada. * @@ -727,7 +727,7 @@ public Instant getAlos72Zmanis() { } /** - * Method to return alos (dawn) calculated using 96 minutes before {@link getSunrise() sunrise} or + * Method to return alos (dawn) calculated using 96 minutes before {@link getSunriseWithElevation() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting) that is based * on the time to walk the distance of 4 mil at 24 minutes a mil. @@ -742,18 +742,18 @@ public Instant getAlos72Zmanis() { * documentation. */ public Instant getAlos96Minutes() { - return getTimeOffset(getSunrise(), -96 * MINUTE_MILLIS); + return getTimeOffset(getSunriseBasedOnElevationSetting(), -96 * MINUTE_MILLIS); } /** * Method to return alos (dawn) calculated using 90 minutes zmaniyos or 1/8th of the day before - * {@link getSunrise() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link + * {@link getSunriseWithElevation() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link * isUseElevation()} setting). This is based on a 22.5-minute mil so the time for 4 mil is 90 minutes * which is 1/8th of a day (12 * 60) / 8 = 90. The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} - * to {@link getSeaLevelSunset() sea level sunset} or {@link getSunrise() sunrise} to {@link - * getSunset() sunset} (depending on the {@link isUseElevation()}. The actual calculation used is - * {@link getSunrise()} - ({@link getShaahZmanisGRA()} * 1.5). + * to {@link getSeaLevelSunset() sea level sunset} or {@link getSunriseWithElevation() sunrise} to {@link + * getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()}. The actual calculation used is + * {@link getSunriseBasedOnElevationSetting()} - ({@link getShaahZmanisGRA()} * 1.5). * * @return the Instant representing the time. If the calculation can't be computed such as in the Arctic * Circle where there is at least one day a year where the sun does not rise, and one where it does not set, @@ -767,13 +767,13 @@ public Instant getAlos90Zmanis() { /** * This method returns alos (dawn) calculated using 96 minutes zmaniyos or 1/7.5th of the day before - * {@link getSunrise() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link + * {@link getSunriseWithElevation() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link * isUseElevation()} setting). This is based on a 24-minute mil so the time for 4 mil is 96 minutes * which is 1/7.5th of a day (12 * 60 / 7.5 = 96). The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} - * to {@link getSeaLevelSunset() sea level sunset} or {@link getSunrise() sunrise} to {@link - * getSunset() sunset} (depending on the {@link isUseElevation()}. The actual calculation used is {@link - * getSunrise()} - ({@link getShaahZmanisGRA()} * 1.6). + * to {@link getSeaLevelSunset() sea level sunset} or {@link getSunriseWithElevation() sunrise} to {@link + * getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()}. The actual calculation used is {@link + * getSunriseBasedOnElevationSetting()} - ({@link getShaahZmanisGRA()} * 1.6). * * @return the Instant representing the time. If the calculation can't be computed such as in the Arctic * Circle where there is at least one day a year where the sun does not rise, and one where it does not set, @@ -786,7 +786,7 @@ public Instant getAlos96Zmanis() { } /** - * Method to return alos (dawn) calculated using 90 minutes before {@link getSunrise() sunrise} or + * Method to return alos (dawn) calculated using 90 minutes before {@link getSunriseWithElevation() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting) based on the time * to walk the distance of 4 mil at * 22.5 minutes a mil. Time-based offset calculations for alos are based on the opinion of the lechumra only and returns alos (dawn) calculated using 120 minutes - * before {@link getSunrise() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the + * before {@link getSunriseWithElevation() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the * {@link isUseElevation()} setting) based on the time to walk the distance of 5 mil (Ula) at 24 minutes a * mil. Time based offset calculations for alos are based on the* opinion of the lechumra only and method returns alos (dawn) calculated using - * 120 minutes zmaniyos or 1/6th of the day before {@link getSunrise() sunrise} or {@link + * 120 minutes zmaniyos or 1/6th of the day before {@link getSunriseWithElevation() sunrise} or {@link * getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting). This is based * on a 24-minute mil so * the time for 5 mil is 120 minutes which is 1/6th of a day (12 * 60 / 6 = 120). The day is calculated from * {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level sunset} or {@link - * getSunrise() sunrise} to {@link getSunset() sunset} (depending on the {@link - * isUseElevation()}. The actual calculation used is {@link getSunrise()} - ({@link getShaahZmanisGRA()} + * getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the {@link + * isUseElevation()}. The actual calculation used is {@link getSunriseWithElevation()} - ({@link getShaahZmanisGRA()} * * 2). Since this time is extremely early, it should only be used lechumra, such as not eating after this time * on a fast day, and not as the start time for mitzvos that can only be performed during the day. * @@ -944,7 +944,7 @@ public Instant getAlos19Point8Degrees() { /** * This method returns misheyakir based on the position of the sun {@link ZENITH_12_POINT_85 12.85°} * below {@link GEOMETRIC_ZENITH geometric zenith} (90°). This is based on the position of the sun slightly - * later than 57 minutes before {@link getSunrise() sunrise} in Jerusalem around the equinox / equilux. This * zman is mentioned for use bish'as hadchak in the Birur Halacha Tinyana and misheyakir based on the position of the sun when it is {@link ZENITH_11_DEGREES * 11.5°} below {@link GEOMETRIC_ZENITH geometric zenith} (90°). This calculation is used for calculating * misheyakir according to some opinions. This calculation is based on the position of the sun 52 minutes - * before {@link getSunrise() sunrise} in Jerusalem around the equinox / equilux, * which calculates to 11.5° below {@link GEOMETRIC_ZENITH geometric zenith}. * @todo recalculate. @@ -1008,7 +1008,7 @@ public Instant getMisheyakir11Point5Degrees() { * This method returns misheyakir based on the position of the sun when it is {@link ZENITH_11_DEGREES * 11°} below {@link GEOMETRIC_ZENITH geometric zenith} (90°). This calculation is used for calculating * misheyakir according to some opinions. This calculation is based on the position of the sun 48 minutes - * before {@link getSunrise() sunrise} in Jerusalem around the equinox / equilux, * which calculates to 11° below {@link GEOMETRIC_ZENITH geometric zenith}. * @@ -1026,7 +1026,7 @@ public Instant getMisheyakir11Degrees() { * This method returns misheyakir based on the position of the sun when it is {@link ZENITH_10_POINT_2 * 10.2°} below {@link GEOMETRIC_ZENITH geometric zenith} (90°). This calculation is used for calculating * misheyakir according to some opinions. This calculation is based on the position of the sun 45 minutes - * before {@link getSunrise() sunrise} in Jerusalem around the equinox which calculates * to 10.2° below {@link GEOMETRIC_ZENITH geometric zenith}. * @@ -1104,7 +1104,7 @@ public Instant getMisheyakir9Point5Degrees() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the * opinion of the Magen Avraham (MGA) based on - * alos being {@link getAlos19Point8Degrees() 19.8°} before {@link getSunrise() sunrise}. This + * alos being {@link getAlos19Point8Degrees() 19.8°} before {@link getSunriseWithElevation() sunrise}. This * time is 3 {@link getShaahZmanis19Point8Degrees() shaos zmaniyos} (solar hours) after {@link * getAlos19Point8Degrees() dawn} based on the opinion of the MGA that the day is calculated from dawn to nightfall * with both being 19.8° below sunrise or sunset. This returns the time of 3 * @@ -1124,7 +1124,7 @@ public Instant getSofZmanShmaMGA19Point8Degrees() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the opinion of * the Magen Avraham (MGA) based on alos being {@link - * getAlos16Point1Degrees() 16.1°} before {@link getSunrise() sunrise}. This time is 3 {@link + * getAlos16Point1Degrees() 16.1°} before {@link getSunriseWithElevation() sunrise}. This time is 3 {@link * getShaahZmanis16Point1Degrees() shaos zmaniyos} (solar hours) after {@link getAlos16Point1Degrees() dawn} based on * the opinion of the MGA that the day is calculated from dawn to nightfall with both being 16.1° below sunrise or sunset. * This returns the time of 3 * {@link getShaahZmanis16Point1Degrees()} after {@link getAlos16Point1Degrees() dawn}. @@ -1143,7 +1143,7 @@ public Instant getSofZmanShmaMGA16Point1Degrees() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the * opinion of the Magen Avraham (MGA) based - * on alos being {@link getAlos18Degrees() 18°} before {@link getSunrise() sunrise}. This time is 3 + * on alos being {@link getAlos18Degrees() 18°} before {@link getSunriseWithElevation() sunrise}. This time is 3 * {@link getShaahZmanis18Degrees() shaos zmaniyos} (solar hours) after {@link getAlos18Degrees() dawn} * based on the opinion of the MGA that the day is calculated from dawn to nightfall with both being 18° * below sunrise or sunset. This returns the time of 3 * {@link getShaahZmanis18Degrees()} after @@ -1164,7 +1164,7 @@ public Instant getSofZmanShmaMGA18Degrees() { * This method returns the latest zman krias shema (time to recite Shema in the morning) according * to the opinion of the Magen Avraham (MGA) based * on alos being {@link getAlos72Zmanis() 72} minutes zmaniyos, or 1/10th of the day before - * {@link getSunrise() sunrise}. This time is 3 {@link getShaahZmanis90MinutesZmanis() shaos zmaniyos} + * {@link getSunriseWithElevation() sunrise}. This time is 3 {@link getShaahZmanis90MinutesZmanis() shaos zmaniyos} * (solar hours) after {@link getAlos72Zmanis() dawn} based on the opinion of the MGA that the day is calculated * from a {@link getAlos72Zmanis() dawn} of 72 minutes zmaniyos, or 1/10th of the day before * {@link getSeaLevelSunrise() sea level sunrise} to {@link getTzais72Zmanis() nightfall} of 72 minutes @@ -1186,7 +1186,7 @@ public Instant getSofZmanShmaMGA72MinutesZmanis() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according * to the opinion of the Magen Avraham (MGA) based on - * alos being {@link getAlos90Minutes() 90} minutes before {@link getSunrise() sunrise}. This time is 3 + * alos being {@link getAlos90Minutes() 90} minutes before {@link getSunriseWithElevation() sunrise}. This time is 3 * {@link getShaahZmanis90Minutes() shaos zmaniyos} (solar hours) after {@link getAlos90Minutes() dawn} based on * the opinion of the MGA that the day is calculated from a {@link getAlos90Minutes() dawn} of 90 minutes before sunrise to * {@link getTzais90Minutes() nightfall} of 90 minutes after sunset. This returns the time of 3 * @@ -1207,7 +1207,7 @@ public Instant getSofZmanShmaMGA90Minutes() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the * opinion of the Magen Avraham (MGA) based - * on alos being {@link getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunrise() + * on alos being {@link getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunriseWithElevation() * sunrise}. This time is 3 {@link getShaahZmanis90MinutesZmanis() shaos zmaniyos} (solar hours) after * {@link getAlos90Zmanis() dawn} based on the opinion of the MGA that the day is calculated from a {@link * getAlos90Zmanis() dawn} of 90 minutes zmaniyos before sunrise to {@link getTzais90Zmanis() nightfall} @@ -1229,7 +1229,7 @@ public Instant getSofZmanShmaMGA90MinutesZmanis() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the opinion of * the Magen Avraham (MGA) based on alos being {@link - * getAlos96Minutes() 96} minutes before {@link getSunrise() sunrise}. This time is 3 {@link + * getAlos96Minutes() 96} minutes before {@link getSunriseWithElevation() sunrise}. This time is 3 {@link * getShaahZmanis96Minutes() shaos zmaniyos} (solar hours) after {@link getAlos96Minutes() dawn} based on the opinion * of the MGA that the day is calculated from a {@link getAlos96Minutes() dawn} of 96 minutes before sunrise to {@link * getTzais96Minutes() nightfall} of 96 minutes after sunset. This returns the time of 3 * {@link getShaahZmanis96Minutes()} @@ -1250,7 +1250,7 @@ public Instant getSofZmanShmaMGA96Minutes() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the * opinion of the Magen Avraham (MGA) based - * on alos being {@link getAlos90Zmanis() 96} minutes zmaniyos before {@link getSunrise() + * on alos being {@link getAlos90Zmanis() 96} minutes zmaniyos before {@link getSunriseWithElevation() * sunrise}. This time is 3 {@link getShaahZmanis96MinutesZmanis() shaos zmaniyos} (solar hours) after * {@link getAlos96Zmanis() dawn} based on the opinion of the MGA that the day is calculated from a {@link * getAlos96Zmanis() dawn} of 96 minutes zmaniyos before sunrise to {@link getTzais90Zmanis() nightfall} @@ -1301,7 +1301,7 @@ public Instant getSofZmanShma3HoursBeforeChatzos() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the * opinion of the Magen Avraham (MGA) based - * on alos being {@link getAlos120Minutes() 120} minutes or 1/6th of the day before {@link getSunrise() + * on alos being {@link getAlos120Minutes() 120} minutes or 1/6th of the day before {@link getSunriseWithElevation() * sunrise}. This time is 3 {@link getShaahZmanis120Minutes() shaos zmaniyos} (solar hours) after {@link * getAlos120Minutes() dawn} based on the opinion of the MGA that the day is calculated from a {@link getAlos120Minutes() dawn} * of 120 minutes before sunrise to {@link getTzais120Minutes() nightfall} of 120 minutes after sunset. This returns the time of @@ -1343,7 +1343,7 @@ public Instant getSofZmanShmaMGA120Minutes() { * @see getSeaLevelSunset() */ public Instant getSofZmanShmaAlos16Point1ToSunset() { - return getSofZmanShma(getAlos16Point1Degrees(), getSunset(), false); + return getSofZmanShma(getAlos16Point1Degrees(), getSunsetBasedOnElevationSetting(), false); } /** @@ -1372,7 +1372,7 @@ public Instant getSofZmanShmaAlos16Point1ToTzaisGeonim7Point083Degrees() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos19Point8Degrees() 19.8°} before {@link getSunrise() sunrise}. This time + * alos being {@link getAlos19Point8Degrees() 19.8°} before {@link getSunriseWithElevation() sunrise}. This time * is 4 {@link getShaahZmanis19Point8Degrees() shaos zmaniyos} (solar hours) after {@link * getAlos19Point8Degrees() dawn} based on the opinion of the MGA that the day is calculated from dawn to * nightfall with both being 19.8° below sunrise or sunset. This returns the time of 4 * {@link @@ -1394,7 +1394,7 @@ public Instant getSofZmanTfilaMGA19Point8Degrees() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunrise() sunrise}. This time + * alos being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunriseWithElevation() sunrise}. This time * is 4 {@link getShaahZmanis16Point1Degrees() shaos zmaniyos} (solar hours) after {@link * getAlos16Point1Degrees() dawn} based on the opinion of the MGA that the day is calculated from dawn to * nightfall with both being 16.1° below sunrise or sunset. This returns the time of 4 * {@link @@ -1415,7 +1415,7 @@ public Instant getSofZmanTfilaMGA16Point1Degrees() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos18Degrees() 18°} before {@link getSunrise() sunrise}. This time is 4 + * alos being {@link getAlos18Degrees() 18°} before {@link getSunriseWithElevation() sunrise}. This time is 4 * {@link getShaahZmanis18Degrees() shaos zmaniyos} (solar hours) after {@link getAlos18Degrees() dawn} * based on the opinion of the MGA that the day is calculated from dawn to nightfall with both being 18° * below sunrise or sunset. This returns the time of 4 * {@link getShaahZmanis18Degrees()} after @@ -1436,7 +1436,7 @@ public Instant getSofZmanTfilaMGA18Degrees() { /** * This method returns the latest zman tfila (time to the morning prayers) according to the opinion of the * Magen Avraham (MGA) based on alos - * being {@link getAlos72Zmanis() 72} minutes zmaniyos before {@link getSunrise() sunrise}. This time is 4 + * being {@link getAlos72Zmanis() 72} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This time is 4 * {@link getShaahZmanis72MinutesZmanis() shaos zmaniyos} (solar hours) after {@link getAlos72Zmanis() dawn} * based on the opinion of the MGA that the day is calculated from a {@link getAlos72Zmanis() dawn} of 72 * minutes zmaniyos before sunrise to {@link getTzais72Zmanis() nightfall} of 72 minutes zmaniyos @@ -1456,7 +1456,7 @@ public Instant getSofZmanTfilaMGA72MinutesZmanis() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos90Minutes() 90} minutes before {@link getSunrise() sunrise}. This time is 4 + * alos being {@link getAlos90Minutes() 90} minutes before {@link getSunriseWithElevation() sunrise}. This time is 4 * {@link getShaahZmanis90Minutes() shaos zmaniyos} (solar hours) after {@link getAlos90Minutes() dawn} based on * the opinion of the MGA that the day is calculated from a {@link getAlos90Minutes() dawn} of 90 minutes before sunrise to * {@link getTzais90Minutes() nightfall} of 90 minutes after sunset. This returns the time of 4 * @@ -1476,7 +1476,7 @@ public Instant getSofZmanTfilaMGA90Minutes() { /** * This method returns the latest zman tfila (time to the morning prayers) according to the opinion of the * Magen Avraham (MGA) based on alos - * being {@link getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunrise() sunrise}. This time is + * being {@link getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This time is * 4 {@link getShaahZmanis90MinutesZmanis() shaos zmaniyos} (solar hours) after {@link getAlos90Zmanis() * dawn} based on the opinion of the MGA that the day is calculated from a {@link getAlos90Zmanis() dawn} * of 90 minutes zmaniyos before sunrise to {@link getTzais90Zmanis() nightfall} of 90 minutes @@ -1497,7 +1497,7 @@ public Instant getSofZmanTfilaMGA90MinutesZmanis() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos96Minutes() 96} minutes before {@link getSunrise() sunrise}. This time is 4 + * alos being {@link getAlos96Minutes() 96} minutes before {@link getSunriseWithElevation() sunrise}. This time is 4 * {@link getShaahZmanis96Minutes() shaos zmaniyos} (solar hours) after {@link getAlos96Minutes() dawn} based on * the opinion of the MGA that the day is calculated from a {@link getAlos96Minutes() dawn} of 96 minutes before * sunrise to {@link getTzais96Minutes() nightfall} of 96 minutes after sunset. This returns the time of 4 * @@ -1517,7 +1517,7 @@ public Instant getSofZmanTfilaMGA96Minutes() { /** * This method returns the latest zman tfila (time to the morning prayers) according to the opinion of the * Magen Avraham (MGA) based on alos - * being {@link getAlos96Zmanis() 96} minutes zmaniyos before {@link getSunrise() sunrise}. This time is + * being {@link getAlos96Zmanis() 96} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This time is * 4 {@link getShaahZmanis96MinutesZmanis() shaos zmaniyos} (solar hours) after {@link getAlos96Zmanis() * dawn} based on the opinion of the MGA that the day is calculated from a {@link getAlos96Zmanis() dawn} * of 96 minutes zmaniyos before sunrise to {@link getTzais96Zmanis() nightfall} of 96 minutes @@ -1538,7 +1538,7 @@ public Instant getSofZmanTfilaMGA96MinutesZmanis() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos120Minutes() 120} minutes before {@link getSunrise() sunrise} . This time is 4 + * alos being {@link getAlos120Minutes() 120} minutes before {@link getSunriseWithElevation() sunrise} . This time is 4 * {@link getShaahZmanis120Minutes() shaos zmaniyos} (solar hours) after {@link getAlos120Minutes() dawn} * based on the opinion of the MGA that the day is calculated from a {@link getAlos120Minutes() dawn} of 120 * minutes before sunrise to {@link getTzais120Minutes() nightfall} of 120 minutes after sunset. This returns the time of @@ -2032,7 +2032,7 @@ public Instant getPlagHamincha18Degrees() { /** * This method should be used lechumra only and returns the time of plag hamincha based on the opinion that - * the day starts at {@link getAlos16Point1Degrees() alos 16.1°} and ends at {@link getSunset() + * the day starts at {@link getAlos16Point1Degrees() alos 16.1°} and ends at {@link getSunsetWithElevation() * sunset}. 10.75 shaos zmaniyos are calculated based on this day and added to {@link getAlos16Point1Degrees() * alos} to reach this time. This time is 10.75 shaos zmaniyos (temporal hours) after {@link * getAlos16Point1Degrees() dawn} based on the opinion that the day is calculated from a {@link getAlos16Point1Degrees() @@ -2055,7 +2055,7 @@ public Instant getPlagHamincha18Degrees() { */ @Deprecated (forRemoval=false) public Instant getPlagAlosToSunset() { - return getPlagHamincha(getAlos16Point1Degrees(), getSunset(), false); + return getPlagHamincha(getAlos16Point1Degrees(), getSunsetBasedOnElevationSetting(), false); } /** @@ -2141,7 +2141,7 @@ public Instant getBainHashmashosRT13Point24Degrees() { * */ public Instant getBainHashmashosRT58Point5Minutes() { - return getTimeOffset(getSunset(), 58.5 * MINUTE_MILLIS); + return getTimeOffset(getSunsetBasedOnElevationSetting(), 58.5 * MINUTE_MILLIS); } /** @@ -2174,11 +2174,11 @@ public Instant getBainHashmashosRT13Point5MinutesBefore7Point083Degrees() { */ public Instant getBainHashmashosRT2Stars() { Instant alos19Point8 = getAlos19Point8Degrees(); - Instant sunrise = getSunrise(); + Instant sunrise = getSunriseBasedOnElevationSetting(); if (alos19Point8 == null || sunrise == null) { return null; } - return getTimeOffset(getSunset(), (sunrise.toEpochMilli() - alos19Point8.toEpochMilli()) * (5 / 18d)); + return getTimeOffset(getSunsetBasedOnElevationSetting(), (sunrise.toEpochMilli() - alos19Point8.toEpochMilli()) * (5 / 18d)); } /** @@ -2195,7 +2195,7 @@ public Instant getBainHashmashosRT2Stars() { * @see getBainHashmashosYereim3Point05Degrees() */ public Instant getBainHashmashosYereim18Minutes() { - return getTimeOffset(getSunset(), -18 * MINUTE_MILLIS); + return getTimeOffset(getSunsetBasedOnElevationSetting(), -18 * MINUTE_MILLIS); } /** @@ -2248,7 +2248,7 @@ public Instant getBainHashmashosYereim3Point05Degrees() { * @see getBainHashmashosYereim2Point8Degrees() */ public Instant getBainHashmashosYereim16Point875Minutes() { - return getTimeOffset(getSunset(), -16.875 * MINUTE_MILLIS); + return getTimeOffset(getSunsetBasedOnElevationSetting(), -16.875 * MINUTE_MILLIS); } /** @@ -2291,7 +2291,7 @@ public Instant getBainHashmashosYereim2Point8Degrees() { * @see getBainHashmashosYereim2Point1Degrees() */ public Instant getBainHashmashosYereim13Point5Minutes() { - return getTimeOffset(getSunset(), -13.5 * MINUTE_MILLIS); + return getTimeOffset(getSunsetBasedOnElevationSetting(), -13.5 * MINUTE_MILLIS); } /** @@ -2583,7 +2583,7 @@ public Instant getTzaisGeonim9Point75Degrees() { * "https://he.wikipedia.org/wiki/%D7%9E%D7%9C%D7%9B%D7%99%D7%90%D7%9C_%D7%A6%D7%91%D7%99_%D7%98%D7%A0%D7%A0%D7%91%D7%95%D7%99%D7%9D" * >Divrei Malkiel that the time to walk the distance of a mil is 15 minutes, for a total of 60 minutes - * for 4 mil after {@link getSunset() sunset} or {@link getSeaLevelSunset() sea level sunset} (depending on the + * for 4 mil after {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunset() sea level sunset} (depending on the * {@link isUseElevation()} setting). See detailed documentation explaining the 60 minute concept at {@link getAlos60Minutes()}. * * @return the Instant representing 60 minutes after sea level sunset. If the calculation can't be @@ -2596,7 +2596,7 @@ public Instant getTzaisGeonim9Point75Degrees() { * @see getShaahZmanis60Minutes() */ public Instant getTzais60Minutes() { - return getTimeOffset(getSunset(), 60 * MINUTE_MILLIS); + return getTimeOffset(getSunsetBasedOnElevationSetting(), 60 * MINUTE_MILLIS); } /** @@ -2616,7 +2616,7 @@ public Instant getTzais60Minutes() { * @see setAteretTorahSunsetOffset(double) */ public Instant getTzaisAteretTorah() { - return getTimeOffset(getSunset(), getAteretTorahSunsetOffset() * MINUTE_MILLIS); + return getTimeOffset(getSunsetBasedOnElevationSetting(), getAteretTorahSunsetOffset() * MINUTE_MILLIS); } /** @@ -2820,7 +2820,7 @@ public Instant getTzais96Zmanis() { } /** - * Method to return tzais (dusk) calculated as 90 minutes after {@link getSunset() sunset} or {@link + * Method to return tzais (dusk) calculated as 90 minutes after {@link getSunsetWithElevation() sunset} or {@link * getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} setting). This method returns * tzais (nightfall) based on the opinion of the Magen Avraham that the time to walk the distance of a mil according to the Rav Chaim Naeh that the time to walk the distance * of a mil according to the Rambam's opinion is 2/5 of an hour (24 minutes) for a total of 120 - * minutes based on the opinion of Ula who calculated tzais as 5 mil after {@link getSunset() + * minutes based on the opinion of Ula who calculated tzais as 5 mil after {@link getSunsetWithElevation() * sunset} or {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} setting). * A similar calculation {@link getTzais26Degrees()} uses degree-based calculations based on this 120 minute calculation. * Since the zman is extremely late and at a point that is long past the 18° point where the darkest point is @@ -2863,7 +2863,7 @@ public Instant getTzais90Minutes() { */ @Deprecated (forRemoval=false) public Instant getTzais120Minutes() { - return getTimeOffset(getSunset(), 120 * MINUTE_MILLIS); + return getTimeOffset(getSunsetBasedOnElevationSetting(), 120 * MINUTE_MILLIS); } /** @@ -2965,7 +2965,7 @@ public Instant getTzais19Point8Degrees() { } /** - * A method to return tzais (dusk) calculated as 96 minutes after {@link getSunset() sunset} or {@link + * A method to return tzais (dusk) calculated as 96 minutes after {@link getSunsetWithElevation() sunset} or {@link * getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} setting). For information on how * this is calculated see the comments on {@link getAlos96Minutes()}. * @@ -2976,7 +2976,7 @@ public Instant getTzais19Point8Degrees() { * @see getAlos96Minutes() */ public Instant getTzais96Minutes() { - return getTimeOffset(getSunset(), 96 * MINUTE_MILLIS); + return getTimeOffset(getSunsetBasedOnElevationSetting(), 96 * MINUTE_MILLIS); } /** @@ -3326,13 +3326,13 @@ public Instant getTchilasZmanKidushLevana7Days() { * @see getSofZmanAchilasChametz(Instant, Instant, boolean) */ public Instant getSofZmanAchilasChametzGRA() { - return getSofZmanAchilasChametz(getSunrise(), getSunset(), true); + return getSofZmanAchilasChametz(getSunriseBasedOnElevationSetting(), getSunsetBasedOnElevationSetting(), true); } /** * This method returns the latest time one is allowed eating chametz on Erev Pesach according to the * opinion of the Magen Avraham (MGA) based on alos - * being {@link getAlos72Minutes() 72} minutes before {@link getSunrise() sunrise}. This time is identical to the + * being {@link getAlos72Minutes() 72} minutes before {@link getSunriseWithElevation() sunrise}. This time is identical to the * {@link getSofZmanTfilaMGA72Minutes() Sof zman tfilah MGA 72 minutes}. This time is 4 {@link * getShaahZmanis72Minutes() shaos zmaniyos} (temporal hours) after {@link getAlos72Minutes() dawn} based on the * opinion of the MGA that the day is calculated from a {@link getAlos72Minutes() dawn} of 72 minutes before sunrise to {@link @@ -3355,7 +3355,7 @@ public Instant getSofZmanAchilasChametzMGA72Minutes() { /** * This method returns the latest time one is allowed eating chametz on Erev Pesach according to the opinion * of the Magen Avraham (MGA) based on alos being {@link - * getAlos72Zmanis() 72 zmaniyos} minutes before {@link getSunrise() sunrise}. This time is identical to the + * getAlos72Zmanis() 72 zmaniyos} minutes before {@link getSunriseWithElevation() sunrise}. This time is identical to the * {@link getSofZmanTfilaMGA72MinutesZmanis() Sof zman tfilah MGA 72 minutes zmanis}. This time is 4 {@link * getShaahZmanis72MinutesZmanis() shaos zmaniyos} (temporal hours) after {@link getAlos72Minutes() dawn} based on the * opinion of the MGA that the day is calculated from a {@link getAlos72Zmanis() dawn} of 72 minutes zmanis before sunrise to @@ -3379,7 +3379,7 @@ public Instant getSofZmanAchilasChametzMGA72MinutesZmanis() { /** * This method returns the latest time one is allowed eating chametz on Erev Pesach according to the * opinion of the Magen Avraham (MGA) based on alos - * being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunrise() sunrise}. This time is 4 {@link + * being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunriseWithElevation() sunrise}. This time is 4 {@link * getShaahZmanis16Point1Degrees() shaos zmaniyos} (solar hours) after {@link getAlos16Point1Degrees() dawn} based * on the opinion of the MGA that the day is calculated from dawn to nightfall with both being 16.1° below sunrise or * sunset. This returns the time of 4 {@link getShaahZmanis16Point1Degrees()} after {@link getAlos16Point1Degrees() dawn}. @@ -3412,13 +3412,13 @@ public Instant getSofZmanAchilasChametzMGA16Point1Degrees() { * @see getSofZmanBiurChametz(Instant, Instant, boolean) */ public Instant getSofZmanBiurChametzGRA() { - return getSofZmanBiurChametz(getSunrise(), getSunset(), true); + return getSofZmanBiurChametz(getSunriseBasedOnElevationSetting(), getSunsetBasedOnElevationSetting(), true); } /** * This method returns the latest time for burning chametz on Erev Pesach according to the opinion of the * Magen Avraham (MGA) based on alos being {@link - * getAlos72Minutes() 72} minutes before {@link getSunrise() sunrise}. This time is 5 {@link + * getAlos72Minutes() 72} minutes before {@link getSunriseWithElevation() sunrise}. This time is 5 {@link * getShaahZmanis72Minutes() shaos zmaniyos} (temporal hours) after {@link getAlos72Minutes() dawn} based on the * opinion of the MGA that the day is calculated from a {@link getAlos72Minutes() dawn} of 72 minutes before sunrise to {@link * getTzais72Minutes() nightfall} of 72 minutes after sunset. This returns the time of 5 * {@link getShaahZmanis72Minutes()} @@ -3438,7 +3438,7 @@ public Instant getSofZmanBiurChametzMGA72Minutes() { /** * This method returns the latest time for burning chametz on Erev Pesach according to the opinion of the * Magen Avraham (MGA) based on alos being {@link - * getAlos72Zmanis() 72} minutes zmanis before {@link getSunrise() sunrise}. This time is 5 {@link + * getAlos72Zmanis() 72} minutes zmanis before {@link getSunriseWithElevation() sunrise}. This time is 5 {@link * getShaahZmanis72MinutesZmanis() shaos zmaniyos} (temporal hours) after {@link getAlos72Zmanis() dawn} based on the * opinion of the MGA that the day is calculated from a {@link getAlos72Zmanis() dawn} of 72 minutes zmanis before sunrise to * {@link getTzais72Zmanis() nightfall} of 72 minutes zmanis after sunset. This returns the time of 5 * {@link @@ -3459,7 +3459,7 @@ public Instant getSofZmanBiurChametzMGA72MinutesZmanis() { /** * This method returns the latest time for burning chametz on Erev Pesach according to the opinion * of the Magen Avraham (MGA) based on alos - * being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunrise() sunrise}. This time is 5 + * being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunriseWithElevation() sunrise}. This time is 5 * {@link getShaahZmanis16Point1Degrees() shaos zmaniyos} (solar hours) after {@link getAlos16Point1Degrees() * dawn} based on the opinion of the MGA that the day is calculated from dawn to nightfall with both being 16.1° * below sunrise or sunset. This returns the time of 5 {@link getShaahZmanis16Point1Degrees()} after @@ -3511,7 +3511,7 @@ public long getShaahZmanisBaalHatanya() { /** * Returns the Baal Hatanya's alos * (dawn) calculated as the time when the sun is 16.9° below the eastern {@link GEOMETRIC_ZENITH geometric horizon} - * before {@link getSunrise() sunrise}. It is based on the calculation that the time between dawn and + * before {@link getSunriseWithElevation() sunrise}. It is based on the calculation that the time between dawn and * netz amiti (sunrise) is 72 minutes, the time that is takes to walk 4 mil at 18 minutes * a mil (Rambam and others). The sun's position at 72 * minutes before {@link getSunriseBaalHatanya netz amiti (sunrise)} in Jerusalem tzais (nightfall) when the sun is 6° below the western geometric horizon (90°) - * after {@link getSunset() sunset}. This tzais / nightfall based on the opinion of the tzais / nightfall based on the opinion of the Baal Hatanya. This calculation is based on the position of the * sun about 24 minutes after {@link getSeaLevelSunset() sunset} in Jerusalem around the equinox / equilux, which @@ -3773,7 +3773,7 @@ public Instant getSofZmanShmaMGA72MinutesToFixedLocalChatzos() { * This method returns Rav Moshe Feinstein's opinion of the * calculation of sof zman krias shema (latest time to recite Shema in the morning) according to the opinion * of the GRA that the day is calculated from sunrise to sunset, but - * calculated using the first half of the day only. The half a day starts at {@link getSunrise() sunrise} and + * calculated using the first half of the day only. The half a day starts at {@link getSunriseWithElevation() sunrise} and * ends at {@link getFixedLocalChatzosHayom() fixed local chatzos}. Sof zman Shema is 3 shaos zmaniyos (solar * hours) after sunrise or half of this half-day. * @@ -3781,12 +3781,12 @@ public Instant getSofZmanShmaMGA72MinutesToFixedLocalChatzos() { * as northern and southern locations even south of the Arctic Circle and north of the Antarctic Circle * where the sun may not reach low enough below the horizon for this calculation, a null will be * returned. See detailed explanation on top of the {@link AstronomicalCalendar} documentation. - * @see getSunrise() + * @see getSunriseWithElevation() * @see getFixedLocalChatzosHayom() * @see getHalfDayBasedZman(Instant, Instant, double) */ public Instant getSofZmanShmaGRASunriseToFixedLocalChatzos() { - return getHalfDayBasedZman(getSunrise(), getFixedLocalChatzosHayom(), 3); + return getHalfDayBasedZman(getSunriseBasedOnElevationSetting(), getFixedLocalChatzosHayom(), 3); } /** @@ -3794,19 +3794,19 @@ public Instant getSofZmanShmaGRASunriseToFixedLocalChatzos() { * calculation of sof zman tfila (zman tfilah (the latest time to recite the morning prayers)) * according to the opinion of the GRA that the day is * calculated from sunrise to sunset, but calculated using the first half of the day only. The half a day starts at - * {@link getSunrise() sunrise} and ends at {@link getFixedLocalChatzosHayom() fixed local chatzos}. Sof zman + * {@link getSunriseWithElevation() sunrise} and ends at {@link getFixedLocalChatzosHayom() fixed local chatzos}. Sof zman * tefila is 4 shaos zmaniyos (solar hours) after sunrise or 2/3 of this half-day. * * @return the Instant of the latest zman krias shema. If the calculation can't be computed such * as northern and southern locations even south of the Arctic Circle and north of the Antarctic Circle * where the sun may not reach low enough below the horizon for this calculation, a null will be * returned. See detailed explanation on top of the {@link AstronomicalCalendar} documentation. - * @see getSunrise() + * @see getSunriseWithElevation() * @see getFixedLocalChatzosHayom() * @see getHalfDayBasedZman(Instant, Instant, double) */ public Instant getSofZmanTfilaGRASunriseToFixedLocalChatzos() { - return getHalfDayBasedZman(getSunrise(), getFixedLocalChatzosHayom(), 4); + return getHalfDayBasedZman(getSunriseBasedOnElevationSetting(), getFixedLocalChatzosHayom(), 4); } /** @@ -3846,7 +3846,7 @@ public Instant getMinchaGedolaGRAFixedLocalChatzos30Minutes() { * @see getHalfDayBasedZman(Instant, Instant, double) */ public Instant getMinchaKetanaGRAFixedLocalChatzosToSunset() { - return getHalfDayBasedZman(getFixedLocalChatzosHayom(), getSunset(), 3.5); + return getHalfDayBasedZman(getFixedLocalChatzosHayom(), getSunsetBasedOnElevationSetting(), 3.5); } /** @@ -3867,11 +3867,11 @@ public Instant getMinchaKetanaGRAFixedLocalChatzosToSunset() { * @see getHalfDayBasedZman(Instant, Instant, double) */ public Instant getPlagHaminchaGRAFixedLocalChatzosToSunset() { - return getHalfDayBasedZman(getFixedLocalChatzosHayom(), getSunset(), 4.75); + return getHalfDayBasedZman(getFixedLocalChatzosHayom(), getSunsetBasedOnElevationSetting(), 4.75); } /** - * Method to return tzais (dusk) calculated as 50 minutes after {@link getSunset() sunset} or {@link + * Method to return tzais (dusk) calculated as 50 minutes after {@link getSunsetWithElevation() sunset} or {@link * getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} setting). This method returns * tzais (nightfall) based on the opinion of Rabbi Moshe Feinstein for the New York area. This time should * not be used for latitudes other than ones similar to the latitude of the NY area. @@ -3882,17 +3882,17 @@ public Instant getPlagHaminchaGRAFixedLocalChatzosToSunset() { * documentation. */ public Instant getTzais50Minutes() { - return getTimeOffset(getSunset(), 50 * MINUTE_MILLIS); + return getTimeOffset(getSunsetBasedOnElevationSetting(), 50 * MINUTE_MILLIS); } /** * A method for calculating samuch lemincha ketana, / near mincha ketana time that is half an hour before - * {@link getMinchaKetanaGRA()} or is 9 * shaos zmaniyos (solar hours) after the start of the day, calculated - * according to the GRA using a day starting at sunrise and ending at - * sunset. This is the time that eating or other activity can't begin prior to praying mincha. The calculation used - * is 9 * {@link getShaahZmanisGRA()} after {@link getSunrise() sunrise} or {@link getSunrise() elevation adjusted sunrise} - * (depending on the {@link isUseElevation()} setting). See the Mechaber and Mishna Berurah 232 and shaos zmaniyos (solar hours) after the start of + * the day, calculated according to the GRA using a day starting at + * sunrise and ending at sunset. This is the time that eating or other activity can't begin prior to praying mincha. + * The calculation used is 9 * {@link getShaahZmanisGRA()} after {@link getSunriseWithElevation() sunrise} or {@link + * getSunriseBasedOnElevationSetting() elevation adjusted sunrise} (depending on the {@link isUseElevation()} setting). See the + * Mechaber and Mishna Berurah 232 and 249:2. * * @see getShaahZmanisGRA() @@ -3904,7 +3904,7 @@ public Instant getTzais50Minutes() { * returned. See detailed explanation on top of the {@link AstronomicalCalendar} documentation. */ public Instant getSamuchLeMinchaKetanaGRA() { - return getSamuchLeMinchaKetana(getSunrise(), getSunset(), true); + return getSamuchLeMinchaKetana(getSunriseBasedOnElevationSetting(), getSunsetBasedOnElevationSetting(), true); } /** From 587d6d67ebe308be6b3bb724521f29027b1dd360 Mon Sep 17 00:00:00 2001 From: Moshe Dicker Date: Fri, 1 May 2026 11:44:06 -0400 Subject: [PATCH 4/7] Revert "ZmanimCalendar - Remove getSunriseWithElevation() and getSunsetWithElevation()" This reverts commit d8870e8f8fb43d87cb29be39f22e63b161133870. --- .../com/kosherjava/zmanim/ZmanimCalendar.java | 188 ++++++++++-------- 1 file changed, 102 insertions(+), 86 deletions(-) diff --git a/src/main/java/com/kosherjava/zmanim/ZmanimCalendar.java b/src/main/java/com/kosherjava/zmanim/ZmanimCalendar.java index 98dec99a..fef567ff 100644 --- a/src/main/java/com/kosherjava/zmanim/ZmanimCalendar.java +++ b/src/main/java/com/kosherjava/zmanim/ZmanimCalendar.java @@ -39,7 +39,7 @@ * >Shimush Zekeinim, Ch. 1, page 17 states that obstructing horizons should be factored into zmanim calculations. The * setting defaults to false (elevation will not be used for zmanim calculations besides sunrise and sunset), unless the * setting is changed to true in {@link setUseElevation(boolean)}. This will impact sunrise and sunset-based zmanim such as - * {@link getSunrise()}, {@link getSunset()}, {@link getSofZmanShmaGRA()}, alos-based + * {@link getSunriseWithElevation()}, {@link getSunsetWithElevation()}, {@link getSofZmanShmaGRA()}, alos-based * zmanim such as {@link getSofZmanShmaMGA72Minutes()} that are based on a fixed offset of sunrise or sunset and * zmanim based on a percentage of the day such as {@link ComprehensiveZmanimCalendar#getSofZmanShmaMGA90MinutesZmanis()} * that are based on sunrise and sunset. Even when set to true it will not impact zmanim that are a degree-based offset of @@ -252,28 +252,44 @@ public void setUseAstronomicalChatzosForOtherZmanim(boolean useAstronomicalChatz /** * This method will return {@link getSeaLevelSunrise() sea level sunrise} if {@link isUseElevation()} is false (the default), - * or elevation adjusted {@link getSunrise()} if it is true. This allows relevant zmanim in this and extending classes - * (such as the {@link ComprehensiveZmanimCalendar}) to automatically adjust to the elevation setting. + * or elevation adjusted {@link getSunriseWithElevation()} if it is true. This allows relevant zmanim in this and + * extending classes (such as the {@link ComprehensiveZmanimCalendar}) to automatically adjust to the elevation setting. + * + * @return {@link getSeaLevelSunrise()} if {@link isUseElevation()} is false (the default), or elevation adjusted + * {@link getSunriseWithElevation()} if it is true. + * @see getSunriseWithElevation() + */ + protected Instant getSunriseBasedOnElevationSetting() { + if (isUseElevation()) { + return super.getSunriseWithElevation(); + } + return getSeaLevelSunrise(); + } + + /** + * This method will return {@link getSeaLevelSunrise() sea level sunrise} if {@link isUseElevation()} is false (the default), + * or elevation adjusted {@link getSunriseWithElevation()} if it is true. This allows relevant zmanim + * in this and extending classes (such as the {@link ComprehensiveZmanimCalendar}) to automatically adjust to the elevation setting. * * @return {@link getSeaLevelSunset()} if {@link isUseElevation()} is false (the default), or elevation adjusted - * {@link getSunset()} if it is true. - * @see getSunset() + * {@link getSunsetWithElevation()} if it is true. + * @see getSunsetWithElevation() */ - /*protected Instant getSunset() { + protected Instant getSunsetBasedOnElevationSetting() { if (isUseElevation()) { - return super.getSunset(); + return super.getSunsetWithElevation(); } return getSeaLevelSunset(); - }*/ + } /** - * A method that returns tzais (nightfall) when the sun is {@link ZENITH_8_POINT_5 8.5°} below the {@link - * GEOMETRIC_ZENITH geometric horizon} (90°) after {@link getSunset() sunset}, a time that Rabbi Meir Posen in his the - * Ohr Meir calculated that 3 small stars are visible, which is - * later than the required 3 medium stars. This calculation is based on the sun's position below the horizon 36 minutes after - * {@link getSeaLevelSunrise() sunset} in Jerusalem around the equinox / equilux, which is - * 8.5° below {@link GEOMETRIC_ZENITH geometric zenith}. + * A method that returns tzais (nightfall) when the sun is {@link ZENITH_8_POINT_5 8.5°} below the + * {@link GEOMETRIC_ZENITH geometric horizon} (90°) after {@link getSunsetWithElevation() sunset}, a time that Rabbi + * Meir Posen in his the Ohr Meir calculated that 3 small + * stars are visible, which is later than the required 3 medium stars. This calculation is based on the sun's position below + * the horizon 36 minutes after {@link getSeaLevelSunrise() sunset} in Jerusalem around the equinox / equilux, which + * is 8.5° below {@link GEOMETRIC_ZENITH geometric zenith}. * * @return The Instant of nightfall. If the calculation can't be computed such as northern and southern * locations even south of the Arctic Circle and north of the Antarctic Circle where the sun may not reach @@ -287,11 +303,11 @@ public Instant getTzaisGeonim8Point5Degrees() { /** * Returns alos (dawn) based on the time when the sun is {@link ZENITH_16_POINT_1 16.1°} below the - * eastern {@link GEOMETRIC_ZENITH geometric horizon} before {@link getSunrise() sunrise}. This is based on the + * eastern {@link GEOMETRIC_ZENITH geometric horizon} before {@link getSunriseWithElevation() sunrise}. This is based on the * calculation that the time between dawn and sunrise (and sunset to nightfall) is 72 minutes, the time that is * takes to walk 4 mil at * 18 minutes a mil (Rambam and others). The sun's position - * below the horizon 72 minutes before {@link getSunrise() sunrise} in Jerusalem on the around the equinox / equilux is * 16.1° below {@link GEOMETRIC_ZENITH}. * @@ -307,7 +323,7 @@ public Instant getAlos16Point1Degrees() { } /** - * Method to return alos (dawn) calculated as 72 minutes before {@link getSunrise() sunrise} or + * Method to return alos (dawn) calculated as 72 minutes before {@link getSunriseWithElevation() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting). This time * is based on the time to walk the distance of 4 mil at 18 minutes a mil. The @@ -321,24 +337,23 @@ public Instant getAlos16Point1Degrees() { * documentation. */ public Instant getAlos72Minutes() { - return getTimeOffset(getSunrise(), -72 * MINUTE_MILLIS); + return getTimeOffset(getSunriseBasedOnElevationSetting(), -72 * MINUTE_MILLIS); } /** - * This method returns {@link getSunTransit() Astronomical chatzos hayom} if the {@link - * com.kosherjava.zmanim.util.AstronomicalCalculator calculator} class used supports it and {@link isUseAstronomicalChatzos() - * isUseAstronomicalChatzos()} is set to true or the {@link getChatzosHayomAsHalfDay() halfway point between sunrise and - * sunset} if it does not support it, or it is not configured to use it. There are currently two {@link - * com.kosherjava.zmanim.util.AstronomicalCalculator calculators} available in the API, the default {@link + * This method returns {@link getSunTransit() Astronomical chatzos hayom} if the + * {@link com.kosherjava.zmanim.util.AstronomicalCalculator calculator} class used supports it and + * {@link isUseAstronomicalChatzos() isUseAstronomicalChatzos()} is set to true or the {@link getChatzosHayomAsHalfDay() + * halfway point between sunrise and sunset} if it does not support it, or it is not configured to use it. There are currently + * two {@link com.kosherjava.zmanim.util.AstronomicalCalculator calculators} available in the API, the default {@link * com.kosherjava.zmanim.util.NOAACalculator NOAA calculator} and the {@link com.kosherjava.zmanim.util.SunTimesCalculator USNO * calculator}. The USNO calculator calculates chatzos as halfway between sunrise and sunset (identical to six shaos * zmaniyos after sunrise), while the NOAACalculator calculates it more accurately as {@link getSunTransit() astronomical - * chatzos}. See The Definition of - * Chatzos for a detailed explanation of the ways to calculate Chatzos. Since half-day chatzos can - * be null in the Arctic on a day when either sunrise or sunset did not happen and astronomical chatzos can - * be calculated even in the Arctic, if half-day chatzos calculates as null and astronomical - * chatzos is supported by the calculator, astronomical chatzos will be returned to avoid returning a - * null. + * chatzos}. See The Definition of Chatzos + * for a detailed explanation of the ways to calculate Chatzos. Since half-day chatzos can be null in + * the Arctic on a day when either sunrise or sunset did not happen and astronomical chatzos can be calculated even in the + * Arctic, if half-day chatzos calculates as null and astronomical chatzos is supported by the + * calculator, astronomical chatzos will be returned to avoid returning a null. * * @see getSunTransit() * @see getChatzosHayomAsHalfDay() @@ -363,11 +378,11 @@ public Instant getChatzosHayom() { } /** - * A method that returns chatzos halayla at the end of the day (the last zman of the day returned by the - * calendar, that may actually be after midnight of the day it is being calculated for). For example, if calculating it for the - * date of Erev Pesach, the calculation will be for Lail Pesach to allow you to use the zman as - * sof zman achilas chametz. {@link getSolarMidnight() Astronomical chatzos halayla} will be returned if the - * {@link com.kosherjava.zmanim.util.AstronomicalCalculator calculator} class used supports it and {@link + * A method that returns chatzos halayla at the end of the day (the last zman of the day + * returned by the calendar, that may actually be after midnight of the day it is being calculated for). For example, if + * calculating it for the date of Erev Pesach, the calculation will be for Lail Pesach to allow you to use the + * zman as sof zman achilas chametz. {@link getSolarMidnight() Astronomical chatzos halayla} will be + * returned if the {@link com.kosherjava.zmanim.util.AstronomicalCalculator calculator} class used supports it and {@link * isUseAstronomicalChatzos() isUseAstronomicalChatzos()} is set to true. Otherwise the {@link #getChatzos(Instant, * Instant) halfway point} between sunset and the following day's sunrise, if it does not support it, or it is not configured to * use it. There are currently two {@link com.kosherjava.zmanim.util.AstronomicalCalculator calculators} available in the API, @@ -488,9 +503,9 @@ public Instant getChatzosHayomAsHalfDay() { * hours), and the latest zman krias shema is calculated as 3 of those shaos zmaniyos after the beginning of * the day. If {@link isUseAstronomicalChatzosForOtherZmanim()} is true, the 3 shaos zmaniyos will be * based on 1/6 of the time between sunrise and {@link getSunTransit() astronomical chatzos}. As an example, passing - * {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link getSeaLevelSunrise() sea level - * sunrise} and {@link getSeaLevelSunset() sea level sunset} to this method (or {@link getSunrise()} and - * {@link getSunset()} that is driven off the {@link isUseElevation()} setting) will return sof zman + * {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunrise() sea level + * sunrise} and {@link getSeaLevelSunset() sea level sunset} to this method (or {@link getSunriseBasedOnElevationSetting()} and + * {@link getSunsetBasedOnElevationSetting()} that is driven off the {@link isUseElevation()} setting) will return sof zman * krias shema according to the opinion of the GRA. In cases where * the start and end dates are not synchronous such as in {@link ComprehensiveZmanimCalendar * #getSofZmanShmaAlos16Point1ToTzaisGeonim7Point083Degrees()} false should be passed to the synchronous parameter @@ -521,10 +536,9 @@ public Instant getSofZmanShma(Instant startOfDay, Instant endOfDay, boolean sync } /** - * A generic method for calculating the latest zman krias shema that calls {@link getSofZmanShma(Instant, Instant, - * boolean)} passing false to the synchronous parameter since there is no way to know if the start and end of the - * day are synchronous. Passing true when they are not synchronous is too much of a risk. See information on that method for - * more details. + * A generic method for calculating the latest zman krias shema that calls {@link getSofZmanShma(Instant, Instant, boolean)} + * passing false to the synchronous parameter since there is no way to know if the start and end of the day are + * synchronous. Passing true when they are not synchronous is too much of a risk. See information on that method for more details. * @param startOfDay * the start of day for calculating zman krias shema. This can be sunrise or any alos passed * to this method. @@ -542,12 +556,13 @@ public Instant getSofZmanShma(Instant startOfDay, Instant endOfDay) { } /** - * This method returns the latest zman krias shema (time to recite shema in the morning) that is 3 * {@link - * getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunrise() sunrise} or {@link getSeaLevelSunrise() - * sea level sunrise} (depending on the {@link isUseElevation()} setting), according to the GRA. The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} - * to {@link getSeaLevelSunset() sea level sunset} or from {@link getSunrise() sunrise} to {@link getSunset() sunset} - * (depending on the {@link isUseElevation()} setting). + * This method returns the latest zman krias shema (time to recite shema in the morning) that is 3 * + * {@link getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunriseWithElevation() sunrise} or + * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting), according + * to the GRA. + * The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level + * sunset} or from {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the + * {@link isUseElevation()} setting). * * @see getSofZmanShma(Instant, Instant) * @see getShaahZmanisGRA() @@ -559,16 +574,17 @@ public Instant getSofZmanShma(Instant startOfDay, Instant endOfDay) { * of the {@link AstronomicalCalendar} documentation. */ public Instant getSofZmanShmaGRA() { - return getSofZmanShma(getSunrise(), getSunset(), true); + return getSofZmanShma(getSunriseBasedOnElevationSetting(), getSunsetBasedOnElevationSetting(), true); } /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the opinion of * the Magen Avraham (MGA) based on alos being {@link - * getAlos72Minutes() 72} minutes before {@link getSunrise() sunrise}. This time is 3 {@link getShaahZmanis72Minutes() - * shaos zmaniyos} (solar hours) after {@link getAlos72Minutes() dawn} based on the opinion of the MGA that the day is - * calculated from a {@link getAlos72Minutes() dawn} of 72 minutes before sunrise to {@link getTzais72Minutes() nightfall} of - * 72 minutes after sunset. This returns the time of 3 * {@link getShaahZmanis72Minutes()} after {@link getAlos72Minutes() dawn}. + * getAlos72Minutes() 72} minutes before {@link getSunriseWithElevation() sunrise}. This time is 3 {@link + * getShaahZmanis72Minutes() shaos zmaniyos} (solar hours) after {@link getAlos72Minutes() dawn} based on the opinion + * of the MGA that the day is calculated from a {@link getAlos72Minutes() dawn} of 72 minutes before sunrise to + * {@link getTzais72Minutes() nightfall} of 72 minutes after sunset. This returns the time of 3 * {@link + * getShaahZmanis72Minutes()} after {@link getAlos72Minutes() dawn}. * * @return the Instant of the latest zman krias shema. If the calculation can't be computed such * as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one where @@ -592,7 +608,7 @@ public Instant getSofZmanShmaMGA72Minutes() { * 235:3, the Pri Megadim in Orach * Chaim 261:2 (see the Biur Halacha) and others (see Hazmanim Bahalacha 17:3 and 17:5) the 72 minutes are standard * clock minutes any time of the year in any location. Depending on the {@link isUseElevation()} setting, a 72-minute - * offset from either {@link getSunset() sunset} or {@link getSeaLevelSunset() sea level sunset} is used. + * offset from either {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunset() sea level sunset} is used. * * @see ComprehensiveZmanimCalendar#getTzais16Point1Degrees() * @return the Instant representing 72 minutes after sunset. If the calculation can't be @@ -601,7 +617,7 @@ public Instant getSofZmanShmaMGA72Minutes() { * {@link AstronomicalCalendar} documentation. */ public Instant getTzais72Minutes() { - return getTimeOffset(getSunset(), 72 * MINUTE_MILLIS); + return getTimeOffset(getSunsetBasedOnElevationSetting(), 72 * MINUTE_MILLIS); } /** @@ -629,7 +645,7 @@ public Instant getCandleLighting() { * end of the day passed to this method. * The time from the start of day to the end of day are divided into 12 shaos zmaniyos (temporal hours), * and sof zman tfila is calculated as 4 of those shaos zmaniyos after the beginning of the day. - * As an example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link getSeaLevelSunrise() + * As an example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunrise() * sea level sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} * elevation setting) to this method will return zman tfilah according to the opinion of the GRA. This method's synchronous parameter indicates if the start @@ -786,11 +802,11 @@ public Instant getSofZmanTfila(Instant startOfDay, Instant endOfDay) { /** * This method returns the latest zman tfila (time to recite shema in the morning) that is 4 * - * {@link getShaahZmanisGRA() shaos zmaniyos }(solar hours) after {@link getSunrise() sunrise} or + * {@link getShaahZmanisGRA() shaos zmaniyos }(solar hours) after {@link getSunriseWithElevation() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting), according * to the GRA. * The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level - * sunset} or from {@link getSunrise() sunrise} to {@link getSunset() sunset} (depending on the + * sunset} or from {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the * {@link isUseElevation()} setting). * * @see getSofZmanTfila(Instant, Instant) @@ -802,7 +818,7 @@ public Instant getSofZmanTfila(Instant startOfDay, Instant endOfDay) { * {@link AstronomicalCalendar} documentation. */ public Instant getSofZmanTfilaGRA() { - return getSofZmanTfila(getSunrise(), getSunset(), true); + return getSofZmanTfila(getSunriseBasedOnElevationSetting(), getSunsetBasedOnElevationSetting(), true); } @@ -810,8 +826,8 @@ public Instant getSofZmanTfilaGRA() { * This method returns the latest zman tfila (time to recite shema in the morning) that is 4 * {@link * getShaahZmanis72Minutes() shaos zmaniyos} (solar hours) after {@link getAlos72Minutes()}, according to the * Magen Avraham (MGA). The day is calculated - * from 72 minutes before {@link getSunrise()} to 72 minutes after {@link - * getSunset()}. The use of elevation depends on the {@link isUseElevation()} setting). + * from 72 minutes before {@link getSunriseBasedOnElevationSetting()} to 72 minutes after {@link + * getSunsetBasedOnElevationSetting()}. The use of elevation depends on the {@link isUseElevation()} setting). * * @return the Instant of the latest zman tfila. If the calculation can't be computed such as in * the Arctic Circle where there is at least one day a year where the sun does not rise, and one where it @@ -830,7 +846,7 @@ public Instant getSofZmanTfilaMGA72Minutes() { * is 6.5 * shaos zmaniyos (temporal hours) after the start of the day, calculated using the start and end of the * day passed to this method. The time from the start of day to the end of day are divided into 12 shaos zmaniyos * (temporal hours), and mincha gedola is calculated as 6.5 of those shaos zmaniyos after the beginning - * of the day. As an example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or + * of the day. As an example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or * {@link getSeaLevelSunrise() sea level sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link * isUseElevation()} elevation setting) to this method will return mincha gedola according to the opinion of the * GRA. Alternatively, this method uses {@link @@ -897,14 +913,14 @@ public Instant getMinchaGedola(Instant startOfDay, Instant endOfDay) { /** * This method returns the latest mincha gedola,the earliest time one can pray mincha that is 6.5 * - * {@link getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunrise() sunrise} or + * {@link getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunriseWithElevation() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting), according * to the GRA. Mincha gedola is the earliest * time one can pray mincha. The Ramba"m is of the opinion that it is better to delay mincha until * {@link getMinchaKetanaGRA() mincha ketana GRA} while the Ra"sh, Tur, GRA and others are of the * opinion that mincha can be prayed lechatchila starting at mincha gedola. * The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level - * sunset} or {@link getSunrise() sunrise} to {@link getSunset() sunset} (depending on the {@link isUseElevation()} + * sunset} or {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()} * setting). * @todo Consider adjusting this to calculate the time as half an hour zmaniyos after either {@link * getSunTransit() astronomical chatzos} or {@link getChatzosHayomAsHalfDay() chatzos as half a day} @@ -920,7 +936,7 @@ public Instant getMinchaGedola(Instant startOfDay, Instant endOfDay) { * {@link AstronomicalCalendar} documentation. */ public Instant getMinchaGedolaGRA() { - return getMinchaGedola(getSunrise(), getSunset(), true); + return getMinchaGedola(getSunriseBasedOnElevationSetting(), getSunsetBasedOnElevationSetting(), true); } /** @@ -929,7 +945,7 @@ public Instant getMinchaGedolaGRA() { * start of the day, calculated using the start and end of the day passed to this method. * The time from the start of day to the end of day are divided into 12 shaos zmaniyos (temporal hours), and * samuch lemincha ketana is calculated as 9 of those shaos zmaniyos after the beginning of the day. - * For example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link getSeaLevelSunrise() sea + * For example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunrise() sea * level sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} elevation * setting) to this method will return samuch lemincha ketana according to the opinion of the * GRA. See the shaos zmaniyos (temporal hours), and * mincha ketana is calculated as 9.5 of those shaos zmaniyos after the beginning of the day. As an - * example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link getSeaLevelSunrise() sea + * example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunrise() sea * level sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} * elevation setting) to this method will return mincha ketana according to the opinion of the * GRA. This method's synchronous parameter indicates if the start @@ -1047,12 +1063,12 @@ public Instant getMinchaKetana(Instant startOfDay, Instant endOfDay) { /** * This method returns mincha ketana,the preferred earliest time to pray mincha in the * opinion of the Rambam and others, that is 9.5 - * * {@link getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunrise() sunrise} or + * * {@link getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunriseWithElevation() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting), according * to the GRA. For more information on this see the * documentation on {@link getMinchaGedolaGRA() mincha gedola}. * The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level - * sunset} or from {@link getSunrise() sunrise} to {@link getSunset() sunset} (depending on the {@link isUseElevation()} + * sunset} or from {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()} * setting. * * @see getMinchaKetana(Instant, Instant) @@ -1065,7 +1081,7 @@ public Instant getMinchaKetana(Instant startOfDay, Instant endOfDay) { * {@link AstronomicalCalendar} documentation. */ public Instant getMinchaKetanaGRA() { - return getMinchaKetana(getSunrise(), getSunset(), true); + return getMinchaKetana(getSunriseBasedOnElevationSetting(), getSunsetBasedOnElevationSetting(), true); } /** @@ -1074,7 +1090,7 @@ public Instant getMinchaKetanaGRA() { * the day passed to the method. * The time from the start of day to the end of day are divided into 12 shaos zmaniyos (temporal hours), and * plag hamincha is calculated as 10.75 of those shaos zmaniyos after the beginning of the day. As an - * example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link getSeaLevelSunrise() sea level + * example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunrise() sea level * sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} elevation * setting) to this method will return plag mincha according to the opinion of the * GRA. This method's synchronous parameter indicates if the start @@ -1128,11 +1144,11 @@ public Instant getPlagHamincha(Instant startOfDay, Instant endOfDay) { /** * This method returns plag hamincha, that is 10.75 * {@link getShaahZmanisGRA() shaos zmaniyos} - * (solar hours) after {@link getSunrise() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on + * (solar hours) after {@link getSunriseWithElevation() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on * the {@link isUseElevation()} setting), according to the GRA. Plag hamincha is the earliest time that Shabbos can be started. * The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level - * sunset} or {@link getSunrise() sunrise} to {@link getSunset() sunset} (depending on the {@link isUseElevation()} + * sunset} or {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()} * * @see getPlagHamincha(Instant, Instant, boolean) * @see getPlagHamincha(Instant, Instant) @@ -1143,14 +1159,14 @@ public Instant getPlagHamincha(Instant startOfDay, Instant endOfDay) { * {@link AstronomicalCalendar} documentation. */ public Instant getPlagHaminchaGRA() { - return getPlagHamincha(getSunrise(), getSunset(), true); + return getPlagHamincha(getSunriseBasedOnElevationSetting(), getSunsetBasedOnElevationSetting(), true); } /** * A method that returns a shaah zmanis ({@link getTemporalHour(Instant, Instant) temporal hour}) according to * the opinion of the GRA. This calculation divides the day * based on the opinion of the GRA that the day runs from from {@link getSeaLevelSunrise() sea level - * sunrise} to {@link getSeaLevelSunset() sea level sunset} or {@link getSunrise() sunrise} to {@link getSunset() + * sunrise} to {@link getSeaLevelSunset() sea level sunset} or {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() * sunset} (depending on the {@link isUseElevation()} setting). The day is split into 12 equal parts with each one * being a shaah zmanis. This method is similar to {@link getTemporalHour()}, but can account for elevation. * @@ -1164,13 +1180,13 @@ public Instant getPlagHaminchaGRA() { * @see ComprehensiveZmanimCalendar#getShaahZmanisBaalHatanya() */ public long getShaahZmanisGRA() { - return getTemporalHour(getSunrise(), getSunset()); + return getTemporalHour(getSunriseBasedOnElevationSetting(), getSunsetBasedOnElevationSetting()); } /** * A utility method to return alos (dawn) or tzais (dusk) based on a fractional day offset. As an * example passing 1.5 to this method as done in the {@link ComprehensiveZmanimCalendar#getTzais90Zmanis()} will return - * the time 90 minutes zmaniyos after {@link getSunset()}, a zman known as + * the time 90 minutes zmaniyos after {@link getSunsetBasedOnElevationSetting()}, a zman known as * the achtel zman or 1/8th of the length of the day (12 * 60 = 720-minute day / 8 = 90 or 1.5 hours * zmaniyos) after sunset. * @param hours the number of shaos zmaniyos (temporal hours) before sunrise or after sunset that defines dawn @@ -1193,9 +1209,9 @@ public Instant getZmanisBasedOffset(double hours) { } if (hours > 0) { - return getTimeOffset(getSunset(), (long) (shaahZmanis * hours)); + return getTimeOffset(getSunsetBasedOnElevationSetting(), (long) (shaahZmanis * hours)); } else { - return getTimeOffset(getSunrise(), (long) (shaahZmanis * hours)); + return getTimeOffset(getSunriseBasedOnElevationSetting(), (long) (shaahZmanis * hours)); } } @@ -1203,9 +1219,9 @@ public Instant getZmanisBasedOffset(double hours) { * A method that returns a shaah zmanis (temporal hour) according to the opinion of the Magen Avraham (MGA) based on a 72-minute alos * and tzais. This calculation divides the day that runs from dawn to dusk (for sof zman krias shema and - * tfila). Dawn for this calculation is 72 minutes before {@link getSunrise() sunrise} or {@link getSeaLevelSunrise() + * tfila). Dawn for this calculation is 72 minutes before {@link getSunriseWithElevation() sunrise} or {@link getSeaLevelSunrise() * sea level sunrise} (depending on the {@link isUseElevation()} elevation setting) and dusk is 72 minutes after {@link - * getSunset() sunset} or {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} elevation + * getSunsetWithElevation() sunset} or {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} elevation * setting). This day is split into 12 equal parts with each part being a shaah zmanis. Alternate methods of calculating * a shaah zmanis according to the Magen Avraham (MGA) are available in the subclass {@link ComprehensiveZmanimCalendar}. * @@ -1269,7 +1285,7 @@ public void setCandleLightingOffset(double candleLightingOffset) { /** * This is a utility method to determine if the current Instant passed in has a melacha (work) prohibition. * Since there are many opinions on the time of tzais, the tzais for the current day has to be passed to this - * class. Sunset is the classes current day's {@link getSunset() elevation adjusted sunset} that observes the + * class. Sunset is the classes current day's {@link getSunsetBasedOnElevationSetting() elevation adjusted sunset} that observes the * {@link isUseElevation()} settings. The {@link JewishCalendar#getInIsrael()} will be set by the inIsrael parameter. * * @param currentTime the current time @@ -1288,7 +1304,7 @@ public boolean isAssurBemlacha(Instant currentTime, Instant tzais, boolean inIsr jewishCalendar.setInIsrael(inIsrael); - if (jewishCalendar.hasCandleLighting() && currentTime.compareTo(getSunset()) >= 0) { //erev shabbos, YT or YT sheni and after shkiah + if (jewishCalendar.hasCandleLighting() && currentTime.compareTo(getSunsetBasedOnElevationSetting()) >= 0) { //erev shabbos, YT or YT sheni and after shkiah return true; } @@ -1325,7 +1341,7 @@ public boolean isAssurBemlacha(Instant currentTime, Instant tzais, boolean inIsr * computed such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one * where it does not set, a null will be returned. See detailed explanation on top of the page. * - * @see getSunrise() + * @see getSunriseWithElevation() * @see getSeaLevelSunrise() * @see getSunsetBaalHatanya() * @see ZENITH_1_POINT_583 @@ -1356,7 +1372,7 @@ protected Instant getSunriseBaalHatanya() { * rise, and one where it does not set, a null will be returned. See detailed explanation on top of * the {@link AstronomicalCalendar} documentation. * - * @see getSunset() + * @see getSunsetWithElevation() * @see getSeaLevelSunset() * @see getSunriseBaalHatanya() * @see ZENITH_1_POINT_583 @@ -1369,7 +1385,7 @@ protected Instant getSunsetBaalHatanya() { * A generic utility method for calculating any shaah zmanis (temporal hour) based zman with the day * defined as the start and end of day (or night) and the number of shaos zmaniyos passed to the method. This * simplifies the code in other methods such as {@link getPlagHamincha(Instant, Instant)} and cuts down on code replication. - * As an example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link + * As an example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link * getSeaLevelSunrise() sea level sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link * isUseElevation()} elevation setting) and 10.75 hours to this method will return plag mincha according to the * opinion of the GRA. From e2dd741787033681195c984b9c380f1ca563237e Mon Sep 17 00:00:00 2001 From: Moshe Dicker Date: Fri, 1 May 2026 11:44:07 -0400 Subject: [PATCH 5/7] Revert "JavaDoc changes for recent AstronomicalCalendar changes" This reverts commit e5b6076c9da806516a38a9a07b50c083c515f337. --- .../zmanim/AstronomicalCalendar.java | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java b/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java index 3297ea82..bc0185f2 100644 --- a/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java +++ b/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java @@ -30,8 +30,8 @@ import com.kosherjava.zmanim.util.ZmanimFormatter; /** - * A Java calendar that calculates astronomical times such as {@link getSunrise() sunrise}, {@link - * getSunset() sunset} and twilight times. This class contains a {@link getLocalDate() LocalDate} and can therefore + * A Java calendar that calculates astronomical times such as {@link getSunriseWithElevation() sunrise}, {@link + * getSunsetWithElevation() sunset} and twilight times. This class contains a {@link getLocalDate() LocalDate} and can therefore * use the standard Calendar functionality to change dates etc. The calculation engine used to calculate the astronomical times can * be changed to a different implementation by implementing the abstract {@link AstronomicalCalculator} and setting it withthe {@link * setAstronomicalCalculator(AstronomicalCalculator)}. A number of different calculation engine implementations are included in the @@ -142,7 +142,7 @@ public Instant getSunrise() { * @return the Instant representing the exact sea-level sunrise time. If the calculation can't be computed * such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one * where it does not set, a null will be returned. See detailed explanation on top of the page. - * @see getSunrise() + * @see getSunriseWithElevation() * @see getUTCSeaLevelSunrise(double) * @see getSeaLevelSunset() */ @@ -224,7 +224,7 @@ public Instant getSunset() { * @return the Instant representing the exact sea-level sunset time. If the calculation can't be computed * such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one * where it does not set, a null will be returned. See detailed explanation on top of the page. - * @see getSunset() + * @see getSunsetWithElevation() * @see getUTCSeaLevelSunset(double) */ public Instant getSeaLevelSunset() { @@ -303,15 +303,15 @@ public static Instant getTimeOffset(Instant time, long offsetMillis) { } /** - * A utility method that returns the time of an offset by degrees below or above the horizon of {@link getSunrise() + * A utility method that returns the time of an offset by degrees below or above the horizon of {@link getSunriseWithElevation() * sunrise}. Note that the degree offset is from the vertical, so for a calculation of 14° before sunrise, an offset of 14 * + {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a parameter. * * @param offsetZenith - * the degrees before {@link getSunrise()} to use in the calculation. For time after sunrise use negative + * the degrees before {@link getSunriseWithElevation()} to use in the calculation. For time after sunrise use negative * numbers. Note that the degree offset is from the vertical, so for a calculation of 14° before sunrise, an offset * of 14 + {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a parameter. - * @return The {@link java.time.Instant} of the offset after (or before) {@link getSunrise()}. If the calculation + * @return The {@link java.time.Instant} of the offset after (or before) {@link getSunriseWithElevation()}. If the calculation * can't be computed such as in the Arctic Circle where there is at least one day a year where the sun does * not rise, and one where it does not set, a null will be returned. See detailed explanation * on top of the page. @@ -323,15 +323,15 @@ public Instant getSunriseOffsetByDegrees(double offsetZenith) { } /** - * A utility method that returns the time of an offset by degrees below or above the horizon of {@link getSunset() + * A utility method that returns the time of an offset by degrees below or above the horizon of {@link getSunsetWithElevation() * sunset}. Note that the degree offset is from the vertical, so for a calculation of 14° after sunset, an offset of 14 + * {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a parameter. * * @param offsetZenith - * the degrees after {@link getSunset()} to use in the calculation. For time before sunset use negative + * the degrees after {@link getSunsetWithElevation()} to use in the calculation. For time before sunset use negative * numbers. Note that the degree offset is from the vertical, so for a calculation of 14° after sunset, an offset * of 14 + {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a parameter. - * @return The {@link java.time.Instant} of the offset after (or before) {@link getSunset()}. If the calculation + * @return The {@link java.time.Instant} of the offset after (or before) {@link getSunsetWithElevation()}. If the calculation * can't be computed such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and * and one where it does not set, a null will be returned. See detailed explanation on top of the page. */ @@ -449,7 +449,7 @@ public long getTemporalHour() { /** * A utility method that will allow the calculation of a temporal (solar) hour based on the sunrise and sunset passed as * parameters to this method. An example of the use of this method would be the calculation of a elevation adjusted temporal - * hour by passing in {@link getSunrise() sunrise} and {@link getSunset() sunset} as parameters. + * hour by passing in {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} as parameters. * * @param startOfDay * The start of the day. From 4bf454cd6094b175c408d9937ae9dae39b8fdc13 Mon Sep 17 00:00:00 2001 From: Moshe Dicker Date: Fri, 1 May 2026 11:44:09 -0400 Subject: [PATCH 6/7] Revert "AstronomicalCalendar - Remove getSunriseWithElevation() and getSunsetWithElevation()" This reverts commit 6f1da01fa51a0bc8cb49a739a286a1726b078392. --- .../zmanim/AstronomicalCalendar.java | 76 +++++++++++++------ 1 file changed, 54 insertions(+), 22 deletions(-) diff --git a/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java b/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java index bc0185f2..31332152 100644 --- a/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java +++ b/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java @@ -110,12 +110,12 @@ public class AstronomicalCalendar implements Cloneable { private AstronomicalCalculator astronomicalCalculator; /** - * The method returns an Instant representing the {@link AstronomicalCalculator getElevationAdjustment(double) - * elevation adjusted} sunrise time. The zenith used for the calculation uses {@link GEOMETRIC_ZENITH geometric zenith} of - * 90° plus {@link AstronomicalCalculator#getElevationAdjustment(double)}. This is adjusted by the {@link - * AstronomicalCalculator} to add approximately 50/60 of a degree to account for 34 archminutes of refraction and 16 archminutes - * for the sun's radius for a total of {@link AstronomicalCalculator#adjustZenith 90.83333°}. See documentation for the - * specific implementation of the {@link AstronomicalCalculator} that you are using. + * The getSunriseWithElevation method returns a Instant representing the {@link AstronomicalCalculator + * #getElevationAdjustment(double) elevation adjusted} sunrise time. The zenith used for the calculation uses {@link + * GEOMETRIC_ZENITH geometric zenith} of 90° plus {@link AstronomicalCalculator#getElevationAdjustment(double)}. This is + * adjusted by the {@link AstronomicalCalculator} to add approximately 50/60 of a degree to account for 34 archminutes of + * refraction and 16 archminutes for the sun's radius for a total of {@link AstronomicalCalculator#adjustZenith 90.83333°}. + * See documentation for the specific implementation of the {@link AstronomicalCalculator} that you are using. * * @return the Instant representing the exact sunrise time. If the calculation can't be computed such as in the * Arctic Circle where there is at least one day a year where the sun does not rise, and one where it does not set, a @@ -124,13 +124,28 @@ public class AstronomicalCalendar implements Cloneable { * @see getSeaLevelSunrise() * @see getUTCSunrise(double) */ - public Instant getSunrise() { - double sunrise = getUTCSunrise(GEOMETRIC_ZENITH); - if (Double.isNaN(sunrise)) { + public Instant getSunriseWithElevation() { + double sunrise = getUTCSunrise(GEOMETRIC_ZENITH); + if (Double.isNaN(sunrise)) { return null; } else { return getInstantFromTime(sunrise, SolarEvent.SUNRISE); } + } + /** + * @deprecated Use {@link getSunriseWithElevation()} instead. This method already accounts for the observer's elevation, but the + * name does not clearly indicate this behavior. The replacement method has a clearer and more descriptive name. + * + * @return the Instant representing the exact sunrise time. If the calculation can't be computed such as + * in the Arctic Circle where there is at least one day a year where the sun does not rise, and one where it + * does not set, a null will be returned. See detailed explanation on top of the page. + * @see AstronomicalCalculator#adjustZenith(double, double) + * @see getSeaLevelSunrise() + * @see getUTCSunrise(double) + */ + @Deprecated(forRemoval = false) + public Instant getSunrise() { + return getSunriseWithElevation(); } /** @@ -187,14 +202,15 @@ public Instant getBeginNauticalTwilight() { public Instant getBeginAstronomicalTwilight() { return getSunriseOffsetByDegrees(ASTRONOMICAL_ZENITH); } - + /** - * The method returns an Instant representing the {@link AstronomicalCalculator#getElevationAdjustment(double) - * elevation adjusted} sunset time. The zenith used for the calculation uses {@link GEOMETRIC_ZENITH geometric zenith} of - * 90° plus {@link AstronomicalCalculator #getElevationAdjustment(double)}. This is adjusted by the {@link - * AstronomicalCalculator} to add approximately 50/60 of a degree to account for 34 archminutes of refraction and 16 archminutes - * for the sun's radius for a total of {@link AstronomicalCalculator#adjustZenith(double, double) 90.83333°}. See - * documentation for the specific implementation of the {@link AstronomicalCalculator} that you are using. + * The getSunsetWithElevation method returns an Instant representing the + * {@link AstronomicalCalculator#getElevationAdjustment(double) elevation adjusted} sunset time. The zenith used for the + * calculation uses {@link GEOMETRIC_ZENITH geometric zenith} of 90° plus {@link AstronomicalCalculator + * #getElevationAdjustment(double)}. This is adjusted by the {@link AstronomicalCalculator} to add approximately 50/60 of a + * degree to account for 34 archminutes of refraction and 16 archminutes for the sun's radius for a total of {@link + * AstronomicalCalculator#adjustZenith(double, double) 90.83333°}. See documentation for the specific implementation of the + * {@link AstronomicalCalculator} that you are using. * Note: In certain cases the calculates sunset will occur before sunrise. This will typically happen when a time zone other than * the local timezone is used (calculating Los Angeles sunset using a GMT time zone for example). In this case the sunset date * will be incremented to the following date. @@ -206,13 +222,29 @@ public Instant getBeginAstronomicalTwilight() { * @see getSeaLevelSunset() * @see getUTCSunset(double) */ + public Instant getSunsetWithElevation() { + double sunset = getUTCSunset(GEOMETRIC_ZENITH); + if (Double.isNaN(sunset)) { + return null; + } else { + return getInstantFromTime(sunset, SolarEvent.SUNSET); + } + } + + /** + * @deprecated Use {@link getSunsetWithElevation()} instead. This method already accounts for the observer's elevation, but its + * name does not clearly reflect that behavior. The replacement method provides a more accurate and descriptive name. + * + * @return the Instant representing the exact sunset time. If the calculation can't be computed such as in the Arctic + * Circle where there is at least one day a year where the sun does not rise, and one where it does not set, a + * null will be returned. See detailed explanation on top of the page. + * @see AstronomicalCalculator#adjustZenith(double, double) + * @see getSeaLevelSunset() + * @see getUTCSunset(double) + */ + @Deprecated(forRemoval = false) public Instant getSunset() { - double sunset = getUTCSunset(GEOMETRIC_ZENITH); - if (Double.isNaN(sunset)) { - return null; - } else { - return getInstantFromTime(sunset, SolarEvent.SUNSET); - } + return getSunsetWithElevation(); } /** From 7804fb973668848755eae1306b23c856bde38a7d Mon Sep 17 00:00:00 2001 From: Moshe Dicker Date: Fri, 1 May 2026 11:53:26 -0400 Subject: [PATCH 7/7] rename getSunsetWithElevation/getSunriseWithElevation --- .../zmanim/AstronomicalCalendar.java | 63 +++----- .../zmanim/ComprehensiveZmanimCalendar.java | 136 +++++++++--------- .../com/kosherjava/zmanim/ZmanimCalendar.java | 74 +++++----- .../RegressionTestFileWriter.java | 2 +- .../util/SerializationRegressionTest.java | 2 +- 5 files changed, 123 insertions(+), 154 deletions(-) diff --git a/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java b/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java index 31332152..bb303d36 100644 --- a/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java +++ b/src/main/java/com/kosherjava/zmanim/AstronomicalCalendar.java @@ -30,8 +30,8 @@ import com.kosherjava.zmanim.util.ZmanimFormatter; /** - * A Java calendar that calculates astronomical times such as {@link getSunriseWithElevation() sunrise}, {@link - * getSunsetWithElevation() sunset} and twilight times. This class contains a {@link getLocalDate() LocalDate} and can therefore + * A Java calendar that calculates astronomical times such as {@link getSunrise() sunrise}, {@link + * getSunset() sunset} and twilight times. This class contains a {@link getLocalDate() LocalDate} and can therefore * use the standard Calendar functionality to change dates etc. The calculation engine used to calculate the astronomical times can * be changed to a different implementation by implementing the abstract {@link AstronomicalCalculator} and setting it withthe {@link * setAstronomicalCalculator(AstronomicalCalculator)}. A number of different calculation engine implementations are included in the @@ -110,7 +110,7 @@ public class AstronomicalCalendar implements Cloneable { private AstronomicalCalculator astronomicalCalculator; /** - * The getSunriseWithElevation method returns a Instant representing the {@link AstronomicalCalculator + * The getSunrise method returns a Instant representing the {@link AstronomicalCalculator * #getElevationAdjustment(double) elevation adjusted} sunrise time. The zenith used for the calculation uses {@link * GEOMETRIC_ZENITH geometric zenith} of 90° plus {@link AstronomicalCalculator#getElevationAdjustment(double)}. This is * adjusted by the {@link AstronomicalCalculator} to add approximately 50/60 of a degree to account for 34 archminutes of @@ -124,7 +124,7 @@ public class AstronomicalCalendar implements Cloneable { * @see getSeaLevelSunrise() * @see getUTCSunrise(double) */ - public Instant getSunriseWithElevation() { + public Instant getSunrise() { double sunrise = getUTCSunrise(GEOMETRIC_ZENITH); if (Double.isNaN(sunrise)) { return null; @@ -132,21 +132,6 @@ public Instant getSunriseWithElevation() { return getInstantFromTime(sunrise, SolarEvent.SUNRISE); } } - /** - * @deprecated Use {@link getSunriseWithElevation()} instead. This method already accounts for the observer's elevation, but the - * name does not clearly indicate this behavior. The replacement method has a clearer and more descriptive name. - * - * @return the Instant representing the exact sunrise time. If the calculation can't be computed such as - * in the Arctic Circle where there is at least one day a year where the sun does not rise, and one where it - * does not set, a null will be returned. See detailed explanation on top of the page. - * @see AstronomicalCalculator#adjustZenith(double, double) - * @see getSeaLevelSunrise() - * @see getUTCSunrise(double) - */ - @Deprecated(forRemoval = false) - public Instant getSunrise() { - return getSunriseWithElevation(); - } /** * A method that returns the sunrise without {@link AstronomicalCalculator#getElevationAdjustment(double) elevation @@ -157,7 +142,7 @@ public Instant getSunrise() { * @return the Instant representing the exact sea-level sunrise time. If the calculation can't be computed * such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one * where it does not set, a null will be returned. See detailed explanation on top of the page. - * @see getSunriseWithElevation() + * @see getSunrise() * @see getUTCSeaLevelSunrise(double) * @see getSeaLevelSunset() */ @@ -204,7 +189,7 @@ public Instant getBeginAstronomicalTwilight() { } /** - * The getSunsetWithElevation method returns an Instant representing the + * The getSunset method returns an Instant representing the * {@link AstronomicalCalculator#getElevationAdjustment(double) elevation adjusted} sunset time. The zenith used for the * calculation uses {@link GEOMETRIC_ZENITH geometric zenith} of 90° plus {@link AstronomicalCalculator * #getElevationAdjustment(double)}. This is adjusted by the {@link AstronomicalCalculator} to add approximately 50/60 of a @@ -222,7 +207,7 @@ public Instant getBeginAstronomicalTwilight() { * @see getSeaLevelSunset() * @see getUTCSunset(double) */ - public Instant getSunsetWithElevation() { + public Instant getSunset() { double sunset = getUTCSunset(GEOMETRIC_ZENITH); if (Double.isNaN(sunset)) { return null; @@ -230,23 +215,7 @@ public Instant getSunsetWithElevation() { return getInstantFromTime(sunset, SolarEvent.SUNSET); } } - - /** - * @deprecated Use {@link getSunsetWithElevation()} instead. This method already accounts for the observer's elevation, but its - * name does not clearly reflect that behavior. The replacement method provides a more accurate and descriptive name. - * - * @return the Instant representing the exact sunset time. If the calculation can't be computed such as in the Arctic - * Circle where there is at least one day a year where the sun does not rise, and one where it does not set, a - * null will be returned. See detailed explanation on top of the page. - * @see AstronomicalCalculator#adjustZenith(double, double) - * @see getSeaLevelSunset() - * @see getUTCSunset(double) - */ - @Deprecated(forRemoval = false) - public Instant getSunset() { - return getSunsetWithElevation(); - } - + /** * A method that returns the sunset without {@link AstronomicalCalculator#getElevationAdjustment(double) elevation adjustment}. * Non-sunrise and sunset calculations such as dawn and dusk, depend on the amount of visible light, something that is not @@ -256,7 +225,7 @@ public Instant getSunset() { * @return the Instant representing the exact sea-level sunset time. If the calculation can't be computed * such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one * where it does not set, a null will be returned. See detailed explanation on top of the page. - * @see getSunsetWithElevation() + * @see getSunset() * @see getUTCSeaLevelSunset(double) */ public Instant getSeaLevelSunset() { @@ -335,15 +304,15 @@ public static Instant getTimeOffset(Instant time, long offsetMillis) { } /** - * A utility method that returns the time of an offset by degrees below or above the horizon of {@link getSunriseWithElevation() + * A utility method that returns the time of an offset by degrees below or above the horizon of {@link getSunrise() * sunrise}. Note that the degree offset is from the vertical, so for a calculation of 14° before sunrise, an offset of 14 * + {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a parameter. * * @param offsetZenith - * the degrees before {@link getSunriseWithElevation()} to use in the calculation. For time after sunrise use negative + * the degrees before {@link getSunrise()} to use in the calculation. For time after sunrise use negative * numbers. Note that the degree offset is from the vertical, so for a calculation of 14° before sunrise, an offset * of 14 + {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a parameter. - * @return The {@link java.time.Instant} of the offset after (or before) {@link getSunriseWithElevation()}. If the calculation + * @return The {@link java.time.Instant} of the offset after (or before) {@link getSunrise()}. If the calculation * can't be computed such as in the Arctic Circle where there is at least one day a year where the sun does * not rise, and one where it does not set, a null will be returned. See detailed explanation * on top of the page. @@ -355,15 +324,15 @@ public Instant getSunriseOffsetByDegrees(double offsetZenith) { } /** - * A utility method that returns the time of an offset by degrees below or above the horizon of {@link getSunsetWithElevation() + * A utility method that returns the time of an offset by degrees below or above the horizon of {@link getSunset() * sunset}. Note that the degree offset is from the vertical, so for a calculation of 14° after sunset, an offset of 14 + * {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a parameter. * * @param offsetZenith - * the degrees after {@link getSunsetWithElevation()} to use in the calculation. For time before sunset use negative + * the degrees after {@link getSunset()} to use in the calculation. For time before sunset use negative * numbers. Note that the degree offset is from the vertical, so for a calculation of 14° after sunset, an offset * of 14 + {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a parameter. - * @return The {@link java.time.Instant} of the offset after (or before) {@link getSunsetWithElevation()}. If the calculation + * @return The {@link java.time.Instant} of the offset after (or before) {@link getSunset()}. If the calculation * can't be computed such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and * and one where it does not set, a null will be returned. See detailed explanation on top of the page. */ @@ -481,7 +450,7 @@ public long getTemporalHour() { /** * A utility method that will allow the calculation of a temporal (solar) hour based on the sunrise and sunset passed as * parameters to this method. An example of the use of this method would be the calculation of a elevation adjusted temporal - * hour by passing in {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} as parameters. + * hour by passing in {@link getSunrise() sunrise} and {@link getSunset() sunset} as parameters. * * @param startOfDay * The start of the day. diff --git a/src/main/java/com/kosherjava/zmanim/ComprehensiveZmanimCalendar.java b/src/main/java/com/kosherjava/zmanim/ComprehensiveZmanimCalendar.java index e4650d95..0b7722d4 100644 --- a/src/main/java/com/kosherjava/zmanim/ComprehensiveZmanimCalendar.java +++ b/src/main/java/com/kosherjava/zmanim/ComprehensiveZmanimCalendar.java @@ -30,7 +30,7 @@ * API. The real power of this API is the ease in calculating zmanim that are not part of the library. The methods for * zmanim calculations not present in this class or it's superclass {@link ZmanimCalendar} are contained in the * {@link AstronomicalCalendar}, the base class of the calendars in our API since they are generic methods for calculating - * time based on degrees or time before or after {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() + * time based on degrees or time before or after {@link getSunset() sunrise} and {@link getSunset() * sunset} and are of interest for calculation beyond zmanim calculations. Here are some examples. *

First create the Calendar for the location you would like to calculate: * @@ -422,11 +422,11 @@ public long getShaahZmanis60Minutes() { /** * Method to return a shaah zmanis (temporal hour) according to the opinion of the Magen Avraham (MGA) based on alos being - * {@link getAlos72Zmanis() 72} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This calculation + * {@link getAlos72Zmanis() 72} minutes zmaniyos before {@link getSunset() sunrise}. This calculation * divides the day based on the opinion of the MGA that the day runs from dawn to dusk. Dawn for this calculation * is 72 minutes zmaniyos before sunrise and dusk is 72 minutes zmaniyos after sunset. This day * is split into 12 equal parts with each part being a shaah zmanis. This is identical to 1/10th of the day - * from {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset}. + * from {@link getSunset() sunrise} to {@link getSunset() sunset}. * * @return the long millisecond length of a shaah zmanis. If the calculation can't be computed * such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one @@ -457,11 +457,11 @@ public long getShaahZmanis90Minutes() { /** * Method to return a shaah zmanis (temporal hour) according to the opinion of the Magen Avraham (MGA) based on alos being {@link - * getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This calculation divides + * getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunset() sunrise}. This calculation divides * the day based on the opinion of the MGA that the day runs from dawn to dusk. Dawn for this calculation is 90 minutes * zmaniyos before sunrise and dusk is 90 minutes zmaniyos after sunset. This day is split into 12 equal - * parts with each part being a shaah zmanis. This is 1/8th of the day from {@link getSunriseWithElevation() sunrise} - * to {@link getSunsetWithElevation() sunset}. + * parts with each part being a shaah zmanis. This is 1/8th of the day from {@link getSunset() sunrise} + * to {@link getSunset() sunset}. * * @return the long millisecond length of a shaah zmanis. If the calculation can't be computed * such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one @@ -477,11 +477,11 @@ public long getShaahZmanis90MinutesZmanis() { /** * Method to return a shaah zmanis (temporal hour) according to the opinion of the Magen Avraham (MGA) based on alos being {@link - * getAlos96Zmanis() 96} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This calculation divides + * getAlos96Zmanis() 96} minutes zmaniyos before {@link getSunset() sunrise}. This calculation divides * the day based on the opinion of the MGA that the day runs from dawn to dusk. Dawn for this calculation is 96 minutes * zmaniyos before sunrise and dusk is 96 minutes zmaniyos after sunset. This day is split into 12 equal * parts with each part being a shaah zmanis. This is identical to 1/7.5th of the day from {@link - * getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset}. + * getSunset() sunrise} to {@link getSunset() sunset}. * * @return the long millisecond length of a shaah zmanis. If the calculation can't be computed * such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one @@ -498,8 +498,8 @@ public long getShaahZmanis96MinutesZmanis() { * Method to return a shaah zmanis (temporal hour) according to the opinion of the * Chacham Yosef Harari-Raful of Yeshivat Ateret Torah calculated with alos being 1/10th * of sunrise to sunset day, or {@link getAlos72Zmanis() 72} minutes zmaniyos of such a day before - * {@link getSunriseWithElevation() sunrise}, and tzais is usually calculated as {@link getTzaisAteretTorah() 40 - * minutes} (configurable to any offset via {@link setAteretTorahSunsetOffset(double)}) after {@link getSunsetWithElevation() + * {@link getSunset() sunrise}, and tzais is usually calculated as {@link getTzaisAteretTorah() 40 + * minutes} (configurable to any offset via {@link setAteretTorahSunsetOffset(double)}) after {@link getSunset() * sunset}. This day is split into 12 equal parts with each part being a shaah zmanis. Note that with this * system, chatzos (midday) will not be the point that the sun is {@link getSunTransit() halfway across * the sky}. @@ -600,11 +600,11 @@ public long getShaahZmanis120Minutes() { /** * Method to return a shaah zmanis (temporal hour) according to the opinion of the Magen Avraham (MGA) based on alos being {@link - * getAlos120Zmanis() 120} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This calculation divides + * getAlos120Zmanis() 120} minutes zmaniyos before {@link getSunset() sunrise}. This calculation divides * the day based on the opinion of the MGA that the day runs from dawn to dusk. Dawn for this calculation is 120 minutes * zmaniyos before sunrise and dusk is 120 minutes zmaniyos after sunset. This day is split into 12 equal * parts with each part being a shaah zmanis. This is identical to 1/6th of the day from {@link - * getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset}. Since zmanim that use this method are + * getSunset() sunrise} to {@link getSunset() sunset}. Since zmanim that use this method are * extremely late or early and at a point when the sky is a long time past the 18° point where the darkest point is reached, * zmanim that use this should only be used lechumra such as delaying the start of nighttime mitzvos. * @@ -673,7 +673,7 @@ public Instant getPlagHamincha120Minutes() { } /** - * Method to return alos (dawn) calculated as 60 minutes before {@link getSunriseWithElevation() sunrise} or + * Method to return alos (dawn) calculated as 60 minutes before {@link getSunset() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting). This is the * time to walk the distance of 4 mil at 15 minutes a mil. This seems to be the opinion of the mil so the time for 4 mil is * 72 minutes which is 1/10th of a day (12 * 60 = 720) based on the day being from {@link getSeaLevelSunrise() sea - * level sunrise} to {@link getSeaLevelSunset() sea level sunset} or {@link getSunriseWithElevation() sunrise} to {@link - * getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()} setting). The actual calculation is {@link + * level sunrise} to {@link getSeaLevelSunset() sea level sunset} or {@link getSunset() sunrise} to {@link + * getSunset() sunset} (depending on the {@link isUseElevation()} setting). The actual calculation is {@link * getSunriseBasedOnElevationSetting()} - ({@link getShaahZmanisGRA()} * 1.2). This calculation is used in the calendars * published by the Hisachdus Harabanim D'Artzos Habris * Ve'Canada. @@ -727,7 +727,7 @@ public Instant getAlos72Zmanis() { } /** - * Method to return alos (dawn) calculated using 96 minutes before {@link getSunriseWithElevation() sunrise} or + * Method to return alos (dawn) calculated using 96 minutes before {@link getSunset() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting) that is based * on the time to walk the distance of 4 mil at 24 minutes a mil. @@ -747,12 +747,12 @@ public Instant getAlos96Minutes() { /** * Method to return alos (dawn) calculated using 90 minutes zmaniyos or 1/8th of the day before - * {@link getSunriseWithElevation() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link + * {@link getSunset() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link * isUseElevation()} setting). This is based on a 22.5-minute mil so the time for 4 mil is 90 minutes * which is 1/8th of a day (12 * 60) / 8 = 90. The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} - * to {@link getSeaLevelSunset() sea level sunset} or {@link getSunriseWithElevation() sunrise} to {@link - * getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()}. The actual calculation used is + * to {@link getSeaLevelSunset() sea level sunset} or {@link getSunset() sunrise} to {@link + * getSunset() sunset} (depending on the {@link isUseElevation()}. The actual calculation used is * {@link getSunriseBasedOnElevationSetting()} - ({@link getShaahZmanisGRA()} * 1.5). * * @return the Instant representing the time. If the calculation can't be computed such as in the Arctic @@ -767,12 +767,12 @@ public Instant getAlos90Zmanis() { /** * This method returns alos (dawn) calculated using 96 minutes zmaniyos or 1/7.5th of the day before - * {@link getSunriseWithElevation() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link + * {@link getSunset() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link * isUseElevation()} setting). This is based on a 24-minute mil so the time for 4 mil is 96 minutes * which is 1/7.5th of a day (12 * 60 / 7.5 = 96). The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} - * to {@link getSeaLevelSunset() sea level sunset} or {@link getSunriseWithElevation() sunrise} to {@link - * getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()}. The actual calculation used is {@link + * to {@link getSeaLevelSunset() sea level sunset} or {@link getSunset() sunrise} to {@link + * getSunset() sunset} (depending on the {@link isUseElevation()}. The actual calculation used is {@link * getSunriseBasedOnElevationSetting()} - ({@link getShaahZmanisGRA()} * 1.6). * * @return the Instant representing the time. If the calculation can't be computed such as in the Arctic @@ -786,7 +786,7 @@ public Instant getAlos96Zmanis() { } /** - * Method to return alos (dawn) calculated using 90 minutes before {@link getSunriseWithElevation() sunrise} or + * Method to return alos (dawn) calculated using 90 minutes before {@link getSunset() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting) based on the time * to walk the distance of 4 mil at * 22.5 minutes a mil. Time-based offset calculations for alos are based on the opinion of the lechumra only and returns alos (dawn) calculated using 120 minutes - * before {@link getSunriseWithElevation() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the + * before {@link getSunset() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on the * {@link isUseElevation()} setting) based on the time to walk the distance of 5 mil (Ula) at 24 minutes a * mil. Time based offset calculations for alos are based on the* opinion of the lechumra only and method returns alos (dawn) calculated using - * 120 minutes zmaniyos or 1/6th of the day before {@link getSunriseWithElevation() sunrise} or {@link + * 120 minutes zmaniyos or 1/6th of the day before {@link getSunset() sunrise} or {@link * getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting). This is based * on a 24-minute mil so * the time for 5 mil is 120 minutes which is 1/6th of a day (12 * 60 / 6 = 120). The day is calculated from * {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level sunset} or {@link - * getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the {@link - * isUseElevation()}. The actual calculation used is {@link getSunriseWithElevation()} - ({@link getShaahZmanisGRA()} + * getSunset() sunrise} to {@link getSunset() sunset} (depending on the {@link + * isUseElevation()}. The actual calculation used is {@link getSunset()} - ({@link getShaahZmanisGRA()} * * 2). Since this time is extremely early, it should only be used lechumra, such as not eating after this time * on a fast day, and not as the start time for mitzvos that can only be performed during the day. * @@ -944,7 +944,7 @@ public Instant getAlos19Point8Degrees() { /** * This method returns misheyakir based on the position of the sun {@link ZENITH_12_POINT_85 12.85°} * below {@link GEOMETRIC_ZENITH geometric zenith} (90°). This is based on the position of the sun slightly - * later than 57 minutes before {@link getSunriseWithElevation() sunrise} in Jerusalem around the equinox / equilux. This * zman is mentioned for use bish'as hadchak in the Birur Halacha Tinyana and misheyakir based on the position of the sun when it is {@link ZENITH_11_DEGREES * 11.5°} below {@link GEOMETRIC_ZENITH geometric zenith} (90°). This calculation is used for calculating * misheyakir according to some opinions. This calculation is based on the position of the sun 52 minutes - * before {@link getSunriseWithElevation() sunrise} in Jerusalem around the equinox / equilux, * which calculates to 11.5° below {@link GEOMETRIC_ZENITH geometric zenith}. * @todo recalculate. @@ -1008,7 +1008,7 @@ public Instant getMisheyakir11Point5Degrees() { * This method returns misheyakir based on the position of the sun when it is {@link ZENITH_11_DEGREES * 11°} below {@link GEOMETRIC_ZENITH geometric zenith} (90°). This calculation is used for calculating * misheyakir according to some opinions. This calculation is based on the position of the sun 48 minutes - * before {@link getSunriseWithElevation() sunrise} in Jerusalem around the equinox / equilux, * which calculates to 11° below {@link GEOMETRIC_ZENITH geometric zenith}. * @@ -1026,7 +1026,7 @@ public Instant getMisheyakir11Degrees() { * This method returns misheyakir based on the position of the sun when it is {@link ZENITH_10_POINT_2 * 10.2°} below {@link GEOMETRIC_ZENITH geometric zenith} (90°). This calculation is used for calculating * misheyakir according to some opinions. This calculation is based on the position of the sun 45 minutes - * before {@link getSunriseWithElevation() sunrise} in Jerusalem around the equinox which calculates * to 10.2° below {@link GEOMETRIC_ZENITH geometric zenith}. * @@ -1104,7 +1104,7 @@ public Instant getMisheyakir9Point5Degrees() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the * opinion of the Magen Avraham (MGA) based on - * alos being {@link getAlos19Point8Degrees() 19.8°} before {@link getSunriseWithElevation() sunrise}. This + * alos being {@link getAlos19Point8Degrees() 19.8°} before {@link getSunset() sunrise}. This * time is 3 {@link getShaahZmanis19Point8Degrees() shaos zmaniyos} (solar hours) after {@link * getAlos19Point8Degrees() dawn} based on the opinion of the MGA that the day is calculated from dawn to nightfall * with both being 19.8° below sunrise or sunset. This returns the time of 3 * @@ -1124,7 +1124,7 @@ public Instant getSofZmanShmaMGA19Point8Degrees() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the opinion of * the Magen Avraham (MGA) based on alos being {@link - * getAlos16Point1Degrees() 16.1°} before {@link getSunriseWithElevation() sunrise}. This time is 3 {@link + * getAlos16Point1Degrees() 16.1°} before {@link getSunset() sunrise}. This time is 3 {@link * getShaahZmanis16Point1Degrees() shaos zmaniyos} (solar hours) after {@link getAlos16Point1Degrees() dawn} based on * the opinion of the MGA that the day is calculated from dawn to nightfall with both being 16.1° below sunrise or sunset. * This returns the time of 3 * {@link getShaahZmanis16Point1Degrees()} after {@link getAlos16Point1Degrees() dawn}. @@ -1143,7 +1143,7 @@ public Instant getSofZmanShmaMGA16Point1Degrees() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the * opinion of the Magen Avraham (MGA) based - * on alos being {@link getAlos18Degrees() 18°} before {@link getSunriseWithElevation() sunrise}. This time is 3 + * on alos being {@link getAlos18Degrees() 18°} before {@link getSunset() sunrise}. This time is 3 * {@link getShaahZmanis18Degrees() shaos zmaniyos} (solar hours) after {@link getAlos18Degrees() dawn} * based on the opinion of the MGA that the day is calculated from dawn to nightfall with both being 18° * below sunrise or sunset. This returns the time of 3 * {@link getShaahZmanis18Degrees()} after @@ -1164,7 +1164,7 @@ public Instant getSofZmanShmaMGA18Degrees() { * This method returns the latest zman krias shema (time to recite Shema in the morning) according * to the opinion of the Magen Avraham (MGA) based * on alos being {@link getAlos72Zmanis() 72} minutes zmaniyos, or 1/10th of the day before - * {@link getSunriseWithElevation() sunrise}. This time is 3 {@link getShaahZmanis90MinutesZmanis() shaos zmaniyos} + * {@link getSunset() sunrise}. This time is 3 {@link getShaahZmanis90MinutesZmanis() shaos zmaniyos} * (solar hours) after {@link getAlos72Zmanis() dawn} based on the opinion of the MGA that the day is calculated * from a {@link getAlos72Zmanis() dawn} of 72 minutes zmaniyos, or 1/10th of the day before * {@link getSeaLevelSunrise() sea level sunrise} to {@link getTzais72Zmanis() nightfall} of 72 minutes @@ -1186,7 +1186,7 @@ public Instant getSofZmanShmaMGA72MinutesZmanis() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according * to the opinion of the Magen Avraham (MGA) based on - * alos being {@link getAlos90Minutes() 90} minutes before {@link getSunriseWithElevation() sunrise}. This time is 3 + * alos being {@link getAlos90Minutes() 90} minutes before {@link getSunset() sunrise}. This time is 3 * {@link getShaahZmanis90Minutes() shaos zmaniyos} (solar hours) after {@link getAlos90Minutes() dawn} based on * the opinion of the MGA that the day is calculated from a {@link getAlos90Minutes() dawn} of 90 minutes before sunrise to * {@link getTzais90Minutes() nightfall} of 90 minutes after sunset. This returns the time of 3 * @@ -1207,7 +1207,7 @@ public Instant getSofZmanShmaMGA90Minutes() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the * opinion of the Magen Avraham (MGA) based - * on alos being {@link getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunriseWithElevation() + * on alos being {@link getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunset() * sunrise}. This time is 3 {@link getShaahZmanis90MinutesZmanis() shaos zmaniyos} (solar hours) after * {@link getAlos90Zmanis() dawn} based on the opinion of the MGA that the day is calculated from a {@link * getAlos90Zmanis() dawn} of 90 minutes zmaniyos before sunrise to {@link getTzais90Zmanis() nightfall} @@ -1229,7 +1229,7 @@ public Instant getSofZmanShmaMGA90MinutesZmanis() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the opinion of * the Magen Avraham (MGA) based on alos being {@link - * getAlos96Minutes() 96} minutes before {@link getSunriseWithElevation() sunrise}. This time is 3 {@link + * getAlos96Minutes() 96} minutes before {@link getSunset() sunrise}. This time is 3 {@link * getShaahZmanis96Minutes() shaos zmaniyos} (solar hours) after {@link getAlos96Minutes() dawn} based on the opinion * of the MGA that the day is calculated from a {@link getAlos96Minutes() dawn} of 96 minutes before sunrise to {@link * getTzais96Minutes() nightfall} of 96 minutes after sunset. This returns the time of 3 * {@link getShaahZmanis96Minutes()} @@ -1250,7 +1250,7 @@ public Instant getSofZmanShmaMGA96Minutes() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the * opinion of the Magen Avraham (MGA) based - * on alos being {@link getAlos90Zmanis() 96} minutes zmaniyos before {@link getSunriseWithElevation() + * on alos being {@link getAlos90Zmanis() 96} minutes zmaniyos before {@link getSunset() * sunrise}. This time is 3 {@link getShaahZmanis96MinutesZmanis() shaos zmaniyos} (solar hours) after * {@link getAlos96Zmanis() dawn} based on the opinion of the MGA that the day is calculated from a {@link * getAlos96Zmanis() dawn} of 96 minutes zmaniyos before sunrise to {@link getTzais90Zmanis() nightfall} @@ -1301,7 +1301,7 @@ public Instant getSofZmanShma3HoursBeforeChatzos() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the * opinion of the Magen Avraham (MGA) based - * on alos being {@link getAlos120Minutes() 120} minutes or 1/6th of the day before {@link getSunriseWithElevation() + * on alos being {@link getAlos120Minutes() 120} minutes or 1/6th of the day before {@link getSunset() * sunrise}. This time is 3 {@link getShaahZmanis120Minutes() shaos zmaniyos} (solar hours) after {@link * getAlos120Minutes() dawn} based on the opinion of the MGA that the day is calculated from a {@link getAlos120Minutes() dawn} * of 120 minutes before sunrise to {@link getTzais120Minutes() nightfall} of 120 minutes after sunset. This returns the time of @@ -1372,7 +1372,7 @@ public Instant getSofZmanShmaAlos16Point1ToTzaisGeonim7Point083Degrees() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos19Point8Degrees() 19.8°} before {@link getSunriseWithElevation() sunrise}. This time + * alos being {@link getAlos19Point8Degrees() 19.8°} before {@link getSunset() sunrise}. This time * is 4 {@link getShaahZmanis19Point8Degrees() shaos zmaniyos} (solar hours) after {@link * getAlos19Point8Degrees() dawn} based on the opinion of the MGA that the day is calculated from dawn to * nightfall with both being 19.8° below sunrise or sunset. This returns the time of 4 * {@link @@ -1394,7 +1394,7 @@ public Instant getSofZmanTfilaMGA19Point8Degrees() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunriseWithElevation() sunrise}. This time + * alos being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunset() sunrise}. This time * is 4 {@link getShaahZmanis16Point1Degrees() shaos zmaniyos} (solar hours) after {@link * getAlos16Point1Degrees() dawn} based on the opinion of the MGA that the day is calculated from dawn to * nightfall with both being 16.1° below sunrise or sunset. This returns the time of 4 * {@link @@ -1415,7 +1415,7 @@ public Instant getSofZmanTfilaMGA16Point1Degrees() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos18Degrees() 18°} before {@link getSunriseWithElevation() sunrise}. This time is 4 + * alos being {@link getAlos18Degrees() 18°} before {@link getSunset() sunrise}. This time is 4 * {@link getShaahZmanis18Degrees() shaos zmaniyos} (solar hours) after {@link getAlos18Degrees() dawn} * based on the opinion of the MGA that the day is calculated from dawn to nightfall with both being 18° * below sunrise or sunset. This returns the time of 4 * {@link getShaahZmanis18Degrees()} after @@ -1436,7 +1436,7 @@ public Instant getSofZmanTfilaMGA18Degrees() { /** * This method returns the latest zman tfila (time to the morning prayers) according to the opinion of the * Magen Avraham (MGA) based on alos - * being {@link getAlos72Zmanis() 72} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This time is 4 + * being {@link getAlos72Zmanis() 72} minutes zmaniyos before {@link getSunset() sunrise}. This time is 4 * {@link getShaahZmanis72MinutesZmanis() shaos zmaniyos} (solar hours) after {@link getAlos72Zmanis() dawn} * based on the opinion of the MGA that the day is calculated from a {@link getAlos72Zmanis() dawn} of 72 * minutes zmaniyos before sunrise to {@link getTzais72Zmanis() nightfall} of 72 minutes zmaniyos @@ -1456,7 +1456,7 @@ public Instant getSofZmanTfilaMGA72MinutesZmanis() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos90Minutes() 90} minutes before {@link getSunriseWithElevation() sunrise}. This time is 4 + * alos being {@link getAlos90Minutes() 90} minutes before {@link getSunset() sunrise}. This time is 4 * {@link getShaahZmanis90Minutes() shaos zmaniyos} (solar hours) after {@link getAlos90Minutes() dawn} based on * the opinion of the MGA that the day is calculated from a {@link getAlos90Minutes() dawn} of 90 minutes before sunrise to * {@link getTzais90Minutes() nightfall} of 90 minutes after sunset. This returns the time of 4 * @@ -1476,7 +1476,7 @@ public Instant getSofZmanTfilaMGA90Minutes() { /** * This method returns the latest zman tfila (time to the morning prayers) according to the opinion of the * Magen Avraham (MGA) based on alos - * being {@link getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This time is + * being {@link getAlos90Zmanis() 90} minutes zmaniyos before {@link getSunset() sunrise}. This time is * 4 {@link getShaahZmanis90MinutesZmanis() shaos zmaniyos} (solar hours) after {@link getAlos90Zmanis() * dawn} based on the opinion of the MGA that the day is calculated from a {@link getAlos90Zmanis() dawn} * of 90 minutes zmaniyos before sunrise to {@link getTzais90Zmanis() nightfall} of 90 minutes @@ -1497,7 +1497,7 @@ public Instant getSofZmanTfilaMGA90MinutesZmanis() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos96Minutes() 96} minutes before {@link getSunriseWithElevation() sunrise}. This time is 4 + * alos being {@link getAlos96Minutes() 96} minutes before {@link getSunset() sunrise}. This time is 4 * {@link getShaahZmanis96Minutes() shaos zmaniyos} (solar hours) after {@link getAlos96Minutes() dawn} based on * the opinion of the MGA that the day is calculated from a {@link getAlos96Minutes() dawn} of 96 minutes before * sunrise to {@link getTzais96Minutes() nightfall} of 96 minutes after sunset. This returns the time of 4 * @@ -1517,7 +1517,7 @@ public Instant getSofZmanTfilaMGA96Minutes() { /** * This method returns the latest zman tfila (time to the morning prayers) according to the opinion of the * Magen Avraham (MGA) based on alos - * being {@link getAlos96Zmanis() 96} minutes zmaniyos before {@link getSunriseWithElevation() sunrise}. This time is + * being {@link getAlos96Zmanis() 96} minutes zmaniyos before {@link getSunset() sunrise}. This time is * 4 {@link getShaahZmanis96MinutesZmanis() shaos zmaniyos} (solar hours) after {@link getAlos96Zmanis() * dawn} based on the opinion of the MGA that the day is calculated from a {@link getAlos96Zmanis() dawn} * of 96 minutes zmaniyos before sunrise to {@link getTzais96Zmanis() nightfall} of 96 minutes @@ -1538,7 +1538,7 @@ public Instant getSofZmanTfilaMGA96MinutesZmanis() { /** * This method returns the latest zman tfila (time to recite the morning prayers) according to the opinion * of the Magen Avraham (MGA) based on - * alos being {@link getAlos120Minutes() 120} minutes before {@link getSunriseWithElevation() sunrise} . This time is 4 + * alos being {@link getAlos120Minutes() 120} minutes before {@link getSunset() sunrise} . This time is 4 * {@link getShaahZmanis120Minutes() shaos zmaniyos} (solar hours) after {@link getAlos120Minutes() dawn} * based on the opinion of the MGA that the day is calculated from a {@link getAlos120Minutes() dawn} of 120 * minutes before sunrise to {@link getTzais120Minutes() nightfall} of 120 minutes after sunset. This returns the time of @@ -2032,7 +2032,7 @@ public Instant getPlagHamincha18Degrees() { /** * This method should be used lechumra only and returns the time of plag hamincha based on the opinion that - * the day starts at {@link getAlos16Point1Degrees() alos 16.1°} and ends at {@link getSunsetWithElevation() + * the day starts at {@link getAlos16Point1Degrees() alos 16.1°} and ends at {@link getSunset() * sunset}. 10.75 shaos zmaniyos are calculated based on this day and added to {@link getAlos16Point1Degrees() * alos} to reach this time. This time is 10.75 shaos zmaniyos (temporal hours) after {@link * getAlos16Point1Degrees() dawn} based on the opinion that the day is calculated from a {@link getAlos16Point1Degrees() @@ -2583,7 +2583,7 @@ public Instant getTzaisGeonim9Point75Degrees() { * "https://he.wikipedia.org/wiki/%D7%9E%D7%9C%D7%9B%D7%99%D7%90%D7%9C_%D7%A6%D7%91%D7%99_%D7%98%D7%A0%D7%A0%D7%91%D7%95%D7%99%D7%9D" * >Divrei Malkiel that the time to walk the distance of a mil is 15 minutes, for a total of 60 minutes - * for 4 mil after {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunset() sea level sunset} (depending on the + * for 4 mil after {@link getSunset() sunset} or {@link getSeaLevelSunset() sea level sunset} (depending on the * {@link isUseElevation()} setting). See detailed documentation explaining the 60 minute concept at {@link getAlos60Minutes()}. * * @return the Instant representing 60 minutes after sea level sunset. If the calculation can't be @@ -2820,7 +2820,7 @@ public Instant getTzais96Zmanis() { } /** - * Method to return tzais (dusk) calculated as 90 minutes after {@link getSunsetWithElevation() sunset} or {@link + * Method to return tzais (dusk) calculated as 90 minutes after {@link getSunset() sunset} or {@link * getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} setting). This method returns * tzais (nightfall) based on the opinion of the Magen Avraham that the time to walk the distance of a mil according to the Rav Chaim Naeh that the time to walk the distance * of a mil according to the Rambam's opinion is 2/5 of an hour (24 minutes) for a total of 120 - * minutes based on the opinion of Ula who calculated tzais as 5 mil after {@link getSunsetWithElevation() + * minutes based on the opinion of Ula who calculated tzais as 5 mil after {@link getSunset() * sunset} or {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} setting). * A similar calculation {@link getTzais26Degrees()} uses degree-based calculations based on this 120 minute calculation. * Since the zman is extremely late and at a point that is long past the 18° point where the darkest point is @@ -2965,7 +2965,7 @@ public Instant getTzais19Point8Degrees() { } /** - * A method to return tzais (dusk) calculated as 96 minutes after {@link getSunsetWithElevation() sunset} or {@link + * A method to return tzais (dusk) calculated as 96 minutes after {@link getSunset() sunset} or {@link * getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} setting). For information on how * this is calculated see the comments on {@link getAlos96Minutes()}. * @@ -3332,7 +3332,7 @@ public Instant getSofZmanAchilasChametzGRA() { /** * This method returns the latest time one is allowed eating chametz on Erev Pesach according to the * opinion of the Magen Avraham (MGA) based on alos - * being {@link getAlos72Minutes() 72} minutes before {@link getSunriseWithElevation() sunrise}. This time is identical to the + * being {@link getAlos72Minutes() 72} minutes before {@link getSunset() sunrise}. This time is identical to the * {@link getSofZmanTfilaMGA72Minutes() Sof zman tfilah MGA 72 minutes}. This time is 4 {@link * getShaahZmanis72Minutes() shaos zmaniyos} (temporal hours) after {@link getAlos72Minutes() dawn} based on the * opinion of the MGA that the day is calculated from a {@link getAlos72Minutes() dawn} of 72 minutes before sunrise to {@link @@ -3355,7 +3355,7 @@ public Instant getSofZmanAchilasChametzMGA72Minutes() { /** * This method returns the latest time one is allowed eating chametz on Erev Pesach according to the opinion * of the Magen Avraham (MGA) based on alos being {@link - * getAlos72Zmanis() 72 zmaniyos} minutes before {@link getSunriseWithElevation() sunrise}. This time is identical to the + * getAlos72Zmanis() 72 zmaniyos} minutes before {@link getSunset() sunrise}. This time is identical to the * {@link getSofZmanTfilaMGA72MinutesZmanis() Sof zman tfilah MGA 72 minutes zmanis}. This time is 4 {@link * getShaahZmanis72MinutesZmanis() shaos zmaniyos} (temporal hours) after {@link getAlos72Minutes() dawn} based on the * opinion of the MGA that the day is calculated from a {@link getAlos72Zmanis() dawn} of 72 minutes zmanis before sunrise to @@ -3379,7 +3379,7 @@ public Instant getSofZmanAchilasChametzMGA72MinutesZmanis() { /** * This method returns the latest time one is allowed eating chametz on Erev Pesach according to the * opinion of the Magen Avraham (MGA) based on alos - * being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunriseWithElevation() sunrise}. This time is 4 {@link + * being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunset() sunrise}. This time is 4 {@link * getShaahZmanis16Point1Degrees() shaos zmaniyos} (solar hours) after {@link getAlos16Point1Degrees() dawn} based * on the opinion of the MGA that the day is calculated from dawn to nightfall with both being 16.1° below sunrise or * sunset. This returns the time of 4 {@link getShaahZmanis16Point1Degrees()} after {@link getAlos16Point1Degrees() dawn}. @@ -3418,7 +3418,7 @@ public Instant getSofZmanBiurChametzGRA() { /** * This method returns the latest time for burning chametz on Erev Pesach according to the opinion of the * Magen Avraham (MGA) based on alos being {@link - * getAlos72Minutes() 72} minutes before {@link getSunriseWithElevation() sunrise}. This time is 5 {@link + * getAlos72Minutes() 72} minutes before {@link getSunset() sunrise}. This time is 5 {@link * getShaahZmanis72Minutes() shaos zmaniyos} (temporal hours) after {@link getAlos72Minutes() dawn} based on the * opinion of the MGA that the day is calculated from a {@link getAlos72Minutes() dawn} of 72 minutes before sunrise to {@link * getTzais72Minutes() nightfall} of 72 minutes after sunset. This returns the time of 5 * {@link getShaahZmanis72Minutes()} @@ -3438,7 +3438,7 @@ public Instant getSofZmanBiurChametzMGA72Minutes() { /** * This method returns the latest time for burning chametz on Erev Pesach according to the opinion of the * Magen Avraham (MGA) based on alos being {@link - * getAlos72Zmanis() 72} minutes zmanis before {@link getSunriseWithElevation() sunrise}. This time is 5 {@link + * getAlos72Zmanis() 72} minutes zmanis before {@link getSunset() sunrise}. This time is 5 {@link * getShaahZmanis72MinutesZmanis() shaos zmaniyos} (temporal hours) after {@link getAlos72Zmanis() dawn} based on the * opinion of the MGA that the day is calculated from a {@link getAlos72Zmanis() dawn} of 72 minutes zmanis before sunrise to * {@link getTzais72Zmanis() nightfall} of 72 minutes zmanis after sunset. This returns the time of 5 * {@link @@ -3459,7 +3459,7 @@ public Instant getSofZmanBiurChametzMGA72MinutesZmanis() { /** * This method returns the latest time for burning chametz on Erev Pesach according to the opinion * of the Magen Avraham (MGA) based on alos - * being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunriseWithElevation() sunrise}. This time is 5 + * being {@link getAlos16Point1Degrees() 16.1°} before {@link getSunset() sunrise}. This time is 5 * {@link getShaahZmanis16Point1Degrees() shaos zmaniyos} (solar hours) after {@link getAlos16Point1Degrees() * dawn} based on the opinion of the MGA that the day is calculated from dawn to nightfall with both being 16.1° * below sunrise or sunset. This returns the time of 5 {@link getShaahZmanis16Point1Degrees()} after @@ -3511,7 +3511,7 @@ public long getShaahZmanisBaalHatanya() { /** * Returns the Baal Hatanya's alos * (dawn) calculated as the time when the sun is 16.9° below the eastern {@link GEOMETRIC_ZENITH geometric horizon} - * before {@link getSunriseWithElevation() sunrise}. It is based on the calculation that the time between dawn and + * before {@link getSunset() sunrise}. It is based on the calculation that the time between dawn and * netz amiti (sunrise) is 72 minutes, the time that is takes to walk 4 mil at 18 minutes * a mil (Rambam and others). The sun's position at 72 * minutes before {@link getSunriseBaalHatanya netz amiti (sunrise)} in Jerusalem tzais (nightfall) when the sun is 6° below the western geometric horizon (90°) - * after {@link getSunsetWithElevation() sunset}. This tzais / nightfall based on the opinion of the tzais / nightfall based on the opinion of the Baal Hatanya. This calculation is based on the position of the * sun about 24 minutes after {@link getSeaLevelSunset() sunset} in Jerusalem around the equinox / equilux, which @@ -3773,7 +3773,7 @@ public Instant getSofZmanShmaMGA72MinutesToFixedLocalChatzos() { * This method returns Rav Moshe Feinstein's opinion of the * calculation of sof zman krias shema (latest time to recite Shema in the morning) according to the opinion * of the GRA that the day is calculated from sunrise to sunset, but - * calculated using the first half of the day only. The half a day starts at {@link getSunriseWithElevation() sunrise} and + * calculated using the first half of the day only. The half a day starts at {@link getSunset() sunrise} and * ends at {@link getFixedLocalChatzosHayom() fixed local chatzos}. Sof zman Shema is 3 shaos zmaniyos (solar * hours) after sunrise or half of this half-day. * @@ -3781,7 +3781,7 @@ public Instant getSofZmanShmaMGA72MinutesToFixedLocalChatzos() { * as northern and southern locations even south of the Arctic Circle and north of the Antarctic Circle * where the sun may not reach low enough below the horizon for this calculation, a null will be * returned. See detailed explanation on top of the {@link AstronomicalCalendar} documentation. - * @see getSunriseWithElevation() + * @see getSunset() * @see getFixedLocalChatzosHayom() * @see getHalfDayBasedZman(Instant, Instant, double) */ @@ -3794,14 +3794,14 @@ public Instant getSofZmanShmaGRASunriseToFixedLocalChatzos() { * calculation of sof zman tfila (zman tfilah (the latest time to recite the morning prayers)) * according to the opinion of the GRA that the day is * calculated from sunrise to sunset, but calculated using the first half of the day only. The half a day starts at - * {@link getSunriseWithElevation() sunrise} and ends at {@link getFixedLocalChatzosHayom() fixed local chatzos}. Sof zman + * {@link getSunset() sunrise} and ends at {@link getFixedLocalChatzosHayom() fixed local chatzos}. Sof zman * tefila is 4 shaos zmaniyos (solar hours) after sunrise or 2/3 of this half-day. * * @return the Instant of the latest zman krias shema. If the calculation can't be computed such * as northern and southern locations even south of the Arctic Circle and north of the Antarctic Circle * where the sun may not reach low enough below the horizon for this calculation, a null will be * returned. See detailed explanation on top of the {@link AstronomicalCalendar} documentation. - * @see getSunriseWithElevation() + * @see getSunset() * @see getFixedLocalChatzosHayom() * @see getHalfDayBasedZman(Instant, Instant, double) */ @@ -3871,7 +3871,7 @@ public Instant getPlagHaminchaGRAFixedLocalChatzosToSunset() { } /** - * Method to return tzais (dusk) calculated as 50 minutes after {@link getSunsetWithElevation() sunset} or {@link + * Method to return tzais (dusk) calculated as 50 minutes after {@link getSunset() sunset} or {@link * getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} setting). This method returns * tzais (nightfall) based on the opinion of Rabbi Moshe Feinstein for the New York area. This time should * not be used for latitudes other than ones similar to the latitude of the NY area. @@ -3890,7 +3890,7 @@ public Instant getTzais50Minutes() { * {@link getMinchaKetanaGRA()} or is 9 * shaos zmaniyos (solar hours) after the start of * the day, calculated according to the GRA using a day starting at * sunrise and ending at sunset. This is the time that eating or other activity can't begin prior to praying mincha. - * The calculation used is 9 * {@link getShaahZmanisGRA()} after {@link getSunriseWithElevation() sunrise} or {@link + * The calculation used is 9 * {@link getShaahZmanisGRA()} after {@link getSunset() sunrise} or {@link * getSunriseBasedOnElevationSetting() elevation adjusted sunrise} (depending on the {@link isUseElevation()} setting). See the * Mechaber and Mishna Berurah 232 and 249:2. diff --git a/src/main/java/com/kosherjava/zmanim/ZmanimCalendar.java b/src/main/java/com/kosherjava/zmanim/ZmanimCalendar.java index fef567ff..a78d5f2a 100644 --- a/src/main/java/com/kosherjava/zmanim/ZmanimCalendar.java +++ b/src/main/java/com/kosherjava/zmanim/ZmanimCalendar.java @@ -39,7 +39,7 @@ * >Shimush Zekeinim, Ch. 1, page 17 states that obstructing horizons should be factored into zmanim calculations. The * setting defaults to false (elevation will not be used for zmanim calculations besides sunrise and sunset), unless the * setting is changed to true in {@link setUseElevation(boolean)}. This will impact sunrise and sunset-based zmanim such as - * {@link getSunriseWithElevation()}, {@link getSunsetWithElevation()}, {@link getSofZmanShmaGRA()}, alos-based + * {@link getSunrise()}, {@link getSunset()}, {@link getSofZmanShmaGRA()}, alos-based * zmanim such as {@link getSofZmanShmaMGA72Minutes()} that are based on a fixed offset of sunrise or sunset and * zmanim based on a percentage of the day such as {@link ComprehensiveZmanimCalendar#getSofZmanShmaMGA90MinutesZmanis()} * that are based on sunrise and sunset. Even when set to true it will not impact zmanim that are a degree-based offset of @@ -252,39 +252,39 @@ public void setUseAstronomicalChatzosForOtherZmanim(boolean useAstronomicalChatz /** * This method will return {@link getSeaLevelSunrise() sea level sunrise} if {@link isUseElevation()} is false (the default), - * or elevation adjusted {@link getSunriseWithElevation()} if it is true. This allows relevant zmanim in this and + * or elevation adjusted {@link getSunrise()} if it is true. This allows relevant zmanim in this and * extending classes (such as the {@link ComprehensiveZmanimCalendar}) to automatically adjust to the elevation setting. * * @return {@link getSeaLevelSunrise()} if {@link isUseElevation()} is false (the default), or elevation adjusted - * {@link getSunriseWithElevation()} if it is true. - * @see getSunriseWithElevation() + * {@link getSunrise()} if it is true. + * @see getSunrise() */ protected Instant getSunriseBasedOnElevationSetting() { if (isUseElevation()) { - return super.getSunriseWithElevation(); + return super.getSunrise(); } return getSeaLevelSunrise(); } /** * This method will return {@link getSeaLevelSunrise() sea level sunrise} if {@link isUseElevation()} is false (the default), - * or elevation adjusted {@link getSunriseWithElevation()} if it is true. This allows relevant zmanim + * or elevation adjusted {@link getSunrise()} if it is true. This allows relevant zmanim * in this and extending classes (such as the {@link ComprehensiveZmanimCalendar}) to automatically adjust to the elevation setting. * * @return {@link getSeaLevelSunset()} if {@link isUseElevation()} is false (the default), or elevation adjusted - * {@link getSunsetWithElevation()} if it is true. - * @see getSunsetWithElevation() + * {@link getSunset()} if it is true. + * @see getSunset() */ protected Instant getSunsetBasedOnElevationSetting() { if (isUseElevation()) { - return super.getSunsetWithElevation(); + return super.getSunset(); } return getSeaLevelSunset(); } /** * A method that returns tzais (nightfall) when the sun is {@link ZENITH_8_POINT_5 8.5°} below the - * {@link GEOMETRIC_ZENITH geometric horizon} (90°) after {@link getSunsetWithElevation() sunset}, a time that Rabbi + * {@link GEOMETRIC_ZENITH geometric horizon} (90°) after {@link getSunset() sunset}, a time that Rabbi * Meir Posen in his the Ohr Meir calculated that 3 small * stars are visible, which is later than the required 3 medium stars. This calculation is based on the sun's position below * the horizon 36 minutes after {@link getSeaLevelSunrise() sunset} in Jerusalem alos (dawn) based on the time when the sun is {@link ZENITH_16_POINT_1 16.1°} below the - * eastern {@link GEOMETRIC_ZENITH geometric horizon} before {@link getSunriseWithElevation() sunrise}. This is based on the + * eastern {@link GEOMETRIC_ZENITH geometric horizon} before {@link getSunrise() sunrise}. This is based on the * calculation that the time between dawn and sunrise (and sunset to nightfall) is 72 minutes, the time that is * takes to walk 4 mil at * 18 minutes a mil (Rambam and others). The sun's position - * below the horizon 72 minutes before {@link getSunriseWithElevation() sunrise} in Jerusalem on the around the equinox / equilux is * 16.1° below {@link GEOMETRIC_ZENITH}. * @@ -323,7 +323,7 @@ public Instant getAlos16Point1Degrees() { } /** - * Method to return alos (dawn) calculated as 72 minutes before {@link getSunriseWithElevation() sunrise} or + * Method to return alos (dawn) calculated as 72 minutes before {@link getSunrise() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting). This time * is based on the time to walk the distance of 4 mil at 18 minutes a mil. The @@ -503,7 +503,7 @@ public Instant getChatzosHayomAsHalfDay() { * hours), and the latest zman krias shema is calculated as 3 of those shaos zmaniyos after the beginning of * the day. If {@link isUseAstronomicalChatzosForOtherZmanim()} is true, the 3 shaos zmaniyos will be * based on 1/6 of the time between sunrise and {@link getSunTransit() astronomical chatzos}. As an example, passing - * {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunrise() sea level + * {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link getSeaLevelSunrise() sea level * sunrise} and {@link getSeaLevelSunset() sea level sunset} to this method (or {@link getSunriseBasedOnElevationSetting()} and * {@link getSunsetBasedOnElevationSetting()} that is driven off the {@link isUseElevation()} setting) will return sof zman * krias shema according to the opinion of the GRA. In cases where @@ -557,11 +557,11 @@ public Instant getSofZmanShma(Instant startOfDay, Instant endOfDay) { /** * This method returns the latest zman krias shema (time to recite shema in the morning) that is 3 * - * {@link getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunriseWithElevation() sunrise} or + * {@link getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunrise() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting), according * to the GRA. * The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level - * sunset} or from {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the + * sunset} or from {@link getSunrise() sunrise} to {@link getSunset() sunset} (depending on the * {@link isUseElevation()} setting). * * @see getSofZmanShma(Instant, Instant) @@ -580,7 +580,7 @@ public Instant getSofZmanShmaGRA() { /** * This method returns the latest zman krias shema (time to recite Shema in the morning) according to the opinion of * the Magen Avraham (MGA) based on alos being {@link - * getAlos72Minutes() 72} minutes before {@link getSunriseWithElevation() sunrise}. This time is 3 {@link + * getAlos72Minutes() 72} minutes before {@link getSunrise() sunrise}. This time is 3 {@link * getShaahZmanis72Minutes() shaos zmaniyos} (solar hours) after {@link getAlos72Minutes() dawn} based on the opinion * of the MGA that the day is calculated from a {@link getAlos72Minutes() dawn} of 72 minutes before sunrise to * {@link getTzais72Minutes() nightfall} of 72 minutes after sunset. This returns the time of 3 * {@link @@ -608,7 +608,7 @@ public Instant getSofZmanShmaMGA72Minutes() { * 235:3, the Pri Megadim in Orach * Chaim 261:2 (see the Biur Halacha) and others (see Hazmanim Bahalacha 17:3 and 17:5) the 72 minutes are standard * clock minutes any time of the year in any location. Depending on the {@link isUseElevation()} setting, a 72-minute - * offset from either {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunset() sea level sunset} is used. + * offset from either {@link getSunset() sunset} or {@link getSeaLevelSunset() sea level sunset} is used. * * @see ComprehensiveZmanimCalendar#getTzais16Point1Degrees() * @return the Instant representing 72 minutes after sunset. If the calculation can't be @@ -645,7 +645,7 @@ public Instant getCandleLighting() { * end of the day passed to this method. * The time from the start of day to the end of day are divided into 12 shaos zmaniyos (temporal hours), * and sof zman tfila is calculated as 4 of those shaos zmaniyos after the beginning of the day. - * As an example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunrise() + * As an example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link getSeaLevelSunrise() * sea level sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} * elevation setting) to this method will return zman tfilah according to the opinion of the GRA. This method's synchronous parameter indicates if the start @@ -802,11 +802,11 @@ public Instant getSofZmanTfila(Instant startOfDay, Instant endOfDay) { /** * This method returns the latest zman tfila (time to recite shema in the morning) that is 4 * - * {@link getShaahZmanisGRA() shaos zmaniyos }(solar hours) after {@link getSunriseWithElevation() sunrise} or + * {@link getShaahZmanisGRA() shaos zmaniyos }(solar hours) after {@link getSunrise() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting), according * to the GRA. * The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level - * sunset} or from {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the + * sunset} or from {@link getSunrise() sunrise} to {@link getSunset() sunset} (depending on the * {@link isUseElevation()} setting). * * @see getSofZmanTfila(Instant, Instant) @@ -846,7 +846,7 @@ public Instant getSofZmanTfilaMGA72Minutes() { * is 6.5 * shaos zmaniyos (temporal hours) after the start of the day, calculated using the start and end of the * day passed to this method. The time from the start of day to the end of day are divided into 12 shaos zmaniyos * (temporal hours), and mincha gedola is calculated as 6.5 of those shaos zmaniyos after the beginning - * of the day. As an example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or + * of the day. As an example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or * {@link getSeaLevelSunrise() sea level sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link * isUseElevation()} elevation setting) to this method will return mincha gedola according to the opinion of the * GRA. Alternatively, this method uses {@link @@ -913,14 +913,14 @@ public Instant getMinchaGedola(Instant startOfDay, Instant endOfDay) { /** * This method returns the latest mincha gedola,the earliest time one can pray mincha that is 6.5 * - * {@link getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunriseWithElevation() sunrise} or + * {@link getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunrise() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting), according * to the GRA. Mincha gedola is the earliest * time one can pray mincha. The Ramba"m is of the opinion that it is better to delay mincha until * {@link getMinchaKetanaGRA() mincha ketana GRA} while the Ra"sh, Tur, GRA and others are of the * opinion that mincha can be prayed lechatchila starting at mincha gedola. * The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level - * sunset} or {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()} + * sunset} or {@link getSunrise() sunrise} to {@link getSunset() sunset} (depending on the {@link isUseElevation()} * setting). * @todo Consider adjusting this to calculate the time as half an hour zmaniyos after either {@link * getSunTransit() astronomical chatzos} or {@link getChatzosHayomAsHalfDay() chatzos as half a day} @@ -945,7 +945,7 @@ public Instant getMinchaGedolaGRA() { * start of the day, calculated using the start and end of the day passed to this method. * The time from the start of day to the end of day are divided into 12 shaos zmaniyos (temporal hours), and * samuch lemincha ketana is calculated as 9 of those shaos zmaniyos after the beginning of the day. - * For example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunrise() sea + * For example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link getSeaLevelSunrise() sea * level sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} elevation * setting) to this method will return samuch lemincha ketana according to the opinion of the * GRA. See the shaos zmaniyos (temporal hours), and * mincha ketana is calculated as 9.5 of those shaos zmaniyos after the beginning of the day. As an - * example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunrise() sea + * example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link getSeaLevelSunrise() sea * level sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} * elevation setting) to this method will return mincha ketana according to the opinion of the * GRA. This method's synchronous parameter indicates if the start @@ -1063,12 +1063,12 @@ public Instant getMinchaKetana(Instant startOfDay, Instant endOfDay) { /** * This method returns mincha ketana,the preferred earliest time to pray mincha in the * opinion of the Rambam and others, that is 9.5 - * * {@link getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunriseWithElevation() sunrise} or + * * {@link getShaahZmanisGRA() shaos zmaniyos} (solar hours) after {@link getSunrise() sunrise} or * {@link getSeaLevelSunrise() sea level sunrise} (depending on the {@link isUseElevation()} setting), according * to the GRA. For more information on this see the * documentation on {@link getMinchaGedolaGRA() mincha gedola}. * The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level - * sunset} or from {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()} + * sunset} or from {@link getSunrise() sunrise} to {@link getSunset() sunset} (depending on the {@link isUseElevation()} * setting. * * @see getMinchaKetana(Instant, Instant) @@ -1090,7 +1090,7 @@ public Instant getMinchaKetanaGRA() { * the day passed to the method. * The time from the start of day to the end of day are divided into 12 shaos zmaniyos (temporal hours), and * plag hamincha is calculated as 10.75 of those shaos zmaniyos after the beginning of the day. As an - * example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link getSeaLevelSunrise() sea level + * example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link getSeaLevelSunrise() sea level * sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} elevation * setting) to this method will return plag mincha according to the opinion of the * GRA. This method's synchronous parameter indicates if the start @@ -1144,11 +1144,11 @@ public Instant getPlagHamincha(Instant startOfDay, Instant endOfDay) { /** * This method returns plag hamincha, that is 10.75 * {@link getShaahZmanisGRA() shaos zmaniyos} - * (solar hours) after {@link getSunriseWithElevation() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on + * (solar hours) after {@link getSunrise() sunrise} or {@link getSeaLevelSunrise() sea level sunrise} (depending on * the {@link isUseElevation()} setting), according to the GRA. Plag hamincha is the earliest time that Shabbos can be started. * The day is calculated from {@link getSeaLevelSunrise() sea level sunrise} to {@link getSeaLevelSunset() sea level - * sunset} or {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() sunset} (depending on the {@link isUseElevation()} + * sunset} or {@link getSunrise() sunrise} to {@link getSunset() sunset} (depending on the {@link isUseElevation()} * * @see getPlagHamincha(Instant, Instant, boolean) * @see getPlagHamincha(Instant, Instant) @@ -1166,7 +1166,7 @@ public Instant getPlagHaminchaGRA() { * A method that returns a shaah zmanis ({@link getTemporalHour(Instant, Instant) temporal hour}) according to * the opinion of the GRA. This calculation divides the day * based on the opinion of the GRA that the day runs from from {@link getSeaLevelSunrise() sea level - * sunrise} to {@link getSeaLevelSunset() sea level sunset} or {@link getSunriseWithElevation() sunrise} to {@link getSunsetWithElevation() + * sunrise} to {@link getSeaLevelSunset() sea level sunset} or {@link getSunrise() sunrise} to {@link getSunset() * sunset} (depending on the {@link isUseElevation()} setting). The day is split into 12 equal parts with each one * being a shaah zmanis. This method is similar to {@link getTemporalHour()}, but can account for elevation. * @@ -1219,9 +1219,9 @@ public Instant getZmanisBasedOffset(double hours) { * A method that returns a shaah zmanis (temporal hour) according to the opinion of the Magen Avraham (MGA) based on a 72-minute alos * and tzais. This calculation divides the day that runs from dawn to dusk (for sof zman krias shema and - * tfila). Dawn for this calculation is 72 minutes before {@link getSunriseWithElevation() sunrise} or {@link getSeaLevelSunrise() + * tfila). Dawn for this calculation is 72 minutes before {@link getSunrise() sunrise} or {@link getSeaLevelSunrise() * sea level sunrise} (depending on the {@link isUseElevation()} elevation setting) and dusk is 72 minutes after {@link - * getSunsetWithElevation() sunset} or {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} elevation + * getSunset() sunset} or {@link getSeaLevelSunset() sea level sunset} (depending on the {@link isUseElevation()} elevation * setting). This day is split into 12 equal parts with each part being a shaah zmanis. Alternate methods of calculating * a shaah zmanis according to the Magen Avraham (MGA) are available in the subclass {@link ComprehensiveZmanimCalendar}. * @@ -1341,7 +1341,7 @@ public boolean isAssurBemlacha(Instant currentTime, Instant tzais, boolean inIsr * computed such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one * where it does not set, a null will be returned. See detailed explanation on top of the page. * - * @see getSunriseWithElevation() + * @see getSunrise() * @see getSeaLevelSunrise() * @see getSunsetBaalHatanya() * @see ZENITH_1_POINT_583 @@ -1372,7 +1372,7 @@ protected Instant getSunriseBaalHatanya() { * rise, and one where it does not set, a null will be returned. See detailed explanation on top of * the {@link AstronomicalCalendar} documentation. * - * @see getSunsetWithElevation() + * @see getSunset() * @see getSeaLevelSunset() * @see getSunriseBaalHatanya() * @see ZENITH_1_POINT_583 @@ -1385,7 +1385,7 @@ protected Instant getSunsetBaalHatanya() { * A generic utility method for calculating any shaah zmanis (temporal hour) based zman with the day * defined as the start and end of day (or night) and the number of shaos zmaniyos passed to the method. This * simplifies the code in other methods such as {@link getPlagHamincha(Instant, Instant)} and cuts down on code replication. - * As an example, passing {@link getSunriseWithElevation() sunrise} and {@link getSunsetWithElevation() sunset} or {@link + * As an example, passing {@link getSunrise() sunrise} and {@link getSunset() sunset} or {@link * getSeaLevelSunrise() sea level sunrise} and {@link getSeaLevelSunset() sea level sunset} (depending on the {@link * isUseElevation()} elevation setting) and 10.75 hours to this method will return plag mincha according to the * opinion of the GRA. diff --git a/src/test/java/com/kosherjava/zmanim/hebrewcalendar/RegressionTestFileWriter.java b/src/test/java/com/kosherjava/zmanim/hebrewcalendar/RegressionTestFileWriter.java index c98a7535..ea275fc6 100644 --- a/src/test/java/com/kosherjava/zmanim/hebrewcalendar/RegressionTestFileWriter.java +++ b/src/test/java/com/kosherjava/zmanim/hebrewcalendar/RegressionTestFileWriter.java @@ -55,7 +55,7 @@ public static void main(String[] args) throws IOException { zcal.getAlos18Degrees(), zcal.getAlos19Degrees(), zcal.getAlos19Point8Degrees(), zcal.getAlos16Point1Degrees(), zcal.getMisheyakir11Point5Degrees(), zcal.getMisheyakir11Degrees(), zcal.getMisheyakir10Point2Degrees(), zcal.getMisheyakir7Point65Degrees(), - zcal.getMisheyakir9Point5Degrees(), zcal.getSunriseWithElevation(), zcal.getSeaLevelSunrise(), + zcal.getMisheyakir9Point5Degrees(), zcal.getSunrise(), zcal.getSeaLevelSunrise(), zcal.getSofZmanShmaMGA16Point1Degrees(), zcal.getSofZmanShmaMGA72Minutes(), zcal.getSofZmanShmaMGA72MinutesZmanis(), zcal.getSofZmanShmaMGA90Minutes(), zcal.getSofZmanShmaMGA90MinutesZmanis(), zcal.getSofZmanShmaMGA96Minutes(), diff --git a/src/test/java/com/kosherjava/zmanim/util/SerializationRegressionTest.java b/src/test/java/com/kosherjava/zmanim/util/SerializationRegressionTest.java index b69bb94c..58d2218f 100644 --- a/src/test/java/com/kosherjava/zmanim/util/SerializationRegressionTest.java +++ b/src/test/java/com/kosherjava/zmanim/util/SerializationRegressionTest.java @@ -41,7 +41,7 @@ public void astronomicalCalendarPreservesSubSecondPrecision() { double utcSunrise = astronomicalCalendar.getUTCSunrise(AstronomicalCalendar.GEOMETRIC_ZENITH); long expectedEpochMillis = Math.round(utcSunrise * AstronomicalCalendar.HOUR_MILLIS); - long actualEpochMillis = astronomicalCalendar.getSunriseWithElevation().toEpochMilli() + long actualEpochMillis = astronomicalCalendar.getSunrise().toEpochMilli() % (24 * AstronomicalCalendar.HOUR_MILLIS); assertTrue(expectedEpochMillis % 1000 != 0);