Class implements the concept of fixed cash flow. More...

#include <FixedCashFlow.hpp>

Inheritance diagram for julian::FixedCashFlow:
julian::CashFlow

Public Member Functions

 FixedCashFlow (Date start, Date end, Date payment, double amount, double notional, bool notional_is_paid)
 constructor More...
 
 FixedCashFlow (Date start, Date end, Date payment, double q, double notional, InterestRate rate, bool notional_is_paid)
 constructor More...
 
virtual double price (const SmartPointer< ir::Curve > &disc) override
 discounts the cashflow More...
 
double value (const SmartPointer< ir::Curve > &disc) override
 prints discounted the cashflow More...
 
virtual Date getDate () const override
 returns payment date More...
 
virtual double getNotional () const override
 returns notional More...
 
virtual double getCF () const override
 returns CF More...
 
void setCashFlow (double amount) override
 sets new CF value More...
 
void setCashFlow (double quote, const InterestRate &rate) override
 calculates new CF value basing on quoting and interest rate provided More...
 
void setCashFlow (const SmartPointer< ir::Curve > &) override
 sets new CF value basing on interest rate curve More...
 
virtual void addToCashFlow (double amount)
 Increases CF by provided amount. More...
 
virtual void addToCashFlow (double quote, InterestRate rate)
 Increases CF by amount calculated using quote and rate provided. More...
 
virtual FixedCashFlowclone () const
 virtual copy constructor More...
 
- Public Member Functions inherited from julian::CashFlow
virtual ~CashFlow ()
 destructor More...
 

Private Member Functions

template<class Archive >
void serialize (Archive &ar, const unsigned int)
 interface used by Boost serialization library More...
 

Private Attributes

Date accrual_start_
 Date determining the beginning of accrual period. More...
 
Date accrual_end_
 Date determining the end of accrual period. More...
 
Date payment_date_
 Date on which the CF is paid. More...
 
double notional_
 Notional of the CF. More...
 
double amount_
 Amount paid on payment_date_. More...
 
bool notional_is_paid_
 If true notional of CF is paid on payment date with accrued amount. More...
 

Friends

class boost::serialization::access
 
std::ostream & operator<< (std::ostream &, FixedCashFlow &)
 Overloads stream operator. More...
 

Detailed Description

Class implements the concept of fixed cash flow.

Fixed cash flow is predefined amount paid on predefined date. Usually fixed cash flow is determined by interest rate given and length of accrual period covering time interval between FixedCashFlow::accrual_start_ and FixedCashFlow::accrual_end_ date.

Constructor & Destructor Documentation

julian::FixedCashFlow::FixedCashFlow ( Date  start,
Date  end,
Date  payment,
double  amount,
double  notional,
bool  notional_is_paid 
)

constructor

Creates FixedCashFlow basing on provided dates and amount

julian::FixedCashFlow::FixedCashFlow ( Date  start,
Date  end,
Date  payment,
double  quote,
double  notional,
InterestRate  rate,
bool  notional_is_paid 
)

constructor

Creates FixedCashFlow basing on provided dates, interest rate and quoting

Member Function Documentation

void julian::FixedCashFlow::addToCashFlow ( double  amount)
virtual

Increases CF by provided amount.

void julian::FixedCashFlow::addToCashFlow ( double  quote,
InterestRate  rate 
)
virtual

Increases CF by amount calculated using quote and rate provided.

FixedCashFlow * julian::FixedCashFlow::clone ( ) const
virtual

virtual copy constructor

Implements julian::CashFlow.

double julian::FixedCashFlow::getCF ( ) const
overridevirtual

returns CF

Implements julian::CashFlow.

Date julian::FixedCashFlow::getDate ( ) const
overridevirtual

returns payment date

Implements julian::CashFlow.

double julian::FixedCashFlow::getNotional ( ) const
overridevirtual

returns notional

Implements julian::CashFlow.

double julian::FixedCashFlow::price ( const SmartPointer< ir::Curve > &  disc)
overridevirtual

discounts the cashflow

Method discount the cashflow on the curve valuation date.

Implements julian::CashFlow.

template<class Archive >
void julian::FixedCashFlow::serialize ( Archive &  ar,
const unsigned  int 
)
private

interface used by Boost serialization library

void julian::FixedCashFlow::setCashFlow ( double  amount)
overridevirtual

sets new CF value

Implements julian::CashFlow.

void julian::FixedCashFlow::setCashFlow ( double  quote,
const InterestRate rate 
)
overridevirtual

calculates new CF value basing on quoting and interest rate provided

Implements julian::CashFlow.

void julian::FixedCashFlow::setCashFlow ( const SmartPointer< ir::Curve > &  )
inlineoverridevirtual

sets new CF value basing on interest rate curve

Implements julian::CashFlow.

double julian::FixedCashFlow::value ( const SmartPointer< ir::Curve > &  disc)
overridevirtual

prints discounted the cashflow

Method calculates discounted cashflow on the curve valuation date and then prints it

Implements julian::CashFlow.

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  s,
FixedCashFlow f 
)
friend

Overloads stream operator.

This overloaded operator enables to print the curve on the console.

Member Data Documentation

Date julian::FixedCashFlow::accrual_end_
private

Date determining the end of accrual period.

Date julian::FixedCashFlow::accrual_start_
private

Date determining the beginning of accrual period.

double julian::FixedCashFlow::amount_
private

Amount paid on payment_date_.

double julian::FixedCashFlow::notional_
private

Notional of the CF.

bool julian::FixedCashFlow::notional_is_paid_
private

If true notional of CF is paid on payment date with accrued amount.

Date julian::FixedCashFlow::payment_date_
private

Date on which the CF is paid.


The documentation for this class was generated from the following files:
  • C:/Unix/home/OEM/jULIAN/src/instruments/FixedCashFlow.hpp
  • C:/Unix/home/OEM/jULIAN/src/instruments/FixedCashFlow.cpp