Logo
Fully annotated reference manual - version 1.8.12
Loading...
Searching...
No Matches
Public Member Functions | List of all members
DummyMarket Class Reference

DummyMarket. More...

#include <ored/marketdata/dummymarket.hpp>

+ Inheritance diagram for DummyMarket:
+ Collaboration diagram for DummyMarket:

Public Member Functions

 DummyMarket ()
 
Date asofDate () const override
 Get the asof Date. More...
 
Handle< YieldTermStructure > discountCurveImpl (const string &key, const string &config) const override
 
Handle< YieldTermStructure > yieldCurve (const ore::data::YieldCurveType &type, const string &, const string &) const override
 
Handle< YieldTermStructure > yieldCurve (const string &, const string &) const override
 
Handle< IborIndexiborIndex (const string &, const string &) const override
 
Handle< SwapIndex > swapIndex (const string &, const string &) const override
 
Handle< SwaptionVolatilityStructureswaptionVol (const string &, const string &) const override
 
string shortSwapIndexBase (const string &, const string &) const override
 
string swapIndexBase (const string &, const string &) const override
 
Handle< SwaptionVolatilityStructureyieldVol (const string &, const string &) const override
 
Handle< QuantExt::FxIndexfxIndexImpl (const string &index, const string &) const override
 
Handle< Quote > fxSpotImpl (const string &, const string &) const override
 
Handle< Quote > fxRateImpl (const string &, const string &) const override
 
Handle< BlackVolTermStructurefxVolImpl (const string &, const string &) const override
 
Handle< QuantExt::CreditCurvedefaultCurve (const string &, const string &) const override
 
Handle< Quote > recoveryRate (const string &, const string &) const override
 
Handle< QuantExt::CreditVolCurvecdsVol (const string &, const string &) const override
 
Handle< QuantExt::BaseCorrelationTermStructurebaseCorrelation (const string &, const string &) const override
 
Handle< OptionletVolatilityStructure > capFloorVol (const string &, const string &) const override
 
std::pair< string, QuantLib::Period > capFloorVolIndexBase (const string &, const string &) const override
 
Handle< ZeroInflationIndex > zeroInflationIndex (const string &, const string &) const override
 Inflation Indexes. More...
 
Handle< YoYInflationIndex > yoyInflationIndex (const string &, const string &) const override
 
Handle< QuantExt::YoYOptionletVolatilitySurface > yoyCapFloorVol (const string &, const string &) const override
 
Handle< QuantLib::CPIVolatilitySurface > cpiInflationCapFloorVolatilitySurface (const string &, const string &) const override
 CPI Inflation Cap Floor Volatility Surfaces. More...
 
Handle< Quote > equitySpot (const string &, const string &) const override
 
Handle< YieldTermStructure > equityDividendCurve (const string &, const string &) const override
 
Handle< YieldTermStructure > equityForecastCurve (const string &, const string &) const override
 
Handle< QuantExt::EquityIndex2equityCurve (const string &eqName, const string &) const override
 
Handle< BlackVolTermStructureequityVol (const string &, const string &) const override
 
Handle< Quote > securitySpread (const string &, const string &) const override
 
QuantLib::Handle< QuantExt::PriceTermStructurecommodityPriceCurve (const std::string &, const std::string &) const override
 
QuantLib::Handle< QuantExt::CommodityIndexcommodityIndex (const std::string &, const std::string &) const override
 
QuantLib::Handle< QuantLib::BlackVolTermStructure > commodityVolatility (const std::string &, const std::string &) const override
 
QuantLib::Handle< QuantLib::Quote > cpr (const string &, const string &) const override
 
QuantLib::Handle< QuantExt::CorrelationTermStructurecorrelationCurve (const std::string &, const std::string &, const std::string &) const override
 
- Public Member Functions inherited from Market
 Market (const bool handlePseudoCurrencies)
 Constructor. More...
 
virtual ~Market ()
 Destructor. More...
 
virtual Date asofDate () const =0
 Get the asof Date. More...
 
Handle< YieldTermStructure > discountCurve (const string &ccy, const string &configuration=Market::defaultConfiguration) const
 
QuantLib::Handle< QuantExt::FxIndexfxIndex (const string &fxIndex, const string &configuration=Market::defaultConfiguration) const
 
Handle< Quote > fxRate (const string &ccypair, const string &configuration=Market::defaultConfiguration) const
 
Handle< Quote > fxSpot (const string &ccypair, const string &configuration=Market::defaultConfiguration) const
 
Handle< BlackVolTermStructurefxVol (const string &ccypair, const string &configuration=Market::defaultConfiguration) const
 
virtual void refresh (const string &)
 Refresh term structures for a given configuration. More...
 
string commodityCurveLookup (const string &pm) const
 
bool handlePseudoCurrencies () const
 

Additional Inherited Members

- Static Public Attributes inherited from Market
static const string defaultConfiguration = "default"
 Default configuration label. More...
 
static const string inCcyConfiguration = "inccy"
 InCcy configuration label. More...
 
- Protected Attributes inherited from Market
bool handlePseudoCurrencies_ = false
 

Detailed Description

DummyMarket.

Definition at line 37 of file dummymarket.hpp.

Constructor & Destructor Documentation

◆ DummyMarket()

Definition at line 39 of file dummymarket.hpp.

39: Market(false) {}
Market(const bool handlePseudoCurrencies)
Constructor.
Definition: market.hpp:166

Member Function Documentation

◆ asofDate()

Date asofDate ( ) const
overridevirtual

Get the asof Date.

Implements Market.

Definition at line 42 of file dummymarket.hpp.

42{ return Date(); }

◆ discountCurveImpl()

Handle< YieldTermStructure > discountCurveImpl ( const string &  key,
const string &  config 
) const
overridevirtual

Implements Market.

Definition at line 44 of file dummymarket.hpp.

44 {
45 return Handle<YieldTermStructure>();
46 }

◆ yieldCurve() [1/2]

Handle< YieldTermStructure > yieldCurve ( const ore::data::YieldCurveType type,
const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 47 of file dummymarket.hpp.

48 {
49 return Handle<YieldTermStructure>();
50 }

◆ yieldCurve() [2/2]

Handle< YieldTermStructure > yieldCurve ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 51 of file dummymarket.hpp.

51 {
52 return Handle<YieldTermStructure>();
53 }

◆ iborIndex()

Handle< IborIndex > iborIndex ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 54 of file dummymarket.hpp.

54 {
55 return Handle<IborIndex>(ore::data::parseIborIndex("EUR-EONIA")); // ugly, but some people check index.empty()
56 }
QuantLib::ext::shared_ptr< IborIndex > parseIborIndex(const string &s, const Handle< YieldTermStructure > &h)
Convert std::string to QuantLib::IborIndex.
+ Here is the call graph for this function:

◆ swapIndex()

Handle< SwapIndex > swapIndex ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 57 of file dummymarket.hpp.

57{ return Handle<SwapIndex>(); }

◆ swaptionVol()

Handle< SwaptionVolatilityStructure > swaptionVol ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 58 of file dummymarket.hpp.

58 {
59 return Handle<SwaptionVolatilityStructure>();
60 }

◆ shortSwapIndexBase()

string shortSwapIndexBase ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 61 of file dummymarket.hpp.

61{ return string(); }

◆ swapIndexBase()

string swapIndexBase ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 62 of file dummymarket.hpp.

62{ return string(); }

◆ yieldVol()

Handle< SwaptionVolatilityStructure > yieldVol ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 64 of file dummymarket.hpp.

64 {
65 return Handle<SwaptionVolatilityStructure>();
66 }

◆ fxIndexImpl()

Handle< QuantExt::FxIndex > fxIndexImpl ( const string &  index,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 68 of file dummymarket.hpp.

68 {
69 if (isFxIndex(index))
70 return Handle<QuantExt::FxIndex>(parseFxIndex(index));
71 return Handle<QuantExt::FxIndex>();
72 };
QuantLib::ext::shared_ptr< FxIndex > parseFxIndex(const string &s, const Handle< Quote > &fxSpot, const Handle< YieldTermStructure > &sourceYts, const Handle< YieldTermStructure > &targetYts, const bool useConventions)
Convert std::string to QuantExt::FxIndex.
bool isFxIndex(const std::string &indexName)
+ Here is the call graph for this function:

◆ fxSpotImpl()

Handle< Quote > fxSpotImpl ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 73 of file dummymarket.hpp.

73{ return Handle<Quote>(); }

◆ fxRateImpl()

Handle< Quote > fxRateImpl ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 74 of file dummymarket.hpp.

74{ return Handle<Quote>(); }

◆ fxVolImpl()

Handle< BlackVolTermStructure > fxVolImpl ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 75 of file dummymarket.hpp.

75 {
76 return Handle<BlackVolTermStructure>();
77 }

◆ defaultCurve()

Handle< QuantExt::CreditCurve > defaultCurve ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 79 of file dummymarket.hpp.

79 {
80 return Handle<QuantExt::CreditCurve>(
81 QuantLib::ext::make_shared<QuantExt::CreditCurve>(Handle<DefaultProbabilityTermStructure>()));
82 }

◆ recoveryRate()

Handle< Quote > recoveryRate ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 83 of file dummymarket.hpp.

83{ return Handle<Quote>(); }

◆ cdsVol()

Handle< QuantExt::CreditVolCurve > cdsVol ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 85 of file dummymarket.hpp.

85 {
86 return Handle<QuantExt::CreditVolCurve>();
87 }

◆ baseCorrelation()

Handle< QuantExt::BaseCorrelationTermStructure > baseCorrelation ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 89 of file dummymarket.hpp.

89 {
90 return Handle<QuantExt::BaseCorrelationTermStructure>();
91 }

◆ capFloorVol()

Handle< OptionletVolatilityStructure > capFloorVol ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 93 of file dummymarket.hpp.

93 {
94 return Handle<OptionletVolatilityStructure>();
95 }

◆ capFloorVolIndexBase()

std::pair< string, QuantLib::Period > capFloorVolIndexBase ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 97 of file dummymarket.hpp.

97 {
98 return std::make_pair(string(), 0 * Days);
99 }

◆ zeroInflationIndex()

Handle< ZeroInflationIndex > zeroInflationIndex ( const string &  indexName,
const string &  configuration 
) const
overridevirtual

Inflation Indexes.

Implements Market.

Definition at line 101 of file dummymarket.hpp.

101 {
102 return Handle<ZeroInflationIndex>();
103 }

◆ yoyInflationIndex()

Handle< YoYInflationIndex > yoyInflationIndex ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 104 of file dummymarket.hpp.

104 {
105 return Handle<YoYInflationIndex>();
106 }

◆ yoyCapFloorVol()

Handle< QuantExt::YoYOptionletVolatilitySurface > yoyCapFloorVol ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 108 of file dummymarket.hpp.

108 {
109 return Handle<QuantExt::YoYOptionletVolatilitySurface>();
110 }

◆ cpiInflationCapFloorVolatilitySurface()

Handle< QuantLib::CPIVolatilitySurface > cpiInflationCapFloorVolatilitySurface ( const string &  indexName,
const string &  configuration 
) const
overridevirtual

CPI Inflation Cap Floor Volatility Surfaces.

Implements Market.

Definition at line 112 of file dummymarket.hpp.

112 {
113 return Handle<QuantLib::CPIVolatilitySurface>();
114 }

◆ equitySpot()

Handle< Quote > equitySpot ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 116 of file dummymarket.hpp.

116{ return Handle<Quote>(); }

◆ equityDividendCurve()

Handle< YieldTermStructure > equityDividendCurve ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 117 of file dummymarket.hpp.

117 {
118 return Handle<YieldTermStructure>();
119 }

◆ equityForecastCurve()

Handle< YieldTermStructure > equityForecastCurve ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 120 of file dummymarket.hpp.

120 {
121 return Handle<YieldTermStructure>();
122 }

◆ equityCurve()

Handle< QuantExt::EquityIndex2 > equityCurve ( const string &  eqName,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 124 of file dummymarket.hpp.

124 {
125 return Handle<QuantExt::EquityIndex2>();
126 }

◆ equityVol()

Handle< BlackVolTermStructure > equityVol ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 128 of file dummymarket.hpp.

128 {
129 return Handle<BlackVolTermStructure>();
130 }

◆ securitySpread()

Handle< Quote > securitySpread ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 132 of file dummymarket.hpp.

132{ return Handle<Quote>(); }

◆ commodityPriceCurve()

QuantLib::Handle< QuantExt::PriceTermStructure > commodityPriceCurve ( const std::string &  ,
const std::string &   
) const
overridevirtual

Implements Market.

Definition at line 134 of file dummymarket.hpp.

135 {
136 return QuantLib::Handle<QuantExt::PriceTermStructure>();
137 }

◆ commodityIndex()

QuantLib::Handle< QuantExt::CommodityIndex > commodityIndex ( const std::string &  ,
const std::string &   
) const
overridevirtual

Implements Market.

Definition at line 139 of file dummymarket.hpp.

139 {
140 return QuantLib::Handle<QuantExt::CommodityIndex>();
141 }

◆ commodityVolatility()

QuantLib::Handle< QuantLib::BlackVolTermStructure > commodityVolatility ( const std::string &  ,
const std::string &   
) const
overridevirtual

Implements Market.

Definition at line 143 of file dummymarket.hpp.

144 {
145 return Handle<BlackVolTermStructure>();
146 }

◆ cpr()

QuantLib::Handle< QuantLib::Quote > cpr ( const string &  ,
const string &   
) const
overridevirtual

Implements Market.

Definition at line 148 of file dummymarket.hpp.

148 {
149 return QuantLib::Handle<QuantLib::Quote>();
150 }

◆ correlationCurve()

QuantLib::Handle< QuantExt::CorrelationTermStructure > correlationCurve ( const std::string &  ,
const std::string &  ,
const std::string &   
) const
overridevirtual

Implements Market.

Definition at line 152 of file dummymarket.hpp.

153 {
154 return QuantLib::Handle<QuantExt::CorrelationTermStructure>();
155 }