Logo
Fully annotated reference manual - version 1.8.12
Loading...
Searching...
No Matches
bondrepo.hpp
Go to the documentation of this file.
1/*
2 Copyright (C) 2020 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 ored/portfolio/bondrepo.hpp
20 \brief Bond Repo trade data model and serialization
21 \ingroup tradedata
22 */
23
24#pragma once
25
30
31namespace ore {
32namespace data {
33
34class BondRepo : public Trade {
35public:
36 BondRepo() : Trade("BondRepo") {}
37
38 virtual void build(const QuantLib::ext::shared_ptr<EngineFactory>&) override;
39
40 virtual void fromXML(XMLNode* node) override;
41 virtual XMLNode* toXML(XMLDocument& doc) const override;
42
43 //! Add underlying Bond names
44 std::map<AssetClass, std::set<std::string>>
45 underlyingIndices(const QuantLib::ext::shared_ptr<ReferenceDataManager>& referenceDataManager = nullptr) const override;
46
48 const ore::data::LegData& cashLegData() const { return cashLegData_; }
49
50private:
53
54 QuantLib::ext::shared_ptr<ore::data::Bond> securityLeg_;
56};
57} // namespace data
58} // namespace ore
Bond trade data model and serialization.
const ore::data::BondData & bondData() const
Definition: bondrepo.hpp:47
ore::data::LegData cashLegData_
Definition: bondrepo.hpp:52
ore::data::BondData securityLegData_
Definition: bondrepo.hpp:51
QuantLib::ext::shared_ptr< ore::data::Bond > securityLeg_
Definition: bondrepo.hpp:54
const ore::data::LegData & cashLegData() const
Definition: bondrepo.hpp:48
ore::data::BondData originalSecurityLegData_
Definition: bondrepo.hpp:51
Serializable object holding leg data.
Definition: legdata.hpp:844
Trade base class.
Definition: trade.hpp:55
Small XML Document wrapper class.
Definition: xmlutils.hpp:65
leg data model and serialization
@ data
Definition: log.hpp:77
Serializable Credit Default Swap.
Definition: namespaces.docs:23
Swap trade data model and serialization.
base trade data model and serialization