ICU 50.1.2
50.1.2
|
A unit of currency, such as USD (U.S. More...
#include <currunit.h>
Public Member Functions | |
CurrencyUnit (const UChar *isoCode, UErrorCode &ec) | |
Construct an object with the given ISO currency code. More... | |
CurrencyUnit (const CurrencyUnit &other) | |
Copy constructor. More... | |
CurrencyUnit & | operator= (const CurrencyUnit &other) |
Assignment operator. More... | |
virtual UObject * | clone () const |
Return a polymorphic clone of this object. More... | |
virtual | ~CurrencyUnit () |
Destructor. More... | |
UBool | operator== (const UObject &other) const |
Equality operator. More... | |
virtual UClassID | getDynamicClassID () const |
Returns a unique class ID for this object POLYMORPHICALLY. More... | |
const UChar * | getISOCurrency () const |
Return the ISO currency code of this object. More... | |
![]() | |
virtual | ~MeasureUnit () |
Destructor. More... | |
![]() | |
virtual | ~UObject () |
Destructor. More... | |
Static Public Member Functions | |
static UClassID | getStaticClassID () |
Returns the class ID for this class. More... | |
Additional Inherited Members | |
![]() | |
MeasureUnit () | |
Default constructor. More... | |
A unit of currency, such as USD (U.S.
dollars) or JPY (Japanese yen). This class is a thin wrapper over a UChar string that subclasses MeasureUnit, for use with Measure and MeasureFormat.
Definition at line 35 of file currunit.h.
icu::CurrencyUnit::CurrencyUnit | ( | const UChar * | isoCode, |
UErrorCode & | ec | ||
) |
Construct an object with the given ISO currency code.
isoCode | the 3-letter ISO 4217 currency code; must not be NULL 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::CurrencyUnit::CurrencyUnit | ( | const CurrencyUnit & | other | ) |
Copy constructor.
|
virtual |
Destructor.
|
virtual |
Return a polymorphic clone of this object.
The result will have the same class as returned by getDynamicClassID().
Implements icu::MeasureUnit.
|
virtual |
Returns a unique class ID for this object POLYMORPHICALLY.
This method implements a simple form of RTTI used by ICU.
Implements icu::UObject.
|
inline |
Return the ISO currency code of this object.
Definition at line 110 of file currunit.h.
|
static |
Returns the class ID for this class.
This is used to compare to the return value of getDynamicClassID().
CurrencyUnit& icu::CurrencyUnit::operator= | ( | const CurrencyUnit & | other | ) |
Assignment operator.
Equality operator.
Return true if this object is equal to the given object.
Implements icu::MeasureUnit.