QuantLib: a free/open-source library for quantitative finance
fully annotated source code - version 1.34
Loading...
Searching...
No Matches
Public Member Functions | List of all members
SimpleQuote Class Reference

market element returning a stored value More...

#include <simplequote.hpp>

+ Inheritance diagram for SimpleQuote:
+ Collaboration diagram for SimpleQuote:

Public Member Functions

 SimpleQuote (Real value=Null< Real >())
 
Quote interface
Real value () const override
 returns the current value More...
 
bool isValid () const override
 returns true if the Quote holds a valid value More...
 
- Public Member Functions inherited from Quote
 ~Quote () override=default
 
virtual Real value () const =0
 returns the current value More...
 
virtual bool isValid () const =0
 returns true if the Quote holds a valid value More...
 
- Public Member Functions inherited from Observable
 Observable ()
 
 Observable (const Observable &)
 
Observableoperator= (const Observable &)
 
 Observable (Observable &&)=delete
 
Observableoperator= (Observable &&)=delete
 
virtual ~Observable ()=default
 
void notifyObservers ()
 

Modifiers

Real value_
 
Real setValue (Real value=Null< Real >())
 returns the difference between the new value and the old value More...
 
void reset ()
 

Detailed Description

market element returning a stored value

Definition at line 33 of file simplequote.hpp.

Constructor & Destructor Documentation

◆ SimpleQuote()

SimpleQuote ( Real  value = Null<Real>())

Definition at line 60 of file simplequote.hpp.

Member Function Documentation

◆ value()

Real value ( ) const
overridevirtual

returns the current value

Implements Quote.

Definition at line 63 of file simplequote.hpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isValid()

bool isValid ( ) const
overridevirtual

returns true if the Quote holds a valid value

Implements Quote.

Definition at line 68 of file simplequote.hpp.

+ Here is the caller graph for this function:

◆ setValue()

Real setValue ( Real  value = Null<Real>())

returns the difference between the new value and the old value

Definition at line 72 of file simplequote.hpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ reset()

void reset ( )

Definition at line 81 of file simplequote.hpp.

+ Here is the call graph for this function:

Member Data Documentation

◆ value_

Real value_
private

Definition at line 48 of file simplequote.hpp.