QuantLib: a free/open-source library for quantitative finance
Fully annotated sources - version 1.32
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
CmsLeg Class Reference

helper class building a sequence of capped/floored cms-rate coupons More...

#include <ql/cashflows/cmscoupon.hpp>

+ Collaboration diagram for CmsLeg:

Public Member Functions

 CmsLeg (Schedule schedule, ext::shared_ptr< SwapIndex > swapIndex)
 
CmsLegwithNotionals (Real notional)
 
CmsLegwithNotionals (const std::vector< Real > &notionals)
 
CmsLegwithPaymentDayCounter (const DayCounter &)
 
CmsLegwithPaymentAdjustment (BusinessDayConvention)
 
CmsLegwithFixingDays (Natural fixingDays)
 
CmsLegwithFixingDays (const std::vector< Natural > &fixingDays)
 
CmsLegwithGearings (Real gearing)
 
CmsLegwithGearings (const std::vector< Real > &gearings)
 
CmsLegwithSpreads (Spread spread)
 
CmsLegwithSpreads (const std::vector< Spread > &spreads)
 
CmsLegwithCaps (Rate cap)
 
CmsLegwithCaps (const std::vector< Rate > &caps)
 
CmsLegwithFloors (Rate floor)
 
CmsLegwithFloors (const std::vector< Rate > &floors)
 
CmsLeginArrears (bool flag=true)
 
CmsLegwithZeroPayments (bool flag=true)
 
CmsLegwithExCouponPeriod (const Period &, const Calendar &, BusinessDayConvention, bool endOfMonth)
 
 operator Leg () const
 

Private Attributes

Schedule schedule_
 
ext::shared_ptr< SwapIndexswapIndex_
 
std::vector< Realnotionals_
 
DayCounter paymentDayCounter_
 
BusinessDayConvention paymentAdjustment_ = Following
 
std::vector< NaturalfixingDays_
 
std::vector< Realgearings_
 
std::vector< Spreadspreads_
 
std::vector< Ratecaps_
 
std::vector< Ratefloors_
 
bool inArrears_ = false
 
bool zeroPayments_ = false
 
Period exCouponPeriod_
 
Calendar exCouponCalendar_
 
BusinessDayConvention exCouponAdjustment_ = Following
 
bool exCouponEndOfMonth_ = false
 

Detailed Description

helper class building a sequence of capped/floored cms-rate coupons

Definition at line 70 of file cmscoupon.hpp.

Constructor & Destructor Documentation

◆ CmsLeg()

CmsLeg ( Schedule  schedule,
ext::shared_ptr< SwapIndex swapIndex 
)

Definition at line 57 of file cmscoupon.cpp.

Member Function Documentation

◆ withNotionals() [1/2]

CmsLeg & withNotionals ( Real  notional)

Definition at line 62 of file cmscoupon.cpp.

+ Here is the caller graph for this function:

◆ withNotionals() [2/2]

CmsLeg & withNotionals ( const std::vector< Real > &  notionals)

Definition at line 67 of file cmscoupon.cpp.

◆ withPaymentDayCounter()

CmsLeg & withPaymentDayCounter ( const DayCounter dayCounter)

Definition at line 72 of file cmscoupon.cpp.

+ Here is the caller graph for this function:

◆ withPaymentAdjustment()

CmsLeg & withPaymentAdjustment ( BusinessDayConvention  convention)

Definition at line 77 of file cmscoupon.cpp.

+ Here is the caller graph for this function:

◆ withFixingDays() [1/2]

CmsLeg & withFixingDays ( Natural  fixingDays)

Definition at line 82 of file cmscoupon.cpp.

+ Here is the caller graph for this function:

◆ withFixingDays() [2/2]

CmsLeg & withFixingDays ( const std::vector< Natural > &  fixingDays)

Definition at line 87 of file cmscoupon.cpp.

◆ withGearings() [1/2]

CmsLeg & withGearings ( Real  gearing)

Definition at line 92 of file cmscoupon.cpp.

+ Here is the caller graph for this function:

◆ withGearings() [2/2]

CmsLeg & withGearings ( const std::vector< Real > &  gearings)

Definition at line 97 of file cmscoupon.cpp.

◆ withSpreads() [1/2]

CmsLeg & withSpreads ( Spread  spread)

Definition at line 102 of file cmscoupon.cpp.

+ Here is the caller graph for this function:

◆ withSpreads() [2/2]

CmsLeg & withSpreads ( const std::vector< Spread > &  spreads)

Definition at line 107 of file cmscoupon.cpp.

◆ withCaps() [1/2]

CmsLeg & withCaps ( Rate  cap)

Definition at line 112 of file cmscoupon.cpp.

+ Here is the caller graph for this function:

◆ withCaps() [2/2]

CmsLeg & withCaps ( const std::vector< Rate > &  caps)

Definition at line 117 of file cmscoupon.cpp.

◆ withFloors() [1/2]

CmsLeg & withFloors ( Rate  floor)

Definition at line 122 of file cmscoupon.cpp.

+ Here is the caller graph for this function:

◆ withFloors() [2/2]

CmsLeg & withFloors ( const std::vector< Rate > &  floors)

Definition at line 127 of file cmscoupon.cpp.

◆ inArrears()

CmsLeg & inArrears ( bool  flag = true)

Definition at line 132 of file cmscoupon.cpp.

+ Here is the caller graph for this function:

◆ withZeroPayments()

CmsLeg & withZeroPayments ( bool  flag = true)

Definition at line 137 of file cmscoupon.cpp.

◆ withExCouponPeriod()

CmsLeg & withExCouponPeriod ( const Period period,
const Calendar cal,
BusinessDayConvention  convention,
bool  endOfMonth 
)

Definition at line 142 of file cmscoupon.cpp.

◆ operator Leg()

operator Leg ( ) const

Definition at line 154 of file cmscoupon.cpp.

Member Data Documentation

◆ schedule_

Schedule schedule_
private

Definition at line 95 of file cmscoupon.hpp.

◆ swapIndex_

ext::shared_ptr<SwapIndex> swapIndex_
private

Definition at line 96 of file cmscoupon.hpp.

◆ notionals_

std::vector<Real> notionals_
private

Definition at line 97 of file cmscoupon.hpp.

◆ paymentDayCounter_

DayCounter paymentDayCounter_
private

Definition at line 98 of file cmscoupon.hpp.

◆ paymentAdjustment_

BusinessDayConvention paymentAdjustment_ = Following
private

Definition at line 99 of file cmscoupon.hpp.

◆ fixingDays_

std::vector<Natural> fixingDays_
private

Definition at line 100 of file cmscoupon.hpp.

◆ gearings_

std::vector<Real> gearings_
private

Definition at line 101 of file cmscoupon.hpp.

◆ spreads_

std::vector<Spread> spreads_
private

Definition at line 102 of file cmscoupon.hpp.

◆ caps_

std::vector<Rate> caps_
private

Definition at line 103 of file cmscoupon.hpp.

◆ floors_

std::vector<Rate> floors_
private

Definition at line 103 of file cmscoupon.hpp.

◆ inArrears_

bool inArrears_ = false
private

Definition at line 104 of file cmscoupon.hpp.

◆ zeroPayments_

bool zeroPayments_ = false
private

Definition at line 104 of file cmscoupon.hpp.

◆ exCouponPeriod_

Period exCouponPeriod_
private

Definition at line 105 of file cmscoupon.hpp.

◆ exCouponCalendar_

Calendar exCouponCalendar_
private

Definition at line 106 of file cmscoupon.hpp.

◆ exCouponAdjustment_

BusinessDayConvention exCouponAdjustment_ = Following
private

Definition at line 107 of file cmscoupon.hpp.

◆ exCouponEndOfMonth_

bool exCouponEndOfMonth_ = false
private

Definition at line 108 of file cmscoupon.hpp.