33 QL_FAIL(
"exchange rate not applicable");
44 QL_FAIL(
"exchange rate not applicable");
46 QL_FAIL(
"unknown exchange-rate type");
55 ext::make_shared<ExchangeRate>(r1),
56 ext::make_shared<ExchangeRate>(r2));
74 QL_FAIL(
"exchange rates not chainable");
exchange rate between two currencies
std::pair< ext::shared_ptr< ExchangeRate >, ext::shared_ptr< ExchangeRate > > rateChain_
static ExchangeRate chain(const ExchangeRate &r1, const ExchangeRate &r2)
chain two exchange rates
Money exchange(const Money &amount) const
apply the exchange rate to a cash amount
const Currency & currency() const
#define QL_FAIL(message)
throw an error (possibly with file and line information)
exchange rate between two currencies