class CurrencyAmount

Defined at line 39 of file ../../third_party/icu/latest/source/i18n/unicode/curramt.h

A currency together with a numeric amount, such as 200 USD.

Public Methods

void CurrencyAmount (const Formattable & amount, ConstChar16Ptr isoCode, UErrorCode & ec)

Construct an object with the given numeric amount and the given

ISO currency code.

Parameters

amount a numeric object; amount.isNumeric() must be true
isoCode the 3-letter ISO 4217 currency code; must not be nullptr and must have length 3
ec input-output error code. If the amount or the isoCode is invalid, then this will be set to a failing value. ICU 3.0
void CurrencyAmount (double amount, ConstChar16Ptr isoCode, UErrorCode & ec)

Construct an object with the given numeric amount and the given

ISO currency code.

Parameters

amount the amount of the given currency
isoCode the 3-letter ISO 4217 currency code; must not be nullptr and must have length 3
ec input-output error code. If the isoCode is invalid, then this will be set to a failing value. ICU 3.0
void CurrencyAmount (const CurrencyAmount & other)

Copy constructor

ICU 3.0

CurrencyAmount & operator= (const CurrencyAmount & other)

Assignment operator

ICU 3.0

CurrencyAmount * clone ()

Return a polymorphic clone of this object. The result will

have the same class as returned by getDynamicClassID().

ICU 3.0

void ~CurrencyAmount ()

Destructor

ICU 3.0

UClassID getDynamicClassID ()

Returns a unique class ID for this object POLYMORPHICALLY.

This method implements a simple form of RTTI used by ICU.

Returns

The class ID for this object. All objects of a given

class have the same class ID. Objects of other classes have

different class IDs.

ICU 3.0

UClassID getStaticClassID ()

Returns the class ID for this class. This is used to compare to

the return value of getDynamicClassID().

Returns

The class ID for all objects of this class.

ICU 3.0

const CurrencyUnit & getCurrency ()

Return the currency unit object of this object.

ICU 3.0

const char16_t * getISOCurrency ()

Return the ISO currency code of this object.

ICU 3.0

Defined at line 123 of file ../../third_party/icu/latest/source/i18n/unicode/curramt.h