Class NewYearsEveEarlyClose

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

public class NewYearsEveEarlyClose extends AbstractObservance
Observance of Euronext Paris's New Year's Eve half-day close (December 31). Euronext runs a shortened trading session (closing 14:05 CET) on December 31 whenever that date falls on a weekday; when December 31 falls on a Saturday or Sunday, the half-day close is not observed that year at all — unlike the London Stock Exchange (see org.holiday.calendar.observance.uk.NewYearsEveEarlyClose), Euronext does not shift the half-day session to the preceding Friday. See EuronextEveEarlyClose for the shared eligibility logic (a different use of isValidYear than its algorithm-validity use in WesternEaster/OrthodoxEaster — see org.holiday.calendar.observance.ca.ChristmasEveEarlyClose's javadoc for the same note).

Verified against Euronext's official trading calendar / half-day-close notices, including the 2016 and 2017 press releases confirming the preceding Friday traded full hours in both weekend years, cross-checked 2014-2026.

Author:
Dave Joyce
  • Constructor Details

    • NewYearsEveEarlyClose

      public NewYearsEveEarlyClose()
  • Method Details

    • computeDate

      protected final 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 final 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