intl/icu/source/io/locbund.h

Thu, 22 Jan 2015 13:21:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 22 Jan 2015 13:21:57 +0100
branch
TOR_BUG_9701
changeset 15
b8a032363ba2
permissions
-rw-r--r--

Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6

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

mercurial