QuantLib: a free/open-source library for quantitative finance
fully annotated source code - version 1.34
|
amount of cash More...
#include <money.hpp>
Classes | |
struct | BaseCurrencyProxy |
struct | ConversionTypeProxy |
class | Settings |
Per-session settings for the Money class. More... | |
Public Member Functions | |
Constructors | |
Money ()=default | |
Money (Currency currency, Decimal value) | |
Money (Decimal value, Currency currency) | |
Inspectors | |
const Currency & | currency () const |
Decimal | value () const |
Money | rounded () const |
Money arithmetics | |
See below for non-member functions and for settings which determine the behavior of the operators. | |
Money | operator+ () const |
Money | operator- () const |
Money & | operator+= (const Money &) |
Money & | operator-= (const Money &) |
Money & | operator*= (Decimal) |
Money & | operator/= (Decimal) |
Related Functions | |
(Note that these are not member functions.) | |
Money | operator+ (const Money &, const Money &) |
Money | operator- (const Money &, const Money &) |
Money | operator* (const Money &, Decimal) |
Money | operator* (Decimal, const Money &) |
Money | operator/ (const Money &, Decimal) |
Decimal | operator/ (const Money &, const Money &) |
bool | operator== (const Money &, const Money &) |
bool | operator!= (const Money &, const Money &) |
bool | operator< (const Money &, const Money &) |
bool | operator<= (const Money &, const Money &) |
bool | operator> (const Money &, const Money &) |
bool | operator>= (const Money &, const Money &) |
bool | close (const Money &, const Money &, Size n=42) |
bool | close_enough (const Money &, const Money &, Size n=42) |
Money | operator* (Decimal, const Currency &) |
Money | operator* (const Currency &, Decimal) |
std::ostream & | operator<< (std::ostream &, const Money &) |
Conversion settings | |
These parameters are used for combining money amounts in different currencies | |
enum | ConversionType { NoConversion , BaseCurrencyConversion , AutomatedConversion } |
Decimal | value_ = 0.0 |
Currency | currency_ |
amount of cash
enum ConversionType |
|
default |
const Currency & currency | ( | ) | const |
Decimal value | ( | ) | const |
Money rounded | ( | ) | const |
|
related |