Class implements Builder design pattern that can be used to create interest rate curves. More...
#include <irCurveBuilder.hpp>
Public Member Functions | |
BuildCurve () | |
constructor More... | |
BuildCurve & | asOfDate (const Date &) |
sets date of curve More... | |
BuildCurve & | withCalendar (const Calendar &) |
sets calendar More... | |
BuildCurve & | withDates (const std::vector< Date > &) |
sets grid dates of the curve More... | |
BuildCurve & | withTenors (const std::vector< Tenor > &) |
sets tenors, basing on tenors the grid dates of the curve are calculated More... | |
BuildCurve & | withTenors (const std::vector< std::string > &) |
sets tenors, basing on tenors the grid dates of the curve are calculated More... | |
BuildCurve & | withDiscountFactors (const std::vector< double > &) |
sets discount factors More... | |
BuildCurve & | withZeroCouponRate (const double) |
sets zero coupon rate More... | |
BuildCurve & | withZeroCouponRates (const std::vector< double > &) |
sets zero coupon rates More... | |
BuildCurve & | withForwardRates (const std::vector< double > &) |
sets forward rates More... | |
BuildCurve & | withSetOfInstruments (const std::vector< SmartPointer< BuildingBlock > > &) |
sets benchmark instruments More... | |
BuildCurve & | usingDiscountingCurve (const SmartPointer< ir::Curve > &) |
sets discounting curve used in multiple curve framework More... | |
BuildCurve & | usingProjectionCurve (const SmartPointer< ir::Curve > &) |
sets projection curve used in multiple curve framework More... | |
BuildCurve & | withInterestRate (const InterestRate &) |
sets interest rate convention More... | |
BuildCurve & | withInterpolator (const SmartPointer< Interpolator > &) |
sets interpolator More... | |
BuildCurve & | withExtrapolator (const SmartPointer< Extrapolator > &) |
sets extrapolator More... | |
BuildCurve & | usingEstimator (const SmartPointer< Estimator > &) |
sets estimator More... | |
BuildCurve & | withFxSpot (const double &) |
sets fx spot More... | |
operator InterpolatedCurve () | |
Creates interpolated interest rate curve. More... | |
operator FlatCurve () | |
creates flat interest rate curve More... | |
Private Types | |
enum | InputType { NONE, DF, ZCR, FWD, INSTRUMENTS } |
Auxiliary type used to identify what data are used to create curve. More... | |
Private Attributes | |
std::vector< Date > | dates_ |
dates that can be used as grid dates of interpolated interest rate curve More... | |
std::vector< Tenor > | tenors_ |
tenors that can be used to calculate grid dates More... | |
std::vector< double > | double_holder_ |
vector holding the doubles which may represent DFs, ZCRs or Fwds More... | |
double | zero_coupon_rate_ |
zero coupon rate required by flat curve More... | |
std::vector< SmartPointer< BuildingBlock > > | instruments_ |
benchmark instrument that are used to estimate curve More... | |
InterestRate | rate_ |
convention of interest rate compounding More... | |
SmartPointer< Interpolator > | interpolator_ |
interpolator used by interpolated rate curve More... | |
SmartPointer< Extrapolator > | extrapolator_ |
extrapolator used by interpolated rate curve More... | |
SmartPointer< Estimator > | estimator_ |
estimator used to estimate curve basing on the instruments More... | |
Calendar | calendar_ |
calendar used by interest rate curve More... | |
SmartPointer< ir::Curve > | discounting_curve_ |
discounting curve used in multiple curve framework More... | |
SmartPointer< ir::Curve > | projection_curve_ |
projection curve used in multiple curve framework More... | |
Date | today_ |
date of interest rate curve More... | |
double | fx_spot_ |
fx spot used by when constructing cross currency curve More... | |
InputType | method_of_construction_ |
contains information what method was used to construct curve More... | |
Detailed Description
Class implements Builder design pattern that can be used to create interest rate curves.
Class provides simple and clear interface for constructing the interest rate curve. The class contains the methods through which the parameters of curve are established. If some parameters are not given builder sets following default setting:
- interpolator - linear interpolation of zero-coupon rates
- extrapolator - extrapolating zero-coupon rate
- rate - simple compounding ACT365
The curve can be constructed by:
- providing the benchmark instruments and interest rate curve estimator
- providing the dates (or tenors) and DFs/ZCRs/Fwds.
Member Enumeration Documentation
|
strongprivate |
Auxiliary type used to identify what data are used to create curve.
Constructor & Destructor Documentation
julian::ir::BuildCurve::BuildCurve | ( | ) |
constructor
Member Function Documentation
BuildCurve & julian::ir::BuildCurve::asOfDate | ( | const Date & | input | ) |
julian::ir::BuildCurve::operator FlatCurve | ( | ) |
creates flat interest rate curve
This is conversion operator. It creates the flat curve with settings provided by other methods.
julian::ir::BuildCurve::operator InterpolatedCurve | ( | ) |
Creates interpolated interest rate curve.
This is conversion operator. It creates the interest rate curve with settings provided by other methods.
BuildCurve & julian::ir::BuildCurve::usingDiscountingCurve | ( | const SmartPointer< ir::Curve > & | input | ) |
sets discounting curve used in multiple curve framework
BuildCurve & julian::ir::BuildCurve::usingEstimator | ( | const SmartPointer< Estimator > & | input | ) |
BuildCurve & julian::ir::BuildCurve::usingProjectionCurve | ( | const SmartPointer< ir::Curve > & | input | ) |
sets projection curve used in multiple curve framework
BuildCurve & julian::ir::BuildCurve::withCalendar | ( | const Calendar & | input | ) |
BuildCurve & julian::ir::BuildCurve::withDates | ( | const std::vector< Date > & | input | ) |
sets grid dates of the curve
BuildCurve & julian::ir::BuildCurve::withDiscountFactors | ( | const std::vector< double > & | input | ) |
sets discount factors
BuildCurve & julian::ir::BuildCurve::withExtrapolator | ( | const SmartPointer< Extrapolator > & | input | ) |
sets extrapolator
- Examples:
- bootstrapperComparison.cpp.
BuildCurve & julian::ir::BuildCurve::withForwardRates | ( | const std::vector< double > & | input | ) |
sets forward rates
BuildCurve & julian::ir::BuildCurve::withFxSpot | ( | const double & | input | ) |
sets fx spot
BuildCurve & julian::ir::BuildCurve::withInterestRate | ( | const InterestRate & | input | ) |
sets interest rate convention
BuildCurve & julian::ir::BuildCurve::withInterpolator | ( | const SmartPointer< Interpolator > & | input | ) |
sets interpolator
BuildCurve & julian::ir::BuildCurve::withSetOfInstruments | ( | const std::vector< SmartPointer< BuildingBlock > > & | input | ) |
sets benchmark instruments
BuildCurve & julian::ir::BuildCurve::withTenors | ( | const std::vector< Tenor > & | input | ) |
sets tenors, basing on tenors the grid dates of the curve are calculated
BuildCurve & julian::ir::BuildCurve::withTenors | ( | const std::vector< std::string > & | input | ) |
sets tenors, basing on tenors the grid dates of the curve are calculated
BuildCurve & julian::ir::BuildCurve::withZeroCouponRate | ( | const double | input | ) |
sets zero coupon rate
- Examples:
- bondsExample.cpp.
BuildCurve & julian::ir::BuildCurve::withZeroCouponRates | ( | const std::vector< double > & | input | ) |
sets zero coupon rates
Member Data Documentation
|
private |
calendar used by interest rate curve
|
private |
dates that can be used as grid dates of interpolated interest rate curve
|
private |
discounting curve used in multiple curve framework
|
private |
vector holding the doubles which may represent DFs, ZCRs or Fwds
|
private |
estimator used to estimate curve basing on the instruments
|
private |
extrapolator used by interpolated rate curve
|
private |
fx spot used by when constructing cross currency curve
|
private |
benchmark instrument that are used to estimate curve
|
private |
interpolator used by interpolated rate curve
|
private |
contains information what method was used to construct curve
|
private |
projection curve used in multiple curve framework
|
private |
convention of interest rate compounding
|
private |
tenors that can be used to calculate grid dates
|
private |
date of interest rate curve
|
private |
zero coupon rate required by flat curve
The documentation for this class was generated from the following files:
- C:/Unix/home/OEM/jULIAN/src/marketData/interestRateCurves/irCurveBuilder.hpp
- C:/Unix/home/OEM/jULIAN/src/marketData/interestRateCurves/irCurveBuilder.cpp