123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416 |
- #ifndef _UCURR_H_
- #define _UCURR_H_
- #include "unicode/utypes.h"
- #include "unicode/uenum.h"
- #if !UCONFIG_NO_FORMATTING
- enum UCurrencyUsage {
-
- UCURR_USAGE_STANDARD=0,
-
- UCURR_USAGE_CASH=1,
-
- UCURR_USAGE_COUNT=2
- };
- typedef enum UCurrencyUsage UCurrencyUsage;
- U_STABLE int32_t U_EXPORT2
- ucurr_forLocale(const char* locale,
- UChar* buff,
- int32_t buffCapacity,
- UErrorCode* ec);
- typedef enum UCurrNameStyle {
-
- UCURR_SYMBOL_NAME,
-
- UCURR_LONG_NAME
- } UCurrNameStyle;
- #if !UCONFIG_NO_SERVICE
- typedef const void* UCurrRegistryKey;
- U_STABLE UCurrRegistryKey U_EXPORT2
- ucurr_register(const UChar* isoCode,
- const char* locale,
- UErrorCode* status);
- U_STABLE UBool U_EXPORT2
- ucurr_unregister(UCurrRegistryKey key, UErrorCode* status);
- #endif
- U_STABLE const UChar* U_EXPORT2
- ucurr_getName(const UChar* currency,
- const char* locale,
- UCurrNameStyle nameStyle,
- UBool* isChoiceFormat,
- int32_t* len,
- UErrorCode* ec);
- U_STABLE const UChar* U_EXPORT2
- ucurr_getPluralName(const UChar* currency,
- const char* locale,
- UBool* isChoiceFormat,
- const char* pluralCount,
- int32_t* len,
- UErrorCode* ec);
- U_STABLE int32_t U_EXPORT2
- ucurr_getDefaultFractionDigits(const UChar* currency,
- UErrorCode* ec);
- U_STABLE int32_t U_EXPORT2
- ucurr_getDefaultFractionDigitsForUsage(const UChar* currency,
- const UCurrencyUsage usage,
- UErrorCode* ec);
- U_STABLE double U_EXPORT2
- ucurr_getRoundingIncrement(const UChar* currency,
- UErrorCode* ec);
- U_STABLE double U_EXPORT2
- ucurr_getRoundingIncrementForUsage(const UChar* currency,
- const UCurrencyUsage usage,
- UErrorCode* ec);
- typedef enum UCurrCurrencyType {
-
- UCURR_ALL = INT32_MAX,
-
- UCURR_COMMON = 1,
-
- UCURR_UNCOMMON = 2,
-
- UCURR_DEPRECATED = 4,
-
- UCURR_NON_DEPRECATED = 8
- } UCurrCurrencyType;
- U_STABLE UEnumeration * U_EXPORT2
- ucurr_openISOCurrencies(uint32_t currType, UErrorCode *pErrorCode);
-
- U_STABLE UBool U_EXPORT2
- ucurr_isAvailable(const UChar* isoCode,
- UDate from,
- UDate to,
- UErrorCode* errorCode);
- U_STABLE int32_t U_EXPORT2
- ucurr_countCurrencies(const char* locale,
- UDate date,
- UErrorCode* ec);
-
- U_STABLE int32_t U_EXPORT2
- ucurr_forLocaleAndDate(const char* locale,
- UDate date,
- int32_t index,
- UChar* buff,
- int32_t buffCapacity,
- UErrorCode* ec);
- U_STABLE UEnumeration* U_EXPORT2
- ucurr_getKeywordValuesForLocale(const char* key,
- const char* locale,
- UBool commonlyUsed,
- UErrorCode* status);
- U_STABLE int32_t U_EXPORT2
- ucurr_getNumericCode(const UChar* currency);
- #endif
- #endif
|