39#include <ql/termstructures/yield/ratehelpers.hpp>
51class ReferenceDataManager;
100 const map<
string, QuantLib::ext::shared_ptr<YieldCurve>>& requiredYieldCurves =
101 map<
string, QuantLib::ext::shared_ptr<YieldCurve>>(),
103 const map<
string, QuantLib::ext::shared_ptr<DefaultCurve>>& requiredDefaultCurves =
104 map<
string, QuantLib::ext::shared_ptr<DefaultCurve>>(),
108 const QuantLib::ext::shared_ptr<ReferenceDataManager>& referenceData =
nullptr,
112 const bool preserveQuoteLinkage =
false,
114 const bool buildCalibrationInfo =
true,
116 const Market* market =
nullptr);
120 const Handle<YieldTermStructure>&
handle()
const {
return h_; }
138 RelinkableHandle<YieldTermStructure>
h_;
139 QuantLib::ext::shared_ptr<YieldTermStructure>
p_;
160 QuantLib::ext::shared_ptr<YieldCurve>
getYieldCurve(
const std::string& ccy,
const std::string&
id)
const;
176 QuantLib::ext::shared_ptr<YieldTermStructure>
piecewisecurve(vector<QuantLib::ext::shared_ptr<RateHelper>> instruments);
179 void addDeposits(
const QuantLib::ext::shared_ptr<YieldCurveSegment>& segment,
180 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
181 void addFutures(
const QuantLib::ext::shared_ptr<YieldCurveSegment>& segment,
182 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
183 void addFras(
const QuantLib::ext::shared_ptr<YieldCurveSegment>& segment,
184 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
185 void addOISs(
const QuantLib::ext::shared_ptr<YieldCurveSegment>& segment,
186 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
187 void addSwaps(
const QuantLib::ext::shared_ptr<YieldCurveSegment>& segment,
188 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
189 void addAverageOISs(
const QuantLib::ext::shared_ptr<YieldCurveSegment>& segment,
190 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
192 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
194 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
195 void addBMABasisSwaps(
const QuantLib::ext::shared_ptr<YieldCurveSegment>& segment,
196 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
197 void addFXForwards(
const QuantLib::ext::shared_ptr<YieldCurveSegment>& segment,
198 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
200 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
202 vector<QuantLib::ext::shared_ptr<RateHelper>>& instruments);
205 QuantLib::ext::shared_ptr<FXSpotQuote>
getFxSpotQuote(
string spotId);
217template <
template <
class>
class CurveType>
218QuantLib::ext::shared_ptr<YieldTermStructure>
buildYieldCurve(
const vector<Date>& dates,
const vector<QuantLib::Real>& rates,
219 const DayCounter& dayCounter,
223QuantLib::ext::shared_ptr<YieldTermStructure>
zerocurve(
const vector<Date>& dates,
const vector<Rate>& yields,
224 const DayCounter& dayCounter,
228QuantLib::ext::shared_ptr<YieldTermStructure>
discountcurve(
const vector<Date>& dates,
const vector<DiscountFactor>& dfs,
229 const DayCounter& dayCounter,
233QuantLib::ext::shared_ptr<YieldTermStructure>
forwardcurve(
const vector<Date>& dates,
const vector<Rate>& forwards,
234 const DayCounter& dayCounter,
Repository for currency dependent market conventions.
Container class for all Curve Configurations.
static IborFallbackConfig defaultConfig()
Market data loader base class.
Yield Curve configuration.
Wrapper class for building yield term structures.
QuantLib::ext::shared_ptr< YieldTermStructure > p_
void addDeposits(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
QuantLib::ext::shared_ptr< YieldCurveCalibrationInfo > calibrationInfo() const
void buildBondYieldShiftedCurve()
Build a yield curve that uses QuantExt::bondYieldShiftedCurve.
const bool preserveQuoteLinkage_
void addCrossCcyBasisSwaps(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
void buildDiscountRatioCurve()
Build a yield curve that uses QuantExt::DiscountRatioModifiedCurve.
void addTenorBasisSwaps(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
DayCounter zeroDayCounter_
void addOISs(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
void addFutures(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
map< string, QuantLib::ext::shared_ptr< DefaultCurve > > requiredDefaultCurves_
InterpolationVariable
Supported interpolation variables.
void addBMABasisSwaps(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
void addSwaps(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
const Currency & currency() const
void buildYieldPlusDefaultCurve()
Build a yield curve that uses QuantExt::YieldPlusDefaultYieldTermStructure.
void buildFittedBondCurve()
Build a yield curve that uses QuantLib::FittedBondCurve.
const Date & asofDate() const
void buildZeroSpreadedCurve()
RelinkableHandle< YieldTermStructure > h_
const QuantLib::ext::shared_ptr< ReferenceDataManager > referenceData_
void addFras(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
YieldCurveSpec curveSpec_
QuantLib::ext::shared_ptr< YieldCurveConfig > curveConfig_
const FXTriangulation & fxTriangulation_
void buildIborFallbackCurve()
Build a yield curve that uses QuantExt::IborFallbackCurve.
const Handle< YieldTermStructure > & handle() const
YieldCurveSpec curveSpec() const
void buildBootstrappedCurve()
InterpolationMethod
Supported interpolation methods.
@ LogMixedLinearCubicNaturalSpline
@ DefaultLogMixedLinearCubic
@ KrugerLogMixedLinearCubic
@ MonotonicLogMixedLinearCubic
void addTenorBasisTwoSwaps(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
void addFXForwards(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
Size mixedInterpolationSize_
InterpolationVariable interpolationVariable_
map< string, QuantLib::ext::shared_ptr< YieldCurve > > requiredYieldCurves_
void buildDiscountCurve()
InterpolationMethod interpolationMethod_
IborFallbackConfig iborFallbackConfig_
QuantLib::ext::shared_ptr< YieldCurveCalibrationInfo > calibrationInfo_
vector< QuantLib::ext::shared_ptr< YieldCurveSegment > > curveSegments_
void addCrossCcyFixFloatSwaps(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
void buildWeightedAverageCurve()
Build a yield curve that uses QuantExt::WeightedYieldTermStructure.
QuantLib::ext::shared_ptr< FXSpotQuote > getFxSpotQuote(string spotId)
QuantLib::ext::shared_ptr< YieldTermStructure > piecewisecurve(vector< QuantLib::ext::shared_ptr< RateHelper > > instruments)
QuantLib::ext::shared_ptr< YieldCurve > discountCurve_
QuantLib::ext::shared_ptr< YieldCurve > getYieldCurve(const std::string &ccy, const std::string &id) const
Return the yield curve with the given id from the requiredYieldCurves_ map.
bool buildCalibrationInfo_
void addAverageOISs(const QuantLib::ext::shared_ptr< YieldCurveSegment > &segment, vector< QuantLib::ext::shared_ptr< RateHelper > > &instruments)
Base class for yield curve segments.
Currency and instrument specific conventions/defaults.
Curve configuration repository.
Curve requirements specification.
Intelligent FX price repository.
ibor fallback configuration
Market Datum Loader Interface.
std::ostream & operator<<(std::ostream &out, EquityReturnType t)
QuantLib::ext::shared_ptr< YieldTermStructure > buildYieldCurve(const vector< Date > &dates, const vector< QuantLib::Real > &rates, const DayCounter &dayCounter, YieldCurve::InterpolationMethod interpolationMethod, Size n)
Templated function to build a YieldTermStructure and apply interpolation methods to it.
YieldCurve::InterpolationVariable parseYieldCurveInterpolationVariable(const string &s)
Helper function for parsing interpolation variable.
QuantLib::ext::shared_ptr< YieldTermStructure > discountcurve(const vector< Date > &dates, const vector< DiscountFactor > &dfs, const DayCounter &dayCounter, YieldCurve::InterpolationMethod interpolationMethod, Size n)
Create a Interpolated Discount Curve and apply interpolators.
YieldCurve::InterpolationMethod parseYieldCurveInterpolationMethod(const string &s)
Helper function for parsing interpolation method.
std::map< string, QuantLib::ext::shared_ptr< YieldCurveConfig > > YieldCurveConfigMap
QuantLib::ext::shared_ptr< YieldTermStructure > forwardcurve(const vector< Date > &dates, const vector< Rate > &forwards, const DayCounter &dayCounter, YieldCurve::InterpolationMethod interpolationMethod, Size n)
Create a Interpolated Forward Curve and apply interpolators.
QuantLib::ext::shared_ptr< YieldTermStructure > zerocurve(const vector< Date > &dates, const vector< Rate > &yields, const DayCounter &dayCounter, YieldCurve::InterpolationMethod interpolationMethod, Size n)
Create a Interpolated Zero Curve and apply interpolators.
Serializable Credit Default Swap.
vector< string > curveConfigs
a container holding information on calibration results during the t0 market build
Wrapper class for QuantLib term structures.
Yield curve configuration classes.