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

CMB coupon class. More...

#include <qle/cashflows/cmbcoupon.hpp>

+ Inheritance diagram for CmbCoupon:
+ Collaboration diagram for CmbCoupon:

Public Member Functions

 CmbCoupon (const Date &paymentDate, Real nominal, const Date &startDate, const Date &endDate, Natural fixingDays, const ext::shared_ptr< ConstantMaturityBondIndex > &index, Real gearing=1.0, Spread spread=0.0, const Date &refPeriodStart=Date(), const Date &refPeriodEnd=Date(), const DayCounter &dayCounter=DayCounter(), bool isInArrears=false, const Date &exCouponDate=Date())
 
Visitability
void accept (AcyclicVisitor &) override
 

Inspectors

ext::shared_ptr< ConstantMaturityBondIndexbondIndex_
 
const ext::shared_ptr< ConstantMaturityBondIndex > & bondIndex () const
 
void setPricer (const ext::shared_ptr< FloatingRateCouponPricer > &pricer) override
 

Detailed Description

CMB coupon class.

Definition at line 33 of file cmbcoupon.hpp.

Constructor & Destructor Documentation

◆ CmbCoupon()

CmbCoupon ( const Date &  paymentDate,
Real  nominal,
const Date &  startDate,
const Date &  endDate,
Natural  fixingDays,
const ext::shared_ptr< ConstantMaturityBondIndex > &  index,
Real  gearing = 1.0,
Spread  spread = 0.0,
const Date &  refPeriodStart = Date(),
const Date &  refPeriodEnd = Date(),
const DayCounter &  dayCounter = DayCounter(),
bool  isInArrears = false,
const Date &  exCouponDate = Date() 
)

Definition at line 26 of file cmbcoupon.cpp.

39 : FloatingRateCoupon(paymentDate, nominal, startDate, endDate,
40 fixingDays, bondIndex, gearing, spread,
41 refPeriodStart, refPeriodEnd,
42 dayCounter, isInArrears, exCouponDate),
44 registerWith(bondIndex_);
45}
const ext::shared_ptr< ConstantMaturityBondIndex > & bondIndex() const
Definition: cmbcoupon.hpp:55
ext::shared_ptr< ConstantMaturityBondIndex > bondIndex_
Definition: cmbcoupon.hpp:61

Member Function Documentation

◆ accept()

void accept ( AcyclicVisitor &  v)
override

Definition at line 47 of file cmbcoupon.cpp.

47 {
48 auto* v1 = dynamic_cast<Visitor<CmbCoupon>*>(&v);
49 if (v1 != nullptr)
50 v1->visit(*this);
51 else
52 FloatingRateCoupon::accept(v);
53}

◆ bondIndex()

const ext::shared_ptr< ConstantMaturityBondIndex > & bondIndex ( ) const

Definition at line 55 of file cmbcoupon.hpp.

55{ return bondIndex_; }
+ Here is the caller graph for this function:

◆ setPricer()

void setPricer ( const ext::shared_ptr< FloatingRateCouponPricer > &  pricer)
override

Definition at line 88 of file cmbcoupon.cpp.

88 {
89 FloatingRateCoupon::setPricer(pricer);
90}

Member Data Documentation

◆ bondIndex_

ext::shared_ptr<ConstantMaturityBondIndex> bondIndex_
private

Definition at line 61 of file cmbcoupon.hpp.