Fully annotated reference manual - version 1.8.12
Loading...
Searching...
No Matches
qle
calendars
ireland.hpp
Go to the documentation of this file.
1
/*
2
Copyright (C) 2021 Quaternion Risk Management Ltd
3
All rights reserved.
4
5
This file is part of ORE, a free-software/open-source library
6
for transparent pricing and risk analysis - http://opensourcerisk.org
7
8
ORE is free software: you can redistribute it and/or modify it
9
under the terms of the Modified BSD License. You should have received a
10
copy of the license along with this program.
11
The license is also available online at <http://opensourcerisk.org>
12
13
This program is distributed on the basis that it will form a useful
14
contribution to risk analytics and model standardisation, but WITHOUT
15
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
16
FITNESS FOR A PARTICULAR PURPOSE. See the license for more details.
17
*/
18
19
/*! \file qle/calendars/ireland.hpp
20
\brief Ireland Calendar
21
*/
22
23
#pragma once
24
25
#include <ql/time/calendar.hpp>
26
27
namespace
QuantExt
{
28
29
//! Ireland Calendars
30
/*! Public holidays:
31
<ul>
32
<li>Saturdays</li>
33
<li>Sundays</li>
34
<li>New Year's Day, January 1st (possibly moved to Monday)</li>
35
<li>Good Friday</li>
36
<li>Easter Monday</li>
37
<li>St. Patricks Day,March 17th</li>
38
<li>May Bank Holiday, first Monday of May</li>
39
<li>June Bank Holiday, first Monday of June</li>
40
<li>August Bank Holiday, first Monday of August</li>
41
<li>October Bank Holiday, last Monday of August</li>
42
<li>Christmas Day, December 25th (possibly moved to Monday or
43
Tuesday)</li>
44
<li>Boxing Day, December 26th (possibly moved to Monday or
45
Tuesday)</li>
46
</ul>
47
48
49
\ingroup calendars
50
51
\test the correctness of the returned results is tested
52
against a list of known holidays.
53
*/
54
class
Ireland
:
public
QuantLib::Calendar {
55
private
:
56
class
IrishStockExchangeImpl
:
public
QuantLib::Calendar::WesternImpl
{
57
public
:
58
std::string
name
()
const override
{
return
"IrishStockExchange"
; }
59
bool
isBusinessDay
(
const
QuantLib::Date&)
const override
;
60
};
61
class
BankHolidaysImpl
:
public
IrishStockExchangeImpl
{
62
public
:
63
std::string
name
()
const override
{
return
"Ireland"
; }
64
bool
isBusinessDay
(
const
QuantLib::Date&)
const override
;
65
};
66
67
public
:
68
enum
Market
{
IrishStockExchange
,
BankHolidays
};
69
70
Ireland
(
const
Market
market=
IrishStockExchange
);
71
};
72
}
// namespace QuantExt
QuantExt::Ireland::BankHolidaysImpl
Definition:
ireland.hpp:61
QuantExt::Ireland::BankHolidaysImpl::isBusinessDay
bool isBusinessDay(const QuantLib::Date &) const override
Definition:
ireland.cpp:72
QuantExt::Ireland::BankHolidaysImpl::name
std::string name() const override
Definition:
ireland.hpp:63
QuantExt::Ireland::IrishStockExchangeImpl
Definition:
ireland.hpp:56
QuantExt::Ireland::IrishStockExchangeImpl::isBusinessDay
bool isBusinessDay(const QuantLib::Date &) const override
Definition:
ireland.cpp:40
QuantExt::Ireland::IrishStockExchangeImpl::name
std::string name() const override
Definition:
ireland.hpp:58
QuantExt::Ireland
Ireland Calendars.
Definition:
ireland.hpp:54
QuantExt::Ireland::Market
Market
Definition:
ireland.hpp:68
QuantExt::Ireland::IrishStockExchange
@ IrishStockExchange
Definition:
ireland.hpp:68
QuantExt::Ireland::BankHolidays
@ BankHolidays
Definition:
ireland.hpp:68
QuantLib::Calendar::WesternImpl
QuantExt
Definition:
namespaces.docs:19
Generated by
Doxygen
1.9.5