Rogue Wave banner
Previous fileTop of DocumentContentsIndex pageNo next file
Currency Module Reference Guide
Rogue Wave web site:  Home Page  |  Main Documentation Page

RWTriangularExchange<T>

Module:  Currency   Group:  Conversion


RWTriangularExchange<T> RWExchangeImpl<T>

Local Index

Members

Synopsis

#include <rw/currency/triexchange.h>
RWTriangularExchange<double> t("ESP","PTE","EUR" 167.8,203.4);

Description

RWTriangularExchange<T> derives from the abstract base class RWExchangeImpl<T> and implements the currency conversion method used to convert between local currencies that are part of the European Monetary Union (EMU). This class may be used as an implementation class for the RWExchange<T> class, or by itself.

In the triangular currency exchange method of conversion, the source currency is converted to an intermediate currency, for example, the Euro, and the result is converted to the target currency. In a direct currency exchange, the source currency is converted directly to the target currency.

Classes RWMultiplicationExchange<T> and RWDivisionExchange<T> allow a direct conversion from a source to a target currency.

Public Static Data Member

const char* exchangeMethodName

Public Constructors

RWTriangularExchange();
RWTriangularExchange(const RWTriangularExchange<T>&);
RWTriangularExchange(const RWCString& source,
         const RWCString& target,
         const RWCString intermediate,
         double intermToSource, 
         double intermToTarget);

Public Member Operators

RWTriangularExchange<T>& 
operator=(const RWTriangularExchange<T>& t);

Public Member Functions

RWExchangeImple<T>*
clone() const;
RWMoney<T>
exchange(const RWMoney<T>&)const;
RWCString
intermediate()const;
double 
intermediateToSourceFactor() const;
double 
intermediateToTargetFactor() const;
RWCString
name() const;
void 
setIntermediate(const RWCString& currencyMnemonic);
void 
setIntermediateToSourceFactor(double factor);
void 
setIntermediateToTargetFactor(double factor);
void
setSource(const RWCString& src);
void
setTarget(const RWCString& src);
RWCString
source()const;
RWCString
target()const;


Previous fileTop of DocumentContentsIndex pageNo next file

© Copyright Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.