Logo
Fully annotated reference manual - version 1.8.12
Loading...
Searching...
No Matches
deltascenariofactory.hpp
Go to the documentation of this file.
1/*
2 Copyright (C) 2017 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 orea/scenario/deltascenariofactory.hpp
20 \brief factory class for cloning a cached scenario
21 \ingroup scenario
22*/
23
24#pragma once
25
28
29#include <boost/make_shared.hpp>
30
31namespace ore {
32namespace analytics {
33
34//! Factory class for cloning scenario objects
35/*! \ingroup scenario
36 */
38public:
39 //! Constructor
40 DeltaScenarioFactory(const QuantLib::ext::shared_ptr<ore::analytics::Scenario>& baseScenario,
41 const QuantLib::ext::shared_ptr<ore::analytics::ScenarioFactory>& scenarioFactory =
42 QuantLib::ext::make_shared<ore::analytics::SimpleScenarioFactory>(false));
43 //! returns a new scenario, using the base scenario as a starting point
44 const QuantLib::ext::shared_ptr<ore::analytics::Scenario>
45 buildScenario(QuantLib::Date asof, bool isAbsolute, const std::string& label = "",
46 QuantLib::Real numeraire = 0.0) const override;
47
48private:
49 QuantLib::ext::shared_ptr<ore::analytics::Scenario> baseScenario_;
50 QuantLib::ext::shared_ptr<ore::analytics::ScenarioFactory> scenarioFactory_;
51};
52
53} // namespace analytics
54} // namespace ore
Factory class for cloning scenario objects.
const QuantLib::ext::shared_ptr< ore::analytics::Scenario > buildScenario(QuantLib::Date asof, bool isAbsolute, const std::string &label="", QuantLib::Real numeraire=0.0) const override
returns a new scenario, using the base scenario as a starting point
QuantLib::ext::shared_ptr< ore::analytics::ScenarioFactory > scenarioFactory_
QuantLib::ext::shared_ptr< ore::analytics::Scenario > baseScenario_
Scenario factory base class.
factory classes for scenarios
factory classes for simple scenarios
Date asof(14, Jun, 2018)