00001
00002
00003
00004
00005
00006
00007 #ifndef _UCURR_H_
00008 #define _UCURR_H_
00009
00010 #include "unicode/utypes.h"
00011 #include "unicode/uenum.h"
00012
00018 #if !UCONFIG_NO_FORMATTING
00019
00052 U_STABLE int32_t U_EXPORT2
00053 ucurr_forLocale(const char* locale,
00054 UChar* buff,
00055 int32_t buffCapacity,
00056 UErrorCode* ec);
00057
00064 typedef enum UCurrNameStyle {
00070 UCURR_SYMBOL_NAME,
00071
00077 UCURR_LONG_NAME
00078 } UCurrNameStyle;
00079
00080 #if !UCONFIG_NO_SERVICE
00081
00084 typedef const void* UCurrRegistryKey;
00085
00097 U_STABLE UCurrRegistryKey U_EXPORT2
00098 ucurr_register(const UChar* isoCode,
00099 const char* locale,
00100 UErrorCode* status);
00112 U_STABLE UBool U_EXPORT2
00113 ucurr_unregister(UCurrRegistryKey key, UErrorCode* status);
00114 #endif
00115
00133 U_STABLE const UChar* U_EXPORT2
00134 ucurr_getName(const UChar* currency,
00135 const char* locale,
00136 UCurrNameStyle nameStyle,
00137 UBool* isChoiceFormat,
00138 int32_t* len,
00139 UErrorCode* ec);
00140
00150 U_STABLE int32_t U_EXPORT2
00151 ucurr_getDefaultFractionDigits(const UChar* currency,
00152 UErrorCode* ec);
00153
00163 U_STABLE double U_EXPORT2
00164 ucurr_getRoundingIncrement(const UChar* currency,
00165 UErrorCode* ec);
00166
00173 typedef enum UCurrCurrencyType {
00178 UCURR_ALL = INT32_MAX,
00187 UCURR_COMMON = 1,
00195 UCURR_UNCOMMON = 2,
00201 UCURR_DEPRECATED = 4,
00207 UCURR_NON_DEPRECATED = 8
00208 } UCurrCurrencyType;
00209
00219 U_STABLE UEnumeration * U_EXPORT2
00220 ucurr_openISOCurrencies(uint32_t currType, UErrorCode *pErrorCode);
00221
00236 U_DRAFT int32_t U_EXPORT2
00237 ucurr_countCurrencies(const char* locale,
00238 UDate date,
00239 UErrorCode* ec);
00240
00260 U_DRAFT int32_t U_EXPORT2
00261 ucurr_forLocaleAndDate(const char* locale,
00262 UDate date,
00263 int32_t index,
00264 UChar* buff,
00265 int32_t buffCapacity,
00266 UErrorCode* ec);
00267
00268 #endif
00269
00270 #endif