Two Hebrew Year Classes in Delphi

Last week I worked on porting across the Jewish Holiday Class from ESBPCS for VCL.

It is a descendant of our Year Class (as would be expected), which is based around a Calendar Year with supports for “negative years”. So 0 is 1 BC, -1 is 2 BC, -2 is 3 BC etc.. And if you prefer BCE/CE rather than BC/AD you can use that as well. So this class, nicely handles dates that Historians and Archaeologists need – as well as being quite useful for business today.

The Class has several useful methods, as well as a Property to control whether we are using the Gregorian or the Julian Calendar (neither of which, of course, were in use back in the “negative” years but are used for determining Leap years and other dates).

The Jewish Holiday descendant adds methods to supply Yom Kippur, Rosh Hashanah, Passover and Hanukkah for the given Calendar Year.

However, I decided it would also be nice to have a different Year Class – which is a “parallel” to the current Year Class rather than a descendant – and it would be based on the Hebrew Year rather than the Calendar Year. So for a given Hebrew Year – once again you can get Yom Kippur, Rosh Hashanah, Passover and Hanukkah – except when access string versions of these dates they will include the Hebrew Month and Year…

Now I have noticed that the Hebrew Months are spelt are variety of different ways – so we are including two versions as well as allowing a custom version where you can supply your own Months (via an event).

We will do a similar approach with the Muslim Calendar as we port that over – as well as the Ancient Roman Calendar that we have been playing with over Christmas.

Please let us know any other Jewish Holidays (besides the 4 mentioned above) that you would like to have 🙂

About esbglenn

Software Developer working at our Family owned business, ESB Consultancy, which is located in Kalgoorlie-Boulder, in the Eastern Goldfields of Western Australia.
This entry was posted in Beta Development, ESBPCS and tagged , , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.