base class for interest rate indexes More...
#include <ql/indexes/interestrateindex.hpp>
Inheritance diagram for InterestRateIndex:Public Member Functions | |
| InterestRateIndex (const std::string &familyName, const Period &tenor, Natural settlementDays, const Currency ¤cy, const Calendar &fixingCalendar, const DayCounter &dayCounter) | |
Index interface | |
| std::string | name () const |
| Returns the name of the index. More... | |
| Calendar | fixingCalendar () const |
| returns the calendar defining valid fixing dates | |
| bool | isValidFixingDate (const Date &fixingDate) const |
| returns TRUE if the fixing date is a valid one | |
| Rate | fixing (const Date &fixingDate, bool forecastTodaysFixing=false) const |
| returns the fixing at the given date More... | |
Observer interface | |
| void | update () |
Inspectors | |
| std::string | familyName () const |
| Period | tenor () const |
| Natural | fixingDays () const |
| Date | fixingDate (const Date &valueDate) const |
| const Currency & | currency () const |
| const DayCounter & | dayCounter () const |
Date calculations | |
These method can be overridden to implement particular conventions (e.g. EurLibor) | |
| virtual Date | valueDate (const Date &fixingDate) const |
| virtual Date | maturityDate (const Date &valueDate) const =0 |
Fixing calculations | |
| virtual Rate | forecastFixing (const Date &fixingDate) const =0 |
| It can be overridden to implement particular conventions. | |
| Rate | pastFixing (const Date &fixingDate) const |
Public Member Functions inherited from Index | |
| const TimeSeries< Real > & | timeSeries () const |
| returns the fixing TimeSeries | |
| virtual bool | allowsNativeFixings () |
| check if index allows for native fixings. More... | |
| virtual void | addFixing (const Date &fixingDate, Real fixing, bool forceOverwrite=false) |
| stores the historical fixing at the given date More... | |
| void | addFixings (const TimeSeries< Real > &t, bool forceOverwrite=false) |
| stores historical fixings from a TimeSeries More... | |
| template<class DateIterator , class ValueIterator > | |
| void | addFixings (DateIterator dBegin, DateIterator dEnd, ValueIterator vBegin, bool forceOverwrite=false) |
| stores historical fixings at the given dates More... | |
| void | clearFixings () |
| clears all stored historical fixings | |
Public Member Functions inherited from Observable | |
| Observable (const Observable &) | |
| Observable & | operator= (const Observable &) |
| void | notifyObservers () |
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 () |
Protected Attributes | |
| std::string | familyName_ |
| Period | tenor_ |
| Natural | fixingDays_ |
| Currency | currency_ |
| DayCounter | dayCounter_ |
| std::string | name_ |
base class for interest rate indexes
|
virtual |
returns the fixing at the given date
the date passed as arguments must be the actual calendar date of the fixing; no settlement days must be used.
Implements Index.
|
virtual |
This method must be implemented in derived classes. An instance of Observer does not call this method directly: instead, it will be called by the observables the instance registered with when they need to notify any changes.
Implements Observer.