Skip to content

Commit 761e5c3

Browse files
committed
Build with JDK 21 while keeping Java 11 bytecode and API docs.
Require JDK 21 for the Maven toolchain so {@snippet} Javadoc works, compile with --release 11 for runtime compatibility, and drop doclint-invalid lang attributes.
1 parent f6c15e1 commit 761e5c3

3 files changed

Lines changed: 32 additions & 13 deletions

File tree

‎.github/workflows/pull_request_worklow.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
uses: actions/setup-java@v5
1212
with:
1313
distribution: 'temurin'
14-
java-version: 11
14+
java-version: 21
1515
cache: 'maven'
1616

1717
- name: Run tests

‎pom.xml‎

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@
6060
<artifactId>maven-javadoc-plugin</artifactId>
6161
<version>3.2.0</version>
6262
<configuration>
63+
<source>11</source>
6364
<tags>
6465
<tag>
6566
<name>todo</name>
@@ -68,7 +69,7 @@
6869
</tag>
6970
</tags>
7071
<links>
71-
<link>https://docs.oracle.com/en/java/javase/17/docs/api/</link>
72+
<link>https://docs.oracle.com/en/java/javase/11/docs/api/</link>
7273
</links>
7374
<show>private</show>
7475
<header><![CDATA[<a href="http://www.kosherjava.com" target="_top">KosherJava.com</a>]]></header>
@@ -118,10 +119,29 @@
118119
<version>3.10.1</version>
119120
<configuration>
120121
<encoding>UTF-8</encoding>
121-
<source>11</source>
122-
<target>11</target>
122+
<release>11</release>
123123
</configuration>
124124
</plugin>
125+
<plugin>
126+
<groupId>org.apache.maven.plugins</groupId>
127+
<artifactId>maven-enforcer-plugin</artifactId>
128+
<version>3.5.0</version>
129+
<executions>
130+
<execution>
131+
<id>enforce-java</id>
132+
<goals>
133+
<goal>enforce</goal>
134+
</goals>
135+
<configuration>
136+
<rules>
137+
<requireJavaVersion>
138+
<version>[21,)</version>
139+
</requireJavaVersion>
140+
</rules>
141+
</configuration>
142+
</execution>
143+
</executions>
144+
</plugin>
125145
<plugin>
126146
<groupId>org.apache.maven.plugins</groupId>
127147
<artifactId>maven-surefire-plugin</artifactId>
@@ -140,7 +160,6 @@
140160
</plugins>
141161
</build>
142162
<properties>
143-
<maven.compiler.target>11</maven.compiler.target>
144-
<maven.compiler.source>11</maven.compiler.source>
163+
<maven.compiler.release>11</maven.compiler.release>
145164
</properties>
146165
</project>

‎src/main/java/com/kosherjava/zmanim/ComprehensiveZmanimCalendar.java‎

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1275,7 +1275,7 @@ public Instant getSofZmanShmaMGA120Minutes() {
12751275
* #getSeaLevelSunset() sea level sunset}. This is the opinion of the <a href=
12761276
* "https://hebrewbooks.org/40357">חידושי וכללות הרז״ה</a> in <a href="https://hebrewbooks.org/pdfpager.aspx?req=40357&pgnum=71"
12771277
* >סימן ב׳ סע״ג וסע״ד</a> and <a href="https://hebrewbooks.org/pdfpager.aspx?req=40357&pgnum=93">סי׳ ז׳ סע״ב</a> and the <a href=
1278-
* "https://hebrewbooks.org/14799">מנורה הטהורה</a> as mentioned by <span lang="he">ישראל והזמנים</span> <a href=
1278+
* "https://hebrewbooks.org/14799">מנורה הטהורה</a> as mentioned by <span>ישראל והזמנים</span> <a href=
12791279
* "https://hebrewbooks.org/pdfpager.aspx?req=9765&pgnum=81">ח״א סי׳ ז׳ פ״ג או׳ ט״ז</a>. Also see <a href=
12801280
* "https://hebrewbooks.org/pdfpager.aspx?req=67890&pgnum=29">אשר לשלמה, מועד, סי׳ ה׳</a>. Three <em>shaos zmaniyos</em> are calculated
12811281
* based on this day and added to {@link #getAlos16Point1Degrees() <em>alos</em>} to reach this time. This time is 3 <em>shaos
@@ -3917,7 +3917,7 @@ public Instant getPolarPlagHaminchaBenIshChai() {
39173917
/**
39183918
* In Polar regions during the period where the sun is above the horizon 24-hours a day, <a href=
39193919
* "https://en.wikipedia.org/wiki/Moshe_Sternbuch">Rav Moshe Sternbuch</a> in <a href=
3920-
* "https://hebrewbooks.org/pdfpager.aspx?req=19963&st=&pgnum=316">מועדים וזמנים ח״ב ס׳ קנ״ה הע׳ א׳</a> (<span lang="he">ח״ד ס׳ ת״א
3920+
* "https://hebrewbooks.org/pdfpager.aspx?req=19963&st=&pgnum=316">מועדים וזמנים ח״ב ס׳ קנ״ה הע׳ א׳</a> (<span>ח״ד ס׳ ת״א
39213921
* הע׳ א׳</span> in the new edition) and in תשובות והנהגות <a href=
39223922
* "https://hebrewbooks.org/pdfpager.aspx?req=20025&st=&pgnum=224">ח״א ס׳ שט״ו,</a> and <a href=
39233923
* "https://hebrewbooks.org/pdfpager.aspx?req=69067&st=&pgnum=135">ח״ה ס׳ פ״ד</a> ruled that during the Polar summer night-based
@@ -3930,10 +3930,10 @@ public Instant getPolarPlagHaminchaBenIshChai() {
39303930
* hashachar</em> only occurs in Antarctica and in uninhabited extreme northern regions. This means almost every northern
39313931
* inhabited location has an <em>alos hashachar</em> and "day" even on December 21st. This method considers <em>alos</em> to be
39323932
* {@link #getAlos16Point1Degrees()}.
3933-
* <p> It should be noted that in the <span lang="he">מועדים וזמנים</span> linked above that was published in 1961, Rav Moshe
3934-
* Sternbuch mentions that [<span lang="he">ולתפלה, היום מתהלק, עד י״ב שעות שחרית, ומאז מנחה, ומעריב מתפלל סמוך ללילה כרבי יהודה כנל״ד ...</span>].
3935-
* This comment (in () in the original, and [] in the new edition published in 2023) was not brought down in the <span lang="he"
3936-
* >תשובות והנהגות</span> vol. 1 that was published in 1977 nor in vol. 5. published in 2009. Since it is not clear to me if this
3933+
* <p> It should be noted that in the <span>מועדים וזמנים</span> linked above that was published in 1961, Rav Moshe
3934+
* Sternbuch mentions that [<span>ולתפלה, היום מתהלק, עד י״ב שעות שחרית, ומאז מנחה, ומעריב מתפלל סמוך ללילה כרבי יהודה כנל״ד ...</span>].
3935+
* This comment (in () in the original, and [] in the new edition published in 2023) was not brought down in the
3936+
* <span>תשובות והנהגות</span> vol. 1 that was published in 1977 nor in vol. 5. published in 2009. Since it is not clear to me if this
39373937
* constitutes a retraction, the calculations for the start of <em>mincha</em> mentioned in the Moadim Uzmanim was omitted. This
39383938
* is 12 hours after the start of the day (either {@link #getChatzosHalayla()} in the Polar summer, or {@link #getChatzosHayom()}
39393939
* in the Polar winter. {@link #getPolarPlagHaminchaTeshuvosVehanhagos()} was included and is the start of the time that
@@ -3973,7 +3973,7 @@ public Instant getPolarStartOfDayTeshuvosVehanhagos() {
39733973
/**
39743974
* In Polar regions during the period where the sun is above the horizon 24-hours a day, <a href=
39753975
* "https://en.wikipedia.org/wiki/Moshe_Sternbuch">Rav Moshe Sternbuch</a> in <a href=
3976-
* "https://hebrewbooks.org/pdfpager.aspx?req=19963&st=&pgnum=316">מועדים וזמנים ח״ב ס׳ קנ״ה הע׳ א׳</a> (<span lang="he">ח״ד ס׳ ת״א
3976+
* "https://hebrewbooks.org/pdfpager.aspx?req=19963&st=&pgnum=316">מועדים וזמנים ח״ב ס׳ קנ״ה הע׳ א׳</a> (<span>ח״ד ס׳ ת״א
39773977
* הע׳ א׳</span> in the new edition) mentions the concept of zmanim based on his {@link #getPolarStartOfDayTeshuvosVehanhagos()}.
39783978
* This calculates {@link #getPlagHamincha(Instant, Instant, boolean)} as 10.75 <em>sha'os zmaniyos</em> starting 24 hours prior
39793979
* to the current start/end of the current day. This will be very close to 2.5 clock hours before the start/end of the day.

0 commit comments

Comments
 (0)