32 #if U_SHOW_CPLUSPLUS_API
34 #if !UCONFIG_NO_FORMATTING
172 #ifndef U_HIDE_INTERNAL_API
179 kFormatSymbolCount = kExponentMultiplicationSymbol + 2
298 U_I18N_API void setSymbol(ENumberFormatSymbol symbol,
300 const UBool propagateDigits);
302 #ifndef U_HIDE_INTERNAL_API
343 UBool beforeCurrency,
357 UBool beforeCurrency,
399 #ifndef U_HIDE_INTERNAL_API
404 return fIsCustomCurrencySymbol;
411 return fIsCustomIntlCurrencySymbol;
418 return fCodePointZero;
439 #ifndef U_HIDE_INTERNAL_API
461 U_I18N_API inline const char16_t* getCurrencyPattern()
const;
467 U_I18N_API inline const char* getNumberingSystemName()
const;
512 const char16_t* currPattern =
nullptr;
516 UBool fIsCustomCurrencySymbol;
517 UBool fIsCustomIntlCurrencySymbol;
526 if(symbol < kFormatSymbolCount) {
527 strPtr = &fSymbols[symbol];
538 if(symbol < kFormatSymbolCount) {
539 strPtr = &fSymbols[symbol];
546 #ifndef U_HIDE_INTERNAL_API
547 inline const UnicodeString& DecimalFormatSymbols::getConstDigitSymbol(int32_t digit)
const {
548 if (digit < 0 || digit > 9) {
552 return fSymbols[kZeroDigitSymbol];
555 return fSymbols[key];
563 if (symbol == kCurrencySymbol) {
564 fIsCustomCurrencySymbol =
true;
566 else if (symbol == kIntlCurrencySymbol) {
567 fIsCustomIntlCurrencySymbol =
true;
569 if(symbol<kFormatSymbolCount) {
570 fSymbols[symbol]=value;
576 if (symbol == kZeroDigitSymbol) {
579 fCodePointZero = sym;
580 for ( int8_t i = 1 ; i<= 9 ; i++ ) {
582 fSymbols[
static_cast<int>(kOneDigitSymbol) + i - 1] =
UnicodeString(sym);
587 }
else if (symbol >= kOneDigitSymbol && symbol <= kNineDigitSymbol) {
595 DecimalFormatSymbols::getLocale()
const {
599 #ifndef U_HIDE_INTERNAL_API
600 inline const char16_t*
601 DecimalFormatSymbols::getCurrencyPattern()
const {
605 DecimalFormatSymbols::getNumberingSystemName()
const {
A Locale object represents a specific geographical, political, or cultural region.
Defines numbering systems.
UObject is the common ICU "boilerplate" class.
UnicodeString is a string class that stores Unicode characters directly and provides similar function...
UChar32 char32At(int32_t offset) const
Return the code point that contains the code unit at offset offset.
int32_t countChar32(int32_t start=0, int32_t length=INT32_MAX) const
Count Unicode code points in the length char16_t code units of the string.
C++ API: Locale ID object.
U_COMMON_API UBool operator==(const StringPiece &x, const StringPiece &y)
Global operator == for StringPiece.
constexpr const size_t kInternalNumSysNameCapacity
Size of a numbering system name.
C++ API: NumberingSystem object.
C API: Unicode Properties.
U_CAPI int32_t u_charDigitValue(UChar32 c)
Returns the decimal digit value of a decimal digit character.
ULocDataLocaleType
Constants for *_getLocale() Allow user to select whether she wants information on requested,...
int32_t UChar32
Define UChar32 as a type for single Unicode code points.
int8_t UBool
The ICU boolean type, a signed-byte integer.
C API: Compatibility APIs for number formatting.
UCurrencySpacing
Constants for specifying currency spacing.
@ UNUM_CURRENCY_SPACING_COUNT
One more than the highest normal UCurrencySpacing value.
C++ API: Common ICU base class UObject.
void * UClassID
UClassID is used to identify classes without using the compiler's RTTI.
Basic definitions for ICU, for both C and C++ APIs.
UErrorCode
Standard ICU4C error code type, a substitute for exceptions.
#define U_I18N_API_CLASS
Set to export library symbols from inside the i18n library, and to import them from outside,...
#define U_I18N_API
Set to export library symbols from inside the i18n library, and to import them from outside.