Class EmperorsBirthday

java.lang.Object
org.holiday.calendar.observance.AbstractObservance
org.holiday.calendar.observance.jp.EmperorsBirthday
All Implemented Interfaces:
Function<Integer,LocalDate>, Predicate<Integer>, Observance

public class EmperorsBirthday extends AbstractObservance
Observance of the Emperor's Birthday (天皇誕生日) — a Japanese national holiday marking the birthday of the reigning Emperor.

The date changes with each new Emperor:

  • 1949–1988: April 29 (Emperor Hirohito, Showa era)
  • 1989–2018: December 23 (Emperor Akihito, Heisei era)
  • 2019: not observed (Emperor Akihito abdicated April 30; Emperor Naruhito acceded May 1 — no Emperor's Birthday was designated for 2019)
  • 2020+: February 23 (Emperor Naruhito, Reiwa era)

Note: April 29 continues as a public holiday under a different name (Showa Day from 2007; Greenery Day 1989–2006) and is modelled separately in the calendar.

  • Constructor Details

    • EmperorsBirthday

      public EmperorsBirthday()
  • Method Details

    • computeDate

      protected LocalDate computeDate(int year)
      Description copied from class: AbstractObservance
      Compute the date for this observance in the given year. Only called when AbstractObservance.isValidYear(int) returns true.
      Specified by:
      computeDate in class AbstractObservance
      Parameters:
      year - the year for which to compute the date
      Returns:
      computed holiday date
    • isValidYear

      protected boolean isValidYear(int year)
      Description copied from class: AbstractObservance
      Determine whether this observance applies in the given year. Defaults to true (all years are valid).
      Overrides:
      isValidYear in class AbstractObservance
      Parameters:
      year - the year to test
      Returns:
      true if this observance applies