QuantLib: a free/open-source library for quantitative finance
Reference manual - version 1.40
Loading...
Searching...
No Matches
ConstantRecoveryModel Class Reference

#include <ql/experimental/credit/recoveryratemodel.hpp>

Inheritance diagram for ConstantRecoveryModel:

Public Member Functions

 ConstantRecoveryModel (const Handle< RecoveryRateQuote > &quote)
 ConstantRecoveryModel (Real recovery, Seniority sen=NoSeniority)
void update () override
bool appliesToSeniority (Seniority) const override
Public Member Functions inherited from RecoveryRateModel
virtual Real recoveryValue (const Date &defaultDate, const DefaultProbKey &defaultKey=DefaultProbKey()) const
Public Member Functions inherited from Observable
 Observable (const Observable &)
Observableoperator= (const Observable &)
 Observable (Observable &&)=delete
Observableoperator= (Observable &&)=delete
void notifyObservers ()
Public Member Functions inherited from Observer
 Observer (const Observer &)
Observeroperator= (const Observer &)
std::pair< iterator, bool > registerWith (const ext::shared_ptr< Observable > &)
void registerWithObservables (const ext::shared_ptr< Observer > &)
Size unregisterWith (const ext::shared_ptr< Observable > &)
void unregisterWithAll ()
virtual void deepUpdate ()

Protected Member Functions

Real recoveryValueImpl (const Date &, const DefaultProbKey &) const override

Additional Inherited Members

Public Types inherited from Observer
typedef set_type::iterator iterator

Detailed Description

Simple Recovery Rate model returning the constant value of the quote independently of the date and the seniority.

Examples
LatentModel.cpp.

Member Function Documentation

◆ update()

void update ( )
overridevirtual

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.

◆ appliesToSeniority()

bool appliesToSeniority ( Seniority ) const
overridevirtual

Returns true if the model will return recovery rates for the requested seniority.

Implements RecoveryRateModel.

◆ recoveryValueImpl()

Real recoveryValueImpl ( const Date & ,
const DefaultProbKey &  ) const
overrideprotectedvirtual

Notice the quote's value is returned without a check on a match of the seniorties of the quote and the request.

Implements RecoveryRateModel.