Wed, 31 Dec 2014 07:22:50 +0100
Correct previous dual key logic pending first delivery installment.
michael@0 | 1 | /* |
michael@0 | 2 | ******************************************************************************* |
michael@0 | 3 | * |
michael@0 | 4 | * Copyright (C) 1998-2011, International Business Machines |
michael@0 | 5 | * Corporation and others. All Rights Reserved. |
michael@0 | 6 | * |
michael@0 | 7 | ******************************************************************************* |
michael@0 | 8 | * |
michael@0 | 9 | * File locbund.h |
michael@0 | 10 | * |
michael@0 | 11 | * Modification History: |
michael@0 | 12 | * |
michael@0 | 13 | * Date Name Description |
michael@0 | 14 | * 10/16/98 stephen Creation. |
michael@0 | 15 | * 02/25/99 stephen Modified for new C API. |
michael@0 | 16 | ******************************************************************************* |
michael@0 | 17 | */ |
michael@0 | 18 | |
michael@0 | 19 | #ifndef LOCBUND_H |
michael@0 | 20 | #define LOCBUND_H |
michael@0 | 21 | |
michael@0 | 22 | #include "unicode/utypes.h" |
michael@0 | 23 | |
michael@0 | 24 | #if !UCONFIG_NO_FORMATTING |
michael@0 | 25 | |
michael@0 | 26 | #include "unicode/unum.h" |
michael@0 | 27 | |
michael@0 | 28 | #define ULOCALEBUNDLE_NUMBERFORMAT_COUNT ((int32_t)UNUM_SPELLOUT) |
michael@0 | 29 | |
michael@0 | 30 | typedef struct ULocaleBundle { |
michael@0 | 31 | char *fLocale; |
michael@0 | 32 | |
michael@0 | 33 | UNumberFormat *fNumberFormat[ULOCALEBUNDLE_NUMBERFORMAT_COUNT]; |
michael@0 | 34 | UBool isInvariantLocale; |
michael@0 | 35 | } ULocaleBundle; |
michael@0 | 36 | |
michael@0 | 37 | |
michael@0 | 38 | /** |
michael@0 | 39 | * Initialize a ULocaleBundle, initializing all formatters to 0. |
michael@0 | 40 | * @param result A ULocaleBundle to initialize. |
michael@0 | 41 | * @param loc The locale of the ULocaleBundle. |
michael@0 | 42 | * @return A pointer to a ULocaleBundle, or 0 if <TT>loc</TT> was invalid. |
michael@0 | 43 | */ |
michael@0 | 44 | U_CAPI ULocaleBundle * |
michael@0 | 45 | u_locbund_init(ULocaleBundle *result, const char *loc); |
michael@0 | 46 | |
michael@0 | 47 | /** |
michael@0 | 48 | * Create a new ULocaleBundle, initializing all formatters to 0. |
michael@0 | 49 | * @param loc The locale of the ULocaleBundle. |
michael@0 | 50 | * @return A pointer to a ULocaleBundle, or 0 if <TT>loc</TT> was invalid. |
michael@0 | 51 | */ |
michael@0 | 52 | /*U_CAPI ULocaleBundle * |
michael@0 | 53 | u_locbund_new(const char *loc);*/ |
michael@0 | 54 | |
michael@0 | 55 | /** |
michael@0 | 56 | * Create a deep copy of this ULocaleBundle; |
michael@0 | 57 | * @param bundle The ULocaleBundle to clone. |
michael@0 | 58 | * @return A new ULocaleBundle. |
michael@0 | 59 | */ |
michael@0 | 60 | /*U_CAPI ULocaleBundle * |
michael@0 | 61 | u_locbund_clone(const ULocaleBundle *bundle);*/ |
michael@0 | 62 | |
michael@0 | 63 | /** |
michael@0 | 64 | * Delete the specified ULocaleBundle, freeing all associated memory. |
michael@0 | 65 | * @param bundle The ULocaleBundle to delete |
michael@0 | 66 | */ |
michael@0 | 67 | U_CAPI void |
michael@0 | 68 | u_locbund_close(ULocaleBundle *bundle); |
michael@0 | 69 | |
michael@0 | 70 | /** |
michael@0 | 71 | * Get the NumberFormat used to format and parse numbers in a ULocaleBundle. |
michael@0 | 72 | * @param bundle The ULocaleBundle to use |
michael@0 | 73 | * @return A pointer to the NumberFormat used for number formatting and parsing. |
michael@0 | 74 | */ |
michael@0 | 75 | U_CAPI UNumberFormat * |
michael@0 | 76 | u_locbund_getNumberFormat(ULocaleBundle *bundle, UNumberFormatStyle style); |
michael@0 | 77 | |
michael@0 | 78 | #endif /* #if !UCONFIG_NO_FORMATTING */ |
michael@0 | 79 | |
michael@0 | 80 | #endif |