Class EasterHoliday
java.lang.Object
com.ibm.icu.util.Holiday
com.ibm.icu.util.EasterHoliday
- All Implemented Interfaces:
DateRule
Note: The Holiday framework is a technology preview. Despite its age, is still draft API,
and clients should treat it as such.
A Holiday subclass which represents holidays that occur a fixed number of days before or after Easter. Supports both the Western and Orthodox methods for calculating Easter.
- Status:
- Draft ICU 2.8 (retainAll).
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final EasterHolidayAscension, 39 days after Easterstatic final EasterHolidayAsh Wednesday, start of Lent, 47 days before Easterstatic final EasterHolidayCorpus Christi, 60 days after Easterstatic final EasterHolidayEaster Monday, 1 day after Easterstatic final EasterHolidayEaster Sundaystatic final EasterHolidayGood Friday, 2 days before Easterstatic final EasterHolidayMaundy Thursday, 3 days before Easterstatic final EasterHolidayPalm Sunday, 7 days before Easterstatic final EasterHolidayPentecost (aka Whit Sunday), 49 days after Easterstatic final EasterHolidayShrove Tuesday, aka Mardi Gras, 48 days before Easterstatic final EasterHolidayWhit Monday, 50 days after Easterstatic final EasterHolidayWhit Sunday (aka Pentecost), 49 days after Easter -
Constructor Summary
ConstructorsConstructorDescriptionEasterHoliday(int daysAfter, boolean orthodox, String name) Construct a holiday that falls a specified number of days before or after Easter Sunday each year, using either the Western or Orthodox calendar.EasterHoliday(int daysAfter, String name) Construct a holiday that falls a specified number of days before or after Easter Sunday each year.EasterHoliday(String name) Construct a holiday that falls on Easter Sunday every year -
Method Summary
Methods inherited from class Holiday
firstAfter, firstBetween, getDisplayName, getDisplayName, getDisplayName, getHolidays, getHolidays, getHolidays, getRule, isBetween, isOn, setRuleModifier and TypeMethodDescriptionfirstAfter(Date start) Return the first occurrence of this holiday on or after the given datefirstBetween(Date start, Date end) Return the first occurrence of this holiday that is on or after the given start date and before the given end date.Return the name of this holiday in the language of the defaultDISPLAYlocale.getDisplayName(ULocale locale) Return the name of this holiday in the language of the specified locale Thenameparameter passed to this object's constructor is used as a key to look up the holiday's localized name in a ResourceBundle object named HolidayBundle.getDisplayName(Locale locale) Return the name of this holiday in the language of the specified locale.static Holiday[]static Holiday[]getHolidays(ULocale locale) static Holiday[]getHolidays(Locale locale) getRule()booleanCheck whether this holiday occurs at least once between the two dates given.booleanChecks whether this holiday falls on the given date.void
-
Field Details
-
SHROVE_TUESDAY
Shrove Tuesday, aka Mardi Gras, 48 days before Easter- Status:
- Draft ICU 2.8.
-
ASH_WEDNESDAY
Ash Wednesday, start of Lent, 47 days before Easter- Status:
- Draft ICU 2.8.
-
PALM_SUNDAY
Palm Sunday, 7 days before Easter- Status:
- Draft ICU 2.8.
-
MAUNDY_THURSDAY
Maundy Thursday, 3 days before Easter- Status:
- Draft ICU 2.8.
-
GOOD_FRIDAY
Good Friday, 2 days before Easter- Status:
- Draft ICU 2.8.
-
EASTER_SUNDAY
-
EASTER_MONDAY
Easter Monday, 1 day after Easter- Status:
- Draft ICU 2.8.
-
ASCENSION
-
PENTECOST
Pentecost (aka Whit Sunday), 49 days after Easter- Status:
- Draft ICU 2.8.
-
WHIT_SUNDAY
Whit Sunday (aka Pentecost), 49 days after Easter- Status:
- Draft ICU 2.8.
-
WHIT_MONDAY
Whit Monday, 50 days after Easter- Status:
- Draft ICU 2.8.
-
CORPUS_CHRISTI
Corpus Christi, 60 days after Easter- Status:
- Draft ICU 2.8.
-
-
Constructor Details
-
EasterHoliday
Construct a holiday that falls on Easter Sunday every year- Parameters:
name- The name of the holiday- Status:
- Draft ICU 2.8.
-
EasterHoliday
Construct a holiday that falls a specified number of days before or after Easter Sunday each year.- Parameters:
daysAfter- The number of days before (-) or after (+) Eastername- The name of the holiday- Status:
- Draft ICU 2.8.
-
EasterHoliday
Construct a holiday that falls a specified number of days before or after Easter Sunday each year, using either the Western or Orthodox calendar.- Parameters:
daysAfter- The number of days before (-) or after (+) Easterorthodox- Use the Orthodox calendar?name- The name of the holiday- Status:
- Draft ICU 2.8.
-