QuantLib: BondHelper Class Reference

A free/open-source library for quantitative finance Reference manual - version 1.6

- Main Page
- Related Pages
- Modules
- Classes
- Examples

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Protected Attributes | List of all members
BondHelper Class Reference

Bond helper for curve bootstrap. More...

`#include <ql/termstructures/yield/bondhelpers.hpp>`

Inheritance diagram for BondHelper:
[legend]

## Public Member Functions
| BondHelper (const Handle< Quote > &price, const boost::shared_ptr< Bond > &bond, bool useCleanPrice=true)
RateHelper interface
Real | impliedQuote () const
void | setTermStructure (YieldTermStructure *)
Additional inspectors
boost::shared_ptr< Bond > | bond () const
bool | useCleanPrice () const
Visitability
void | accept (AcyclicVisitor &)
Public Member Functions inherited from BootstrapHelper< TS >
| BootstrapHelper (const Handle< Quote > &quote)
| BootstrapHelper (Real quote)
const Handle< Quote > & | quote () const
Real | quoteError () const
virtual void | setTermStructure (TS *)
| sets the term structure to be used for pricing More...
virtual Date | earliestDate () const
| earliest relevant date More...
virtual Date | latestDate () const
| latest relevant date More...
virtual void | update ()
Public Member Functions inherited from Observer
| Observer (const Observer &)
Observer & | operator= (const Observer &)
std::pair< std::set< boost::shared_ptr< Observable > >::iterator, bool > | registerWith (const boost::shared_ptr< Observable > &)
void | registerWithObservables (const boost::shared_ptr< Observer > &)
Size | unregisterWith (const boost::shared_ptr< Observable > &)
void | unregisterWithAll ()
Public Member Functions inherited from Observable
| Observable (const Observable &)
Observable & | operator= (const Observable &)
void | notifyObservers ()

## Protected Attributes
boost::shared_ptr< Bond > | bond_
RelinkableHandle< YieldTermStructure > | termStructureHandle_
bool | useCleanPrice_
Protected Attributes inherited from BootstrapHelper< TS >
Handle< Quote > | quote_
TS * | termStructure_
Date | earliestDate_
Date | latestDate_

## Detailed Description

Bond helper for curve bootstrap.

Warning:
  This class assumes that the reference date does not change between calls of setTermStructure().

## Constructor & Destructor Documentation

BondHelper | ( | const Handle< Quote > & | price,
|  | const boost::shared_ptr< Bond > & | bond,
|  | bool | useCleanPrice = `true`
| ) |  |

Warning:
  Setting a pricing engine to the passed bond from external code will cause the bootstrap to fail or to give wrong results. It is advised to discard the bond after creating the helper, so that the helper has sole ownership of it.