40 return (
d == 22 || (
d == 23 && w ==
Monday)
51 return (
d == 30 || (
d == 31 && w ==
Monday)
68 if (y <= 1970 || y >= 1978) {
70 return (
d == 11 || (
d == 12 && w ==
Monday) ||
79 if (y <= 1970 || y >= 1978) {
90 return (
d == 19 || (
d == 20 && w ==
Monday) || ((
d == 18 && w ==
Friday) && moveToFriday))
91 && m ==
June &&
y >= 2022;
97 static auto settlementImpl = ext::make_shared<UnitedStates::SettlementImpl>();
98 static auto liborImpactImpl = ext::make_shared<UnitedStates::LiborImpactImpl>();
99 static auto nyseImpl = ext::make_shared<UnitedStates::NyseImpl>();
100 static auto governmentImpl = ext::make_shared<UnitedStates::GovernmentBondImpl>();
101 static auto nercImpl = ext::make_shared<UnitedStates::NercImpl>();
102 static auto federalReserveImpl = ext::make_shared<UnitedStates::FederalReserveImpl>();
103 static auto sofrImpl = ext::make_shared<UnitedStates::SofrImpl>();
107 impl_ = settlementImpl;
110 impl_ = liborImpactImpl;
116 impl_ = governmentImpl;
125 impl_ = federalReserveImpl;
147 || isWashingtonBirthday(
d, m,
y, w)
149 || isMemorialDay(
d, m,
y, w)
151 || isJuneteenth(
d, m,
y, w)
153 || ((
d == 4 || (
d == 5 && w ==
Monday) ||
156 || isLaborDay(
d, m,
y, w)
158 || isColumbusDay(
d, m,
y, w)
160 || isVeteransDay(
d, m,
y, w)
164 || ((
d == 25 || (
d == 26 && w ==
Monday) ||
177 if (((
d == 5 && w ==
Monday) ||
188 Day em = easterMonday(
y);
193 || isWashingtonBirthday(
d, m,
y, w)
197 || isMemorialDay(
d, m,
y, w)
199 || isJuneteenth(
d, m,
y, w)
201 || ((
d == 4 || (
d == 5 && w ==
Monday) ||
204 || isLaborDay(
d, m,
y, w)
208 || ((
d == 25 || (
d == 26 && w ==
Monday) ||
216 if ((
y <= 1968 || (
y <= 1980 &&
y % 4 == 0)) && m ==
November
225 || (
y == 2012 && m ==
October && (
d == 29 ||
d == 30))
229 || (
y == 2004 && m ==
June &&
d == 11)
231 || (
y == 2001 && m ==
September && (11 <=
d &&
d <= 14))
233 || (
y == 1994 && m ==
April &&
d == 27)
237 || (
y == 1977 && m ==
July &&
d == 14)
239 || (
y == 1973 && m ==
January &&
d == 25)
243 || (
y == 1969 && m ==
July &&
d == 21)
245 || (
y == 1969 && m ==
March &&
d == 31)
249 || (
y == 1968 && m ==
July &&
d == 5)
254 || (
y == 1968 && m ==
April &&
d == 9)
258 || (
y == 1961 && m ==
May &&
d == 29)
262 || ((
y == 1954 ||
y == 1956 ||
y == 1965)
275 Day em = easterMonday(
y);
283 || isWashingtonBirthday(
d, m,
y, w)
286 || (dd == em-3 &&
y != 2015 &&
y != 2021 &&
y != 2023)
288 || isMemorialDay(
d, m,
y, w)
290 || isJuneteenth(
d, m,
y, w)
292 || ((
d == 4 || (
d == 5 && w ==
Monday) ||
295 || isLaborDay(
d, m,
y, w)
297 || isColumbusDay(
d, m,
y, w)
299 || isVeteransDayNoSaturday(
d, m,
y, w)
303 || ((
d == 25 || (
d == 26 && w ==
Monday) ||
311 || (
y == 2012 && m ==
October && (
d == 30))
313 || (
y == 2004 && m ==
June &&
d == 11)
328 if (dY == (easterMonday(
y) - 3))
344 || isMemorialDay(
d, m,
y, w)
348 || isLaborDay(
d, m,
y, w)
371 || isWashingtonBirthday(
d, m,
y, w)
373 || isMemorialDay(
d, m,
y, w)
375 || isJuneteenth(
d, m,
y, w,
false)
379 || isLaborDay(
d, m,
y, w)
381 || isColumbusDay(
d, m,
y, w)
383 || isVeteransDayNoSaturday(
d, m,
y, w)
bool isWeekend(Weekday) const override
bool isWeekend(Weekday w) const
ext::shared_ptr< Impl > impl_
Day dayOfYear() const
One-based (Jan 1st = 1)
bool isBusinessDay(const Date &) const override
bool isBusinessDay(const Date &) const override
bool isBusinessDay(const Date &) const override
bool isBusinessDay(const Date &) const override
bool isBusinessDay(const Date &) const override
bool isBusinessDay(const Date &) const override
bool isBusinessDay(const Date &) const override
@ FederalReserve
Federal Reserve Bankwire System.
@ NYSE
New York stock exchange calendar.
@ LiborImpact
Libor impact calendar.
@ GovernmentBond
government-bond calendar
@ NERC
off-peak days for NERC
@ Settlement
generic settlement calendar
@ SOFR
SOFR fixing calendar.
UnitedStates(Market market)
Classes and functions for error handling.
#define QL_FAIL(message)
throw an error (possibly with file and line information)