Helper class building a sequence of capped/floored CPI coupons. More...
#include <qle/cashflows/cpicoupon.hpp>
Public Member Functions | |
CPILeg (const Schedule &schedule, const ext::shared_ptr< ZeroInflationIndex > &index, const Handle< YieldTermStructure > &rateCurve, const Real baseCPI, const Period &observationLag) | |
CPILeg & | withNotionals (Real notional) |
CPILeg & | withNotionals (const std::vector< Real > ¬ionals) |
CPILeg & | withFixedRates (Real fixedRate) |
CPILeg & | withFixedRates (const std::vector< Real > &fixedRates) |
CPILeg & | withPaymentDayCounter (const DayCounter &) |
CPILeg & | withPaymentAdjustment (BusinessDayConvention) |
CPILeg & | withPaymentCalendar (const Calendar &) |
CPILeg & | withPaymentLag (Natural lag) |
CPILeg & | withFixingDays (Natural fixingDays) |
CPILeg & | withFixingDays (const std::vector< Natural > &fixingDays) |
CPILeg & | withObservationInterpolation (CPI::InterpolationType) |
CPILeg & | withSubtractInflationNominal (bool) |
CPILeg & | withCaps (Rate cap) |
CPILeg & | withCaps (const std::vector< Rate > &caps) |
CPILeg & | withFloors (Rate floor) |
CPILeg & | withFloors (const std::vector< Rate > &floors) |
CPILeg & | withFinalFlowCap (Rate cap) |
CPILeg & | withFinalFlowFloor (Rate floor) |
CPILeg & | withExCouponPeriod (const Period &, const Calendar &, BusinessDayConvention, bool endOfMonth=false) |
CPILeg & | withStartDate (const Date &startDate) |
CPILeg & | withObservationLag (const Period &observationLag) |
CPILeg & | withSubtractInflationNominalAllCoupons (bool subtractInflationNominalAllCoupons) |
CPILeg & | withBaseDate (const Date &baseDate) |
operator Leg () const | |
Private Attributes | |
Schedule | schedule_ |
ext::shared_ptr< ZeroInflationIndex > | index_ |
Handle< YieldTermStructure > | rateCurve_ |
Real | baseCPI_ |
Period | observationLag_ |
std::vector< Real > | notionals_ |
std::vector< Real > | fixedRates_ |
DayCounter | paymentDayCounter_ |
BusinessDayConvention | paymentAdjustment_ |
Calendar | paymentCalendar_ |
Natural | paymentLag_ |
std::vector< Natural > | fixingDays_ |
CPI::InterpolationType | observationInterpolation_ |
bool | subtractInflationNominal_ |
std::vector< Rate > | caps_ |
std::vector< Rate > | floors_ |
double | finalFlowCap_ |
double | finalFlowFloor_ |
Period | exCouponPeriod_ |
Calendar | exCouponCalendar_ |
BusinessDayConvention | exCouponAdjustment_ |
bool | exCouponEndOfMonth_ |
bool | subtractInflationNominalAllCoupons_ |
Date | startDate_ |
Date | baseDate_ |
Helper class building a sequence of capped/floored CPI coupons.
Also allowing for the inflated notional at the end... especially if there is only one date in the schedule. If a fixedRate is zero you get a FixedRateCoupon, otherwise you get a ZeroInflationCoupon.
payoff is: spread + fixedRate x index
Definition at line 138 of file cpicoupon.hpp.
CPILeg | ( | const Schedule & | schedule, |
const ext::shared_ptr< ZeroInflationIndex > & | index, | ||
const Handle< YieldTermStructure > & | rateCurve, | ||
const Real | baseCPI, | ||
const Period & | observationLag | ||
) |
Definition at line 225 of file cpicoupon.cpp.
CPILeg & withNotionals | ( | Real | notional | ) |
Definition at line 250 of file cpicoupon.cpp.
CPILeg & withNotionals | ( | const std::vector< Real > & | notionals | ) |
Definition at line 255 of file cpicoupon.cpp.
CPILeg & withFixedRates | ( | Real | fixedRate | ) |
Definition at line 240 of file cpicoupon.cpp.
CPILeg & withFixedRates | ( | const std::vector< Real > & | fixedRates | ) |
Definition at line 245 of file cpicoupon.cpp.
CPILeg & withPaymentDayCounter | ( | const DayCounter & | dayCounter | ) |
Definition at line 265 of file cpicoupon.cpp.
CPILeg & withPaymentAdjustment | ( | BusinessDayConvention | convention | ) |
Definition at line 270 of file cpicoupon.cpp.
CPILeg & withPaymentCalendar | ( | const Calendar & | cal | ) |
CPILeg & withPaymentLag | ( | Natural | lag | ) |
Definition at line 280 of file cpicoupon.cpp.
CPILeg & withFixingDays | ( | Natural | fixingDays | ) |
Definition at line 285 of file cpicoupon.cpp.
CPILeg & withFixingDays | ( | const std::vector< Natural > & | fixingDays | ) |
Definition at line 290 of file cpicoupon.cpp.
CPILeg & withObservationInterpolation | ( | CPI::InterpolationType | interp | ) |
Definition at line 235 of file cpicoupon.cpp.
Definition at line 260 of file cpicoupon.cpp.
CPILeg & withCaps | ( | Rate | cap | ) |
Definition at line 295 of file cpicoupon.cpp.
CPILeg & withCaps | ( | const std::vector< Rate > & | caps | ) |
Definition at line 300 of file cpicoupon.cpp.
CPILeg & withFloors | ( | Rate | floor | ) |
Definition at line 305 of file cpicoupon.cpp.
CPILeg & withFloors | ( | const std::vector< Rate > & | floors | ) |
Definition at line 320 of file cpicoupon.cpp.
CPILeg & withFinalFlowCap | ( | Rate | cap | ) |
Definition at line 310 of file cpicoupon.cpp.
CPILeg & withFinalFlowFloor | ( | Rate | floor | ) |
Definition at line 315 of file cpicoupon.cpp.
CPILeg & withExCouponPeriod | ( | const Period & | period, |
const Calendar & | cal, | ||
BusinessDayConvention | convention, | ||
bool | endOfMonth = false |
||
) |
Definition at line 335 of file cpicoupon.cpp.
CPILeg & withStartDate | ( | const Date & | startDate | ) |
Definition at line 325 of file cpicoupon.cpp.
CPILeg & withObservationLag | ( | const Period & | observationLag | ) |
Definition at line 330 of file cpicoupon.cpp.
Definition at line 344 of file cpicoupon.cpp.
CPILeg & withBaseDate | ( | const Date & | baseDate | ) |
operator Leg | ( | ) | const |
Definition at line 349 of file cpicoupon.cpp.
|
private |
Definition at line 168 of file cpicoupon.hpp.
|
private |
Definition at line 169 of file cpicoupon.hpp.
|
private |
Definition at line 170 of file cpicoupon.hpp.
|
private |
Definition at line 171 of file cpicoupon.hpp.
|
private |
Definition at line 172 of file cpicoupon.hpp.
|
private |
Definition at line 173 of file cpicoupon.hpp.
|
private |
Definition at line 174 of file cpicoupon.hpp.
|
private |
Definition at line 175 of file cpicoupon.hpp.
|
private |
Definition at line 176 of file cpicoupon.hpp.
|
private |
Definition at line 177 of file cpicoupon.hpp.
|
private |
Definition at line 178 of file cpicoupon.hpp.
|
private |
Definition at line 179 of file cpicoupon.hpp.
|
private |
Definition at line 180 of file cpicoupon.hpp.
|
private |
Definition at line 181 of file cpicoupon.hpp.
|
private |
Definition at line 182 of file cpicoupon.hpp.
|
private |
Definition at line 182 of file cpicoupon.hpp.
|
private |
Definition at line 183 of file cpicoupon.hpp.
|
private |
Definition at line 183 of file cpicoupon.hpp.
|
private |
Definition at line 184 of file cpicoupon.hpp.
|
private |
Definition at line 185 of file cpicoupon.hpp.
|
private |
Definition at line 186 of file cpicoupon.hpp.
|
private |
Definition at line 187 of file cpicoupon.hpp.
|
private |
Definition at line 188 of file cpicoupon.hpp.
|
private |
Definition at line 191 of file cpicoupon.hpp.
|
private |
Definition at line 193 of file cpicoupon.hpp.