Changeset 215722 in webkit for trunk/Source/JavaScriptCore/icu


Ignore:
Timestamp:
Apr 24, 2017, 10:19:03 PM (8 years ago)
Author:
[email protected]
Message:

Clean up ICU headers
https://bugs.webkit.org/show_bug.cgi?id=170997

Patch by Andy VanWagoner <[email protected]> on 2017-04-24
Reviewed by JF Bastien.

Update all icu headers to 55.1

Source/JavaScriptCore:

  • icu/LICENSE: Update copyright
  • icu/README: Explain ICU headers for OS X better
  • icu/unicode/localpointer.h:

(LocalPointer::LocalPointer):
(LocalPointer::adoptInsteadAndCheckErrorCode):

  • icu/unicode/platform.h:
  • icu/unicode/putil.h:
  • icu/unicode/ucal.h:
  • icu/unicode/uchar.h:
  • icu/unicode/ucnv.h:
  • icu/unicode/ucol.h:
  • icu/unicode/uconfig.h:
  • icu/unicode/ucurr.h:
  • icu/unicode/udatpg.h:
  • icu/unicode/udisplaycontext.h:
  • icu/unicode/uformattable.h:
  • icu/unicode/uloc.h:
  • icu/unicode/umachine.h:
  • icu/unicode/unum.h:
  • icu/unicode/unumsys.h:
  • icu/unicode/urename.h:
  • icu/unicode/uscript.h:
  • icu/unicode/uset.h:
  • icu/unicode/ustring.h:
  • icu/unicode/utf8.h:
  • icu/unicode/utypes.h:

Source/WebCore:

  • icu/LICENSE: Update copyright
  • icu/README: Explain ICU headers for OS X better
  • icu/unicode/localpointer.h:

(LocalPointer::LocalPointer):
(LocalPointer::adoptInsteadAndCheckErrorCode):

  • icu/unicode/platform.h:
  • icu/unicode/putil.h:
  • icu/unicode/std_string.h:
  • icu/unicode/ubrk.h:
  • icu/unicode/uchar.h:
  • icu/unicode/ucnv.h:
  • icu/unicode/ucol.h:
  • icu/unicode/ucoleitr.h:
  • icu/unicode/uconfig.h:
  • icu/unicode/ucurr.h:
  • icu/unicode/uidna.h:
  • icu/unicode/uloc.h:
  • icu/unicode/umachine.h:
  • icu/unicode/unistr.h:

(UnicodeString::getArrayStart):
(UnicodeString::UnicodeString):
(UnicodeString::hasShortLength):
(UnicodeString::getShortLength):
(UnicodeString::length):
(UnicodeString::getCapacity):
(UnicodeString::isBogus):
(UnicodeString::isWritable):
(UnicodeString::isBufferWritable):
(UnicodeString::getBuffer):
(UnicodeString::isEmpty):
(UnicodeString::setZeroLength):
(UnicodeString::setShortLength):
(UnicodeString::setLength):
(UnicodeString::setToEmpty):
(UnicodeString::remove):

  • icu/unicode/urename.h:
  • icu/unicode/uscript.h:
  • icu/unicode/usearch.h:
  • icu/unicode/uset.h:
  • icu/unicode/ustring.h:
  • icu/unicode/utf8.h:
  • icu/unicode/utypes.h:
  • icu/unicode/uvernum.h:

Source/WebKit/mac:

  • icu/README: Explain ICU headers for OS X better
  • icu/unicode/localpointer.h:

(LocalPointer::LocalPointer):
(LocalPointer::adoptInsteadAndCheckErrorCode):

  • icu/unicode/platform.h:
  • icu/unicode/putil.h:
  • icu/unicode/uchar.h:
  • icu/unicode/uconfig.h:
  • icu/unicode/ucurr.h:
  • icu/unicode/uidna.h:
  • icu/unicode/umachine.h:
  • icu/unicode/urename.h:
  • icu/unicode/uscript.h:
  • icu/unicode/ustring.h:
  • icu/unicode/utf8.h:
  • icu/unicode/utypes.h:
  • icu/unicode/uvernum.h:

Source/WTF:

  • icu/LICENSE: Update copyright
  • icu/README: Explain ICU headers for OS X better
  • icu/unicode/localpointer.h:

(LocalPointer::LocalPointer):
(LocalPointer::adoptInsteadAndCheckErrorCode):

  • icu/unicode/platform.h:
  • icu/unicode/putil.h:
  • icu/unicode/std_string.h:
  • icu/unicode/ubrk.h:
  • icu/unicode/uchar.h:
  • icu/unicode/ucnv.h:
  • icu/unicode/ucol.h:
  • icu/unicode/uconfig.h:
  • icu/unicode/ucurr.h:
  • icu/unicode/uloc.h:
  • icu/unicode/umachine.h:
  • icu/unicode/unistr.h:

(UnicodeString::getArrayStart):
(UnicodeString::UnicodeString):
(UnicodeString::hasShortLength):
(UnicodeString::getShortLength):
(UnicodeString::length):
(UnicodeString::getCapacity):
(UnicodeString::isBogus):
(UnicodeString::isWritable):
(UnicodeString::isBufferWritable):
(UnicodeString::getBuffer):
(UnicodeString::isEmpty):
(UnicodeString::setZeroLength):
(UnicodeString::setShortLength):
(UnicodeString::setLength):
(UnicodeString::setToEmpty):
(UnicodeString::remove):

  • icu/unicode/urename.h:
  • icu/unicode/uscript.h:
  • icu/unicode/uset.h:
  • icu/unicode/ustring.h:
  • icu/unicode/utf8.h:
  • icu/unicode/utypes.h:
  • icu/unicode/uvernum.h:
Location:
trunk/Source/JavaScriptCore/icu
Files:
24 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/icu/LICENSE

    r25096 r215722  
    11COPYRIGHT AND PERMISSION NOTICE
    22
    3 Copyright (c) 1995-2006 International Business Machines Corporation and others
     3Copyright (c) 1995-2015 International Business Machines Corporation and others
    44
    55All rights reserved.
  • trunk/Source/JavaScriptCore/icu/README

    r11962 r215722  
    1 The headers in this directory are for compiling on Mac OS X 10.4.
    2 The Mac OS X 10.4 release includes the ICU binary, but not ICU headers.
     1The headers in this directory are for compiling on Mac OS X 10.4 and newer.
     2The Mac OS X 10.4 and subsequent releases include the ICU binary, but not ICU headers.
     3
    34For other platforms, installed ICU headers should be used rather than these.
    4 They are specific to Mac OS X 10.4.
     5They are specific to the Mac OS X platform.
     6
     7The headers here are from ICU version 55.1 downloaded from the ICU project.
     8http://site.icu-project.org/download/55#TOC-ICU4C-Download
     9
     10The following changes are needed again if you update the files:
     11utypes.h:62 U_SHOW_CPLUSPLUS_API 0
     12uconfig.h:90 U_DISABLE_RENAMING 1
  • trunk/Source/JavaScriptCore/icu/unicode/localpointer.h

    r196492 r215722  
    22*******************************************************************************
    33*
    4 *   Copyright (C) 2009-2012, International Business Machines
     4*   Copyright (C) 2009-2014, International Business Machines
    55*   Corporation and others.  All Rights Reserved.
    66*
     
    192192     */
    193193    explicit LocalPointer(T *p=NULL) : LocalPointerBase<T>(p) {}
     194#ifndef U_HIDE_DRAFT_API
     195    /**
     196     * Constructor takes ownership and reports an error if NULL.
     197     *
     198     * This constructor is intended to be used with other-class constructors
     199     * that may report a failure UErrorCode,
     200     * so that callers need to check only for U_FAILURE(errorCode)
     201     * and not also separately for isNull().
     202     *
     203     * @param p simple pointer to an object that is adopted
     204     * @param errorCode in/out UErrorCode, set to U_MEMORY_ALLOCATION_ERROR
     205     *     if p==NULL and no other failure code had been set
     206     * @draft ICU 55
     207     */
     208    LocalPointer(T *p, UErrorCode &errorCode) : LocalPointerBase<T>(p) {
     209        if(p==NULL && U_SUCCESS(errorCode)) {
     210            errorCode=U_MEMORY_ALLOCATION_ERROR;
     211        }
     212    }
     213#endif  /* U_HIDE_DRAFT_API */
    194214    /**
    195215     * Destructor deletes the object it owns.
     
    209229        LocalPointerBase<T>::ptr=p;
    210230    }
     231#ifndef U_HIDE_DRAFT_API
     232    /**
     233     * Deletes the object it owns,
     234     * and adopts (takes ownership of) the one passed in.
     235     *
     236     * If U_FAILURE(errorCode), then the current object is retained and the new one deleted.
     237     *
     238     * If U_SUCCESS(errorCode) but the input pointer is NULL,
     239     * then U_MEMORY_ALLOCATION_ERROR is set,
     240     * the current object is deleted, and NULL is set.
     241     *
     242     * @param p simple pointer to an object that is adopted
     243     * @param errorCode in/out UErrorCode, set to U_MEMORY_ALLOCATION_ERROR
     244     *     if p==NULL and no other failure code had been set
     245     * @draft ICU 55
     246     */
     247    void adoptInsteadAndCheckErrorCode(T *p, UErrorCode &errorCode) {
     248        if(U_SUCCESS(errorCode)) {
     249            delete LocalPointerBase<T>::ptr;
     250            LocalPointerBase<T>::ptr=p;
     251            if(p==NULL) {
     252                errorCode=U_MEMORY_ALLOCATION_ERROR;
     253            }
     254        } else {
     255            delete p;
     256        }
     257    }
     258#endif  /* U_HIDE_DRAFT_API */
    211259};
    212260
  • trunk/Source/JavaScriptCore/icu/unicode/platform.h

    r196492 r215722  
    22******************************************************************************
    33*
    4 *   Copyright (C) 1997-2013, International Business Machines
     4*   Copyright (C) 1997-2015, International Business Machines
    55*   Corporation and others.  All Rights Reserved.
    66*
     
    122122/** Linux is a Unix-like operating system. @internal */
    123123#define U_PF_LINUX 4000
     124/**
     125 * Native Client is pretty close to Linux.
     126 * See https://developer.chrome.com/native-client and
     127 *  http://www.chromium.org/nativeclient
     128 *  @internal
     129 */
     130#define U_PF_BROWSER_NATIVE_CLIENT 4020
    124131/** Android is based on Linux. @internal */
    125132#define U_PF_ANDROID 4050
    126 /** "Classic" Mac OS (1984-2001) @internal */
    127 #define U_PF_CLASSIC_MACOS 8000
     133/* Maximum value for Linux-based platform is 4499 */
    128134/** z/OS is the successor to OS/390 which was the successor to MVS. @internal */
    129135#define U_PF_OS390 9000
     
    143149    /* Android wchar_t support depends on the API level. */
    144150#   include <android/api-level.h>
     151#elif defined(__native_client__)
     152#   define U_PLATFORM U_PF_BROWSER_NATIVE_CLIENT
    145153#elif defined(linux) || defined(__linux__) || defined(__linux)
    146154#   define U_PLATFORM U_PF_LINUX
     
    170178#elif defined(sgi) || defined(__sgi)
    171179#   define U_PLATFORM U_PF_IRIX
    172 #elif defined(macintosh)
    173 #   define U_PLATFORM U_PF_CLASSIC_MACOS
    174180#elif defined(__QNX__) || defined(__QNXNTO__)
    175181#   define U_PLATFORM U_PF_QNX
     
    231237#ifdef U_PLATFORM_IMPLEMENTS_POSIX
    232238    /* Use the predefined value. */
    233 #elif U_PLATFORM_USES_ONLY_WIN32_API || U_PLATFORM == U_PF_CLASSIC_MACOS
     239#elif U_PLATFORM_USES_ONLY_WIN32_API
    234240#   define U_PLATFORM_IMPLEMENTS_POSIX 0
    235241#else
     
    244250#ifdef U_PLATFORM_IS_LINUX_BASED
    245251    /* Use the predefined value. */
    246 #elif U_PF_LINUX <= U_PLATFORM && U_PLATFORM <= U_PF_ANDROID
     252#elif U_PF_LINUX <= U_PLATFORM && U_PLATFORM <= 4499
    247253#   define U_PLATFORM_IS_LINUX_BASED 1
    248254#else
     
    580586#ifdef U_SIZEOF_WCHAR_T
    581587    /* Use the predefined value. */
    582 #elif (U_PLATFORM == U_PF_ANDROID && __ANDROID_API__ < 9) || U_PLATFORM == U_PF_CLASSIC_MACOS
     588#elif (U_PLATFORM == U_PF_ANDROID && __ANDROID_API__ < 9)
    583589    /*
    584590     * Classic Mac OS and Mac OS X before 10.3 (Panther) did not support wchar_t or wstring.
  • trunk/Source/JavaScriptCore/icu/unicode/putil.h

    r196492 r215722  
    22******************************************************************************
    33*
    4 *   Copyright (C) 1997-2011, International Business Machines
     4*   Copyright (C) 1997-2014, International Business Machines
    55*   Corporation and others.  All Rights Reserved.
    66*
     
    6767U_STABLE const char* U_EXPORT2 u_getDataDirectory(void);
    6868
     69
    6970/**
    7071 * Set the ICU data directory.
     
    8889U_STABLE void U_EXPORT2 u_setDataDirectory(const char *directory);
    8990
     91#ifndef U_HIDE_INTERNAL_API
     92/**
     93  * Return the time zone files override directory, or an empty string if
     94  * no directory was specified. Certain time zone resources will be preferrentially
     95  * loaded from individual files in this directory.
     96  *
     97  * @return the time zone data override directory.
     98  * @internal
     99  */
     100U_INTERNAL const char * U_EXPORT2 u_getTimeZoneFilesDirectory(UErrorCode *status);
     101
     102/**
     103  * Set the time zone files override directory.
     104  * This function is not thread safe; it must not be called concurrently with
     105  *   u_getTimeZoneFilesDirectory() or any other use of ICU time zone functions.
     106  * This function should only be called before using any ICU service that
     107  *   will access the time zone data.
     108  * @internal
     109  */
     110U_INTERNAL void U_EXPORT2 u_setTimeZoneFilesDirectory(const char *path, UErrorCode *status);
     111#endif  /* U_HIDE_INTERNAL_API */
     112
     113
    90114/**
    91115 * @{
     
    94118 * @stable ICU 2.0
    95119 */
    96 #if U_PLATFORM == U_PF_CLASSIC_MACOS
    97 #   define U_FILE_SEP_CHAR ':'
    98 #   define U_FILE_ALT_SEP_CHAR ':'
    99 #   define U_PATH_SEP_CHAR ';'
    100 #   define U_FILE_SEP_STRING ":"
    101 #   define U_FILE_ALT_SEP_STRING ":"
    102 #   define U_PATH_SEP_STRING ";"
    103 #elif U_PLATFORM_USES_ONLY_WIN32_API
     120#if U_PLATFORM_USES_ONLY_WIN32_API
    104121#   define U_FILE_SEP_CHAR '\\'
    105122#   define U_FILE_ALT_SEP_CHAR '/'
  • trunk/Source/JavaScriptCore/icu/unicode/ucal.h

    r196492 r215722  
    11/*
    22 *******************************************************************************
    3  * Copyright (C) 1996-2013, International Business Machines Corporation and
     3 * Copyright (C) 1996-2015, International Business Machines Corporation and
    44 * others. All Rights Reserved.
    55 *******************************************************************************
     
    423423   */
    424424  UCAL_IS_LEAP_MONTH,
    425  
     425
    426426  /**
    427427   * Field count
     
    746746                 UErrorCode*   status);
    747747
    748 #ifndef U_HIDE_DRAFT_API
    749748/**
    750749 * Get the ID of the UCalendar's time zone.
     
    755754 * @param status        Receives the status.
    756755 * @return              The total buffer size needed; if greater than resultLength, the output was truncated.
    757  * @draft ICU 51
     756 * @stable ICU 51
    758757 */
    759 U_DRAFT int32_t U_EXPORT2
     758U_STABLE int32_t U_EXPORT2
    760759ucal_getTimeZoneID(const UCalendar *cal,
    761760                   UChar *result,
    762761                   int32_t resultLength,
    763762                   UErrorCode *status);
    764 #endif /* U_HIDE_DRAFT_API */
    765763
    766764/**
     
    12901288 * @param isSystemID        Receives if the given ID is a known system
    12911289     *                      timezone ID.
    1292  * @param status    Recevies the status.  When the given timezone ID
     1290 * @param status    Receives the status.  When the given timezone ID
    12931291 *                  is neither a known system time zone ID nor a
    12941292 *                  valid custom timezone ID, U_ILLEGAL_ARGUMENT_ERROR
     
    14941492* @stable ICU 50
    14951493*/
    1496 U_DRAFT UBool U_EXPORT2
     1494U_STABLE UBool U_EXPORT2
    14971495ucal_getTimeZoneTransitionDate(const UCalendar* cal, UTimeZoneTransitionType type,
    14981496                               UDate* transition, UErrorCode* status);
    14991497
    1500 #ifndef U_HIDE_DRAFT_API
    15011498/**
    15021499* Converts a system time zone ID to an equivalent Windows time zone ID. For example,
     
    15211518* @see ucal_getTimeZoneIDForWindowsID
    15221519*
    1523 * @draft ICU 52
     1520* @stable ICU 52
    15241521*/
    1525 U_DRAFT int32_t U_EXPORT2
     1522U_STABLE int32_t U_EXPORT2
    15261523ucal_getWindowsTimeZoneID(const UChar* id, int32_t len,
    15271524                            UChar* winid, int32_t winidCapacity, UErrorCode* status);
     
    15531550* @see ucal_getWindowsTimeZoneID
    15541551*
    1555 * @draft ICU 52
     1552* @stable ICU 52
    15561553*/
    1557 U_DRAFT int32_t U_EXPORT2
     1554U_STABLE int32_t U_EXPORT2
    15581555ucal_getTimeZoneIDForWindowsID(const UChar* winid, int32_t len, const char* region,
    15591556                                UChar* id, int32_t idCapacity, UErrorCode* status);
    15601557
    1561 #endif  /* U_HIDE_DRAFT_API */
    1562 
    15631558#endif /* #if !UCONFIG_NO_FORMATTING */
    15641559
  • trunk/Source/JavaScriptCore/icu/unicode/uchar.h

    r196492 r215722  
    11/*
    22**********************************************************************
    3 *   Copyright (C) 1997-2013, International Business Machines
     3*   Copyright (C) 1997-2014, International Business Machines
    44*   Corporation and others.  All Rights Reserved.
    55**********************************************************************
     
    4040 * @stable ICU 2.0
    4141 */
    42 #define U_UNICODE_VERSION "6.3"
     42#define U_UNICODE_VERSION "7.0"
    4343
    4444/**
     
    14531453    UBLOCK_TAKRI = 220, /*[11680]*/
    14541454
    1455     /** @stable ICU 2.0 */
    1456     UBLOCK_COUNT = 221,
     1455    /* New blocks in Unicode 7.0 */
     1456
     1457    /** @stable ICU 54 */
     1458    UBLOCK_BASSA_VAH = 221, /*[16AD0]*/
     1459    /** @stable ICU 54 */
     1460    UBLOCK_CAUCASIAN_ALBANIAN = 222, /*[10530]*/
     1461    /** @stable ICU 54 */
     1462    UBLOCK_COPTIC_EPACT_NUMBERS = 223, /*[102E0]*/
     1463    /** @stable ICU 54 */
     1464    UBLOCK_COMBINING_DIACRITICAL_MARKS_EXTENDED = 224, /*[1AB0]*/
     1465    /** @stable ICU 54 */
     1466    UBLOCK_DUPLOYAN = 225, /*[1BC00]*/
     1467    /** @stable ICU 54 */
     1468    UBLOCK_ELBASAN = 226, /*[10500]*/
     1469    /** @stable ICU 54 */
     1470    UBLOCK_GEOMETRIC_SHAPES_EXTENDED = 227, /*[1F780]*/
     1471    /** @stable ICU 54 */
     1472    UBLOCK_GRANTHA = 228, /*[11300]*/
     1473    /** @stable ICU 54 */
     1474    UBLOCK_KHOJKI = 229, /*[11200]*/
     1475    /** @stable ICU 54 */
     1476    UBLOCK_KHUDAWADI = 230, /*[112B0]*/
     1477    /** @stable ICU 54 */
     1478    UBLOCK_LATIN_EXTENDED_E = 231, /*[AB30]*/
     1479    /** @stable ICU 54 */
     1480    UBLOCK_LINEAR_A = 232, /*[10600]*/
     1481    /** @stable ICU 54 */
     1482    UBLOCK_MAHAJANI = 233, /*[11150]*/
     1483    /** @stable ICU 54 */
     1484    UBLOCK_MANICHAEAN = 234, /*[10AC0]*/
     1485    /** @stable ICU 54 */
     1486    UBLOCK_MENDE_KIKAKUI = 235, /*[1E800]*/
     1487    /** @stable ICU 54 */
     1488    UBLOCK_MODI = 236, /*[11600]*/
     1489    /** @stable ICU 54 */
     1490    UBLOCK_MRO = 237, /*[16A40]*/
     1491    /** @stable ICU 54 */
     1492    UBLOCK_MYANMAR_EXTENDED_B = 238, /*[A9E0]*/
     1493    /** @stable ICU 54 */
     1494    UBLOCK_NABATAEAN = 239, /*[10880]*/
     1495    /** @stable ICU 54 */
     1496    UBLOCK_OLD_NORTH_ARABIAN = 240, /*[10A80]*/
     1497    /** @stable ICU 54 */
     1498    UBLOCK_OLD_PERMIC = 241, /*[10350]*/
     1499    /** @stable ICU 54 */
     1500    UBLOCK_ORNAMENTAL_DINGBATS = 242, /*[1F650]*/
     1501    /** @stable ICU 54 */
     1502    UBLOCK_PAHAWH_HMONG = 243, /*[16B00]*/
     1503    /** @stable ICU 54 */
     1504    UBLOCK_PALMYRENE = 244, /*[10860]*/
     1505    /** @stable ICU 54 */
     1506    UBLOCK_PAU_CIN_HAU = 245, /*[11AC0]*/
     1507    /** @stable ICU 54 */
     1508    UBLOCK_PSALTER_PAHLAVI = 246, /*[10B80]*/
     1509    /** @stable ICU 54 */
     1510    UBLOCK_SHORTHAND_FORMAT_CONTROLS = 247, /*[1BCA0]*/
     1511    /** @stable ICU 54 */
     1512    UBLOCK_SIDDHAM = 248, /*[11580]*/
     1513    /** @stable ICU 54 */
     1514    UBLOCK_SINHALA_ARCHAIC_NUMBERS = 249, /*[111E0]*/
     1515    /** @stable ICU 54 */
     1516    UBLOCK_SUPPLEMENTAL_ARROWS_C = 250, /*[1F800]*/
     1517    /** @stable ICU 54 */
     1518    UBLOCK_TIRHUTA = 251, /*[11480]*/
     1519    /** @stable ICU 54 */
     1520    UBLOCK_WARANG_CITI = 252, /*[118A0]*/
     1521
     1522    /** @stable ICU 2.0 */
     1523    UBLOCK_COUNT = 253,
    14571524
    14581525    /** @stable ICU 2.0 */
     
    16631730    U_JG_NYA,       /**< @stable ICU 4.4 */
    16641731    U_JG_ROHINGYA_YEH,  /**< @stable ICU 49 */
     1732    U_JG_MANICHAEAN_ALEPH,  /**< @stable ICU 54 */
     1733    U_JG_MANICHAEAN_AYIN,  /**< @stable ICU 54 */
     1734    U_JG_MANICHAEAN_BETH,  /**< @stable ICU 54 */
     1735    U_JG_MANICHAEAN_DALETH,  /**< @stable ICU 54 */
     1736    U_JG_MANICHAEAN_DHAMEDH,  /**< @stable ICU 54 */
     1737    U_JG_MANICHAEAN_FIVE,  /**< @stable ICU 54 */
     1738    U_JG_MANICHAEAN_GIMEL,  /**< @stable ICU 54 */
     1739    U_JG_MANICHAEAN_HETH,  /**< @stable ICU 54 */
     1740    U_JG_MANICHAEAN_HUNDRED,  /**< @stable ICU 54 */
     1741    U_JG_MANICHAEAN_KAPH,  /**< @stable ICU 54 */
     1742    U_JG_MANICHAEAN_LAMEDH,  /**< @stable ICU 54 */
     1743    U_JG_MANICHAEAN_MEM,  /**< @stable ICU 54 */
     1744    U_JG_MANICHAEAN_NUN,  /**< @stable ICU 54 */
     1745    U_JG_MANICHAEAN_ONE,  /**< @stable ICU 54 */
     1746    U_JG_MANICHAEAN_PE,  /**< @stable ICU 54 */
     1747    U_JG_MANICHAEAN_QOPH,  /**< @stable ICU 54 */
     1748    U_JG_MANICHAEAN_RESH,  /**< @stable ICU 54 */
     1749    U_JG_MANICHAEAN_SADHE,  /**< @stable ICU 54 */
     1750    U_JG_MANICHAEAN_SAMEKH,  /**< @stable ICU 54 */
     1751    U_JG_MANICHAEAN_TAW,  /**< @stable ICU 54 */
     1752    U_JG_MANICHAEAN_TEN,  /**< @stable ICU 54 */
     1753    U_JG_MANICHAEAN_TETH,  /**< @stable ICU 54 */
     1754    U_JG_MANICHAEAN_THAMEDH,  /**< @stable ICU 54 */
     1755    U_JG_MANICHAEAN_TWENTY,  /**< @stable ICU 54 */
     1756    U_JG_MANICHAEAN_WAW,  /**< @stable ICU 54 */
     1757    U_JG_MANICHAEAN_YODH,  /**< @stable ICU 54 */
     1758    U_JG_MANICHAEAN_ZAYIN,  /**< @stable ICU 54 */
     1759    U_JG_STRAIGHT_WAW,  /**< @stable ICU 54 */
    16651760    U_JG_COUNT
    16661761} UJoiningGroup;
     
    27412836 * @deprecated ICU 49
    27422837 */
    2743 U_STABLE int32_t U_EXPORT2
     2838U_DEPRECATED int32_t U_EXPORT2
    27442839u_getISOComment(UChar32 c,
    27452840                char *dest, int32_t destCapacity,
  • trunk/Source/JavaScriptCore/icu/unicode/ucnv.h

    r196492 r215722  
    11/*
    22**********************************************************************
    3 *   Copyright (C) 1999-2013, International Business Machines
     3*   Copyright (C) 1999-2014, International Business Machines
    44*   Corporation and others.  All Rights Reserved.
    55**********************************************************************
     
    1919/**
    2020 * \file
    21  * \brief C API: Character conversion 
     21 * \brief C API: Character conversion
    2222 *
    2323 * <h2>Character Conversion C API</h2>
     
    4040 * many other callback actions that can be used instead of a character substitution.</p>
    4141 *
    42  * <p>More information about this API can be found in our 
     42 * <p>More information about this API can be found in our
    4343 * <a href="http://icu-project.org/userguide/conversion.html">User's
    4444 * Guide</a>.</p>
     
    117117    UCNV_LMBCS_1 = 11,
    118118    /** @stable ICU 2.0 */
    119     UCNV_LMBCS_2, 
     119    UCNV_LMBCS_2,
    120120    /** @stable ICU 2.0 */
    121121    UCNV_LMBCS_3,
     
    238238
    239239/**
    240  * String version of UCNV_OPTION_SEP_CHAR. 
     240 * String version of UCNV_OPTION_SEP_CHAR.
    241241 * @see ucnv_open
    242242 * @stable ICU 2.0
     
    252252
    253253/**
    254  * String version of UCNV_VALUE_SEP_CHAR. 
     254 * String version of UCNV_VALUE_SEP_CHAR.
    255255 * @see ucnv_open
    256256 * @stable ICU 2.0
     
    270270/**
    271271 * Converter option for specifying a version selector (0..9) for some converters.
    272  * For example, 
     272 * For example,
    273273 * \code
    274274 *   ucnv_open("UTF-7,version=1", &errorCode);
     
    362362 * @stable ICU 2.0
    363363 */
    364 U_STABLE UConverter* U_EXPORT2 
     364U_STABLE UConverter* U_EXPORT2
    365365ucnv_open(const char *converterName, UErrorCode *err);
    366366
    367367
    368368/**
    369  * Creates a Unicode converter with the names specified as unicode string. 
     369 * Creates a Unicode converter with the names specified as unicode string.
    370370 * The name should be limited to the ASCII-7 alphanumerics range.
    371371 * The actual name will be resolved with the alias file
     
    374374 * E.g., the names "UTF8", "utf-8", "u*T@f08" and "Utf 8" are all equivalent.
    375375 * (See also ucnv_compareNames().)
    376  * If <TT>NULL</TT> is passed for the converter name, it will create 
     376 * If <TT>NULL</TT> is passed for the converter name, it will create
    377377 * one with the ucnv_getDefaultName() return value.
    378378 * If the alias is ambiguous, then the preferred converter is used
     
    380380 *
    381381 * <p>See ucnv_open for the complete details</p>
    382  * @param name Name of the UConverter table in a zero terminated 
     382 * @param name Name of the UConverter table in a zero terminated
    383383 *        Unicode string
    384  * @param err outgoing error status <TT>U_MEMORY_ALLOCATION_ERROR, 
     384 * @param err outgoing error status <TT>U_MEMORY_ALLOCATION_ERROR,
    385385 *        U_FILE_ACCESS_ERROR</TT>
    386  * @return the created Unicode converter object, or <TT>NULL</TT> if an 
     386 * @return the created Unicode converter object, or <TT>NULL</TT> if an
    387387 *        error occured
    388388 * @see ucnv_open
     
    392392 * @stable ICU 2.0
    393393 */
    394 U_STABLE UConverter* U_EXPORT2 
     394U_STABLE UConverter* U_EXPORT2
    395395ucnv_openU(const UChar *name,
    396396           UErrorCode *err);
     
    467467/**
    468468 * <p>Creates a UConverter object specified from a packageName and a converterName.</p>
    469  * 
     469 *
    470470 * <p>The packageName and converterName must point to an ICU udata object, as defined by
    471471 *   <code> udata_open( packageName, "cnv", converterName, err) </code> or equivalent.
    472472 * Typically, packageName will refer to a (.dat) file, or to a package registered with
    473473 * udata_setAppData(). Using a full file or directory pathname for packageName is deprecated.</p>
    474  * 
     474 *
    475475 * <p>The name will NOT be looked up in the alias mechanism, nor will the converter be
    476476 * stored in the converter cache or the alias table. The only way to open further converters
    477  * is call this function multiple times, or use the ucnv_safeClone() function to clone a 
     477 * is call this function multiple times, or use the ucnv_safeClone() function to clone a
    478478 * 'master' converter.</p>
    479479 *
    480480 * <p>A future version of ICU may add alias table lookups and/or caching
    481481 * to this function.</p>
    482  * 
     482 *
    483483 * <p>Example Use:
    484484 *      <code>cnv = ucnv_openPackage("myapp", "myconverter", &err);</code>
     
    495495 * @stable ICU 2.2
    496496 */
    497 U_STABLE UConverter* U_EXPORT2 
     497U_STABLE UConverter* U_EXPORT2
    498498ucnv_openPackage(const char *packageName, const char *converterName, UErrorCode *err);
    499499
     
    523523 * @param cnv converter to be cloned
    524524 * @param stackBuffer <em>Deprecated functionality as of ICU 52, use NULL.</em><br>
    525  *  user allocated space for the new clone. If NULL new memory will be allocated. 
     525 *  user allocated space for the new clone. If NULL new memory will be allocated.
    526526 *  If buffer is not large enough, new memory will be allocated.
    527527 *  Clients can use the U_CNV_SAFECLONE_BUFFERSIZE. This will probably be enough to avoid memory allocations.
     
    537537 * @stable ICU 2.0
    538538 */
    539 U_STABLE UConverter * U_EXPORT2 
    540 ucnv_safeClone(const UConverter *cnv, 
     539U_STABLE UConverter * U_EXPORT2
     540ucnv_safeClone(const UConverter *cnv,
    541541               void             *stackBuffer,
    542                int32_t          *pBufferSize, 
     542               int32_t          *pBufferSize,
    543543               UErrorCode       *status);
    544544
     
    596596 * @param converter the Unicode converter
    597597 * @param subChars the subsitution characters
    598  * @param len on input the capacity of subChars, on output the number 
     598 * @param len on input the capacity of subChars, on output the number
    599599 * of bytes copied to it
    600600 * @param  err the outgoing error status code.
     
    694694 * @param converter the Unicode converter
    695695 * @param errUChars the UChars which were in error
    696  * @param len on input the capacity of errUChars, on output the number of 
     696 * @param len on input the capacity of errUChars, on output the number of
    697697 *  UChars which were copied to it
    698698 * @param err the error status code.
     
    725725 * @stable ICU 2.0
    726726 */
    727 U_STABLE void U_EXPORT2 
     727U_STABLE void U_EXPORT2
    728728ucnv_resetToUnicode(UConverter *converter);
    729729
     
    736736 * @stable ICU 2.0
    737737 */
    738 U_STABLE void U_EXPORT2 
     738U_STABLE void U_EXPORT2
    739739ucnv_resetFromUnicode(UConverter *converter);
    740740
     
    780780 *
    781781 * @param converter The Unicode converter.
    782  * @return The maximum number of bytes per UChar that are output by ucnv_fromUnicode(),
    783  *         to be used together with UCNV_GET_MAX_BYTES_FOR_STRING for buffer allocation.
     782 * @return The maximum number of bytes per UChar (16 bit code unit)
     783 *    that are output by ucnv_fromUnicode(),
     784 *    to be used together with UCNV_GET_MAX_BYTES_FOR_STRING
     785 *    for buffer allocation.
    784786 *
    785787 * @see UCNV_GET_MAX_BYTES_FOR_STRING
     
    813815
    814816/**
    815  * Returns the minimum byte length for characters in this codepage.
     817 * Returns the minimum byte length (per codepoint) for characters in this codepage.
    816818 * This is usually either 1 or 2.
    817819 * @param converter the Unicode converter
    818  * @return the minimum number of bytes allowed by this particular converter
     820 * @return the minimum number of bytes per codepoint allowed by this particular converter
    819821 * @see ucnv_getMaxCharSize
    820822 * @stable ICU 2.0
     
    824826
    825827/**
    826  * Returns the display name of the converter passed in based on the Locale 
     828 * Returns the display name of the converter passed in based on the Locale
    827829 * passed in. If the locale contains no display name, the internal ASCII
    828830 * name will be filled in.
     
    846848/**
    847849 * Gets the internal, canonical name of the converter (zero-terminated).
    848  * The lifetime of the returned string will be that of the converter 
     850 * The lifetime of the returned string will be that of the converter
    849851 * passed to this function.
    850852 * @param converter the Unicode converter
     
    854856 * @stable ICU 2.0
    855857 */
    856 U_STABLE const char * U_EXPORT2 
     858U_STABLE const char * U_EXPORT2
    857859ucnv_getName(const UConverter *converter, UErrorCode *err);
    858860
     
    885887
    886888/**
    887  * Gets a codepage platform associated with the converter. Currently, 
     889 * Gets a codepage platform associated with the converter. Currently,
    888890 * only <TT>UCNV_IBM</TT> will be returned.
    889  * Does not test if the converter is <TT>NULL</TT> or if converter's data 
    890  * table is <TT>NULL</TT>. 
     891 * Does not test if the converter is <TT>NULL</TT> or if converter's data
     892 * table is <TT>NULL</TT>.
    891893 * @param converter the Unicode converter
    892894 * @param err the error status code.
     
    900902/**
    901903 * Gets the type of the converter
    902  * e.g. SBCS, MBCS, DBCS, UTF8, UTF16_BE, UTF16_LE, ISO_2022, 
     904 * e.g. SBCS, MBCS, DBCS, UTF8, UTF16_BE, UTF16_LE, ISO_2022,
    903905 * EBCDIC_STATEFUL, LATIN_1
    904906 * @param converter a valid, opened converter
     
    912914 * Gets the "starter" (lead) bytes for converters of type MBCS.
    913915 * Will fill in an <TT>U_ILLEGAL_ARGUMENT_ERROR</TT> if converter passed in
    914  * is not MBCS. Fills in an array of type UBool, with the value of the byte 
     916 * is not MBCS. Fills in an array of type UBool, with the value of the byte
    915917 * as offset to the array. For example, if (starters[0x20] == TRUE) at return,
    916918 * it means that the byte 0x20 is a starter byte in this converter.
    917919 * Context pointers are always owned by the caller.
    918  * 
     920 *
    919921 * @param converter a valid, opened converter of type MBCS
    920922 * @param starters an array of size 256 to be filled in
    921  * @param err error status, <TT>U_ILLEGAL_ARGUMENT_ERROR</TT> if the 
     923 * @param err error status, <TT>U_ILLEGAL_ARGUMENT_ERROR</TT> if the
    922924 * converter is not a type which can return starters.
    923925 * @see ucnv_getType
     
    925927 */
    926928U_STABLE void U_EXPORT2
    927 ucnv_getStarters(const UConverter* converter, 
     929ucnv_getStarters(const UConverter* converter,
    928930                 UBool starters[256],
    929931                 UErrorCode* err);
     
    9981000/**
    9991001 * Gets the current calback function used by the converter when an illegal
    1000  *  or invalid codepage sequence is found. 
     1002 *  or invalid codepage sequence is found.
    10011003 * Context pointers are always owned by the caller.
    10021004 *
     
    10131015
    10141016/**
    1015  * Gets the current callback function used by the converter when illegal 
     1017 * Gets the current callback function used by the converter when illegal
    10161018 * or invalid Unicode sequence is found.
    10171019 * Context pointers are always owned by the caller.
     
    10791081 * stream of data in buffer-sized chunks, where the entire source and
    10801082 * target does not fit in available buffers.
    1081  * 
    1082  * The source pointer is an in/out parameter. It starts out pointing where the 
    1083  * conversion is to begin, and ends up pointing after the last UChar consumed. 
    1084  * 
     1083 *
     1084 * The source pointer is an in/out parameter. It starts out pointing where the
     1085 * conversion is to begin, and ends up pointing after the last UChar consumed.
     1086 *
    10851087 * Target similarly starts out pointer at the first available byte in the output
    10861088 * buffer, and ends up pointing after the last byte written to the output.
    1087  * 
    1088  * The converter always attempts to consume the entire source buffer, unless 
     1089 *
     1090 * The converter always attempts to consume the entire source buffer, unless
    10891091 * (1.) the target buffer is full, or (2.) a failing error is returned from the
    10901092 * current callback function.  When a successful error status has been
     
    10921094 *  consumed. At that point, the caller should reset the source and
    10931095 *  sourceLimit pointers to point to the next chunk.
    1094  * 
     1096 *
    10951097 * At the end of the stream (flush==TRUE), the input is completely consumed
    10961098 * when *source==sourceLimit and no error code is set.
     
    10981100 * (This means that a converter need not be reset explicitly between data
    10991101 * streams if it finishes the previous stream without errors.)
    1100  * 
     1102 *
    11011103 * This is a <I>stateful</I> conversion. Additionally, even when all source data has
    11021104 * been consumed, some data may be in the converters' internal state.
     
    11111113 *  to <TT>target</TT>.
    11121114 * @param targetLimit the pointer just after last of the <TT>target</TT> buffer
    1113  * @param source I/O parameter, pointer to pointer to the source Unicode character buffer. 
     1115 * @param source I/O parameter, pointer to pointer to the source Unicode character buffer.
    11141116 * @param sourceLimit the pointer just after the last of the source buffer
    11151117 * @param offsets if NULL is passed, nothing will happen to it, otherwise it needs to have the same number
     
    11171119 * e.g: <TT>offsets[3]</TT> is equal to 6, it means that the <TT>target[3]</TT> was a result of transcoding <TT>source[6]</TT>
    11181120 * For output data carried across calls, and other data without a specific source character
    1119  * (such as from escape sequences or callbacks)  -1 will be placed for offsets. 
     1121 * (such as from escape sequences or callbacks)  -1 will be placed for offsets.
    11201122 * @param flush set to <TT>TRUE</TT> if the current source buffer is the last available
    11211123 * chunk of the source, <TT>FALSE</TT> otherwise. Note that if a failing status is returned,
     
    11241126 * @param err the error status.  <TT>U_ILLEGAL_ARGUMENT_ERROR</TT> will be set if the
    11251127 * converter is <TT>NULL</TT>.
    1126  * <code>U_BUFFER_OVERFLOW_ERROR</code> will be set if the target is full and there is 
     1128 * <code>U_BUFFER_OVERFLOW_ERROR</code> will be set if the target is full and there is
    11271129 * still data to be written to the target.
    11281130 * @see ucnv_fromUChars
     
    11321134 * @stable ICU 2.0
    11331135 */
    1134 U_STABLE void U_EXPORT2 
     1136U_STABLE void U_EXPORT2
    11351137ucnv_fromUnicode (UConverter * converter,
    11361138                  char **target,
     
    11471149 * stream of data in buffer-sized chunks, where the entire source and
    11481150 * target does not fit in available buffers.
    1149  * 
    1150  * The source pointer is an in/out parameter. It starts out pointing where the 
    1151  * conversion is to begin, and ends up pointing after the last byte of source consumed. 
    1152  * 
     1151 *
     1152 * The source pointer is an in/out parameter. It starts out pointing where the
     1153 * conversion is to begin, and ends up pointing after the last byte of source consumed.
     1154 *
    11531155 * Target similarly starts out pointer at the first available UChar in the output
    1154  * buffer, and ends up pointing after the last UChar written to the output. 
     1156 * buffer, and ends up pointing after the last UChar written to the output.
    11551157 * It does NOT necessarily keep UChar sequences together.
    1156  * 
    1157  * The converter always attempts to consume the entire source buffer, unless 
     1158 *
     1159 * The converter always attempts to consume the entire source buffer, unless
    11581160 * (1.) the target buffer is full, or (2.) a failing error is returned from the
    11591161 * current callback function.  When a successful error status has been
     
    11671169 * (This means that a converter need not be reset explicitly between data
    11681170 * streams if it finishes the previous stream without errors.)
    1169  * 
     1171 *
    11701172 * This is a <I>stateful</I> conversion. Additionally, even when all source data has
    11711173 * been consumed, some data may be in the converters' internal state.
     
    11791181 *  UChars into. Output : points to after the last UChar copied.
    11801182 * @param targetLimit the pointer just after the end of the <TT>target</TT> buffer
    1181  * @param source I/O parameter, pointer to pointer to the source codepage buffer. 
     1183 * @param source I/O parameter, pointer to pointer to the source codepage buffer.
    11821184 * @param sourceLimit the pointer to the byte after the end of the source buffer
    11831185 * @param offsets if NULL is passed, nothing will happen to it, otherwise it needs to have the same number
     
    11851187 * e.g: <TT>offsets[3]</TT> is equal to 6, it means that the <TT>target[3]</TT> was a result of transcoding <TT>source[6]</TT>
    11861188 * For output data carried across calls, and other data without a specific source character
    1187  * (such as from escape sequences or callbacks)  -1 will be placed for offsets. 
     1189 * (such as from escape sequences or callbacks)  -1 will be placed for offsets.
    11881190 * @param flush set to <TT>TRUE</TT> if the current source buffer is the last available
    11891191 * chunk of the source, <TT>FALSE</TT> otherwise. Note that if a failing status is returned,
     
    11921194 * @param err the error status.  <TT>U_ILLEGAL_ARGUMENT_ERROR</TT> will be set if the
    11931195 * converter is <TT>NULL</TT>.
    1194  * <code>U_BUFFER_OVERFLOW_ERROR</code> will be set if the target is full and there is 
    1195  * still data to be written to the target. 
     1196 * <code>U_BUFFER_OVERFLOW_ERROR</code> will be set if the target is full and there is
     1197 * still data to be written to the target.
    11961198 * @see ucnv_fromUChars
    11971199 * @see ucnv_convert
     
    12011203 * @stable ICU 2.0
    12021204 */
    1203 U_STABLE void U_EXPORT2 
     1205U_STABLE void U_EXPORT2
    12041206ucnv_toUnicode(UConverter *converter,
    12051207               UChar **target,
     
    13321334 * @param sourceLimit points to the end of the input buffer
    13331335 * @param err fills in error status (see ucnv_toUnicode)
    1334  * <code>U_INDEX_OUTOFBOUNDS_ERROR</code> will be set if the input 
    1335  * is empty or does not convert to any output (e.g.: pure state-change 
     1336 * <code>U_INDEX_OUTOFBOUNDS_ERROR</code> will be set if the input
     1337 * is empty or does not convert to any output (e.g.: pure state-change
    13361338 * codes SI/SO, escape sequences for ISO 2022,
    13371339 * or if the callback did not output anything, ...).
     
    14371439 *                    TRUE, TRUE,
    14381440 *                    pErrorCode);
    1439  * 
     1441 *
    14401442 *     myReleaseCachedUTF8Converter(utf8Cnv);
    14411443 *
     
    17251727 * @stable ICU 2.0
    17261728 */
    1727 U_STABLE uint16_t U_EXPORT2 
     1729U_STABLE uint16_t U_EXPORT2
    17281730ucnv_countAliases(const char *alias, UErrorCode *pErrorCode);
    17291731
     
    17401742 * @stable ICU 2.0
    17411743 */
    1742 U_STABLE const char * U_EXPORT2 
     1744U_STABLE const char * U_EXPORT2
    17431745ucnv_getAlias(const char *alias, uint16_t n, UErrorCode *pErrorCode);
    17441746
     
    17561758 * @stable ICU 2.0
    17571759 */
    1758 U_STABLE void U_EXPORT2 
     1760U_STABLE void U_EXPORT2
    17591761ucnv_getAliases(const char *alias, const char **aliases, UErrorCode *pErrorCode);
    17601762
     
    18881890
    18891891/**
    1890  * Fixes the backslash character mismapping.  For example, in SJIS, the backslash 
    1891  * character in the ASCII portion is also used to represent the yen currency sign. 
    1892  * When mapping from Unicode character 0x005C, it's unclear whether to map the 
     1892 * Fixes the backslash character mismapping.  For example, in SJIS, the backslash
     1893 * character in the ASCII portion is also used to represent the yen currency sign.
     1894 * When mapping from Unicode character 0x005C, it's unclear whether to map the
    18931895 * character back to yen or backslash in SJIS.  This function will take the input
    18941896 * buffer and replace all the yen sign characters with backslash.  This is necessary
     
    19111913 * character or not.
    19121914 * @param cnv the converter to be tested
    1913  * @return TRUE if the converter contains ambiguous mapping of the same 
     1915 * @return TRUE if the converter contains ambiguous mapping of the same
    19141916 * character, FALSE otherwise.
    19151917 * @stable ICU 2.0
     
    19281930 *
    19291931 * @param cnv The converter to set the fallback mapping usage on.
    1930  * @param usesFallback TRUE if the user wants the converter to take advantage of the fallback 
     1932 * @param usesFallback TRUE if the user wants the converter to take advantage of the fallback
    19311933 * mapping, FALSE otherwise.
    19321934 * @stable ICU 2.0
    19331935 * @see ucnv_usesFallback
    19341936 */
    1935 U_STABLE void U_EXPORT2 
     1937U_STABLE void U_EXPORT2
    19361938ucnv_setFallback(UConverter *cnv, UBool usesFallback);
    19371939
     
    19451947 * @see ucnv_setFallback
    19461948 */
    1947 U_STABLE UBool U_EXPORT2 
     1949U_STABLE UBool U_EXPORT2
    19481950ucnv_usesFallback(const UConverter *cnv);
    19491951
     
    19691971 * @param source            The source string in which the signature should be detected.
    19701972 * @param sourceLength      Length of the input string, or -1 if terminated with a NUL byte.
    1971  * @param signatureLength   A pointer to int32_t to receive the number of bytes that make up the signature 
     1973 * @param signatureLength   A pointer to int32_t to receive the number of bytes that make up the signature
    19721974 *                          of the detected UTF. 0 if not detected.
    19731975 *                          Can be a NULL pointer.
    19741976 * @param pErrorCode        ICU error code in/out parameter.
    19751977 *                          Must fulfill U_SUCCESS before the function call.
    1976  * @return The name of the encoding detected. NULL if encoding is not detected. 
     1978 * @return The name of the encoding detected. NULL if encoding is not detected.
    19771979 * @stable ICU 2.4
    19781980 */
     
    19841986
    19851987/**
    1986  * Returns the number of UChars held in the converter's internal state 
    1987  * because more input is needed for completing the conversion. This function is 
     1988 * Returns the number of UChars held in the converter's internal state
     1989 * because more input is needed for completing the conversion. This function is
    19881990 * useful for mapping semantics of ICU's converter interface to those of iconv,
    19891991 * and this information is not needed for normal conversion.
     
    19992001/**
    20002002 * Returns the number of chars held in the converter's internal state
    2001  * because more input is needed for completing the conversion. This function is 
     2003 * because more input is needed for completing the conversion. This function is
    20022004 * useful for mapping semantics of ICU's converter interface to those of iconv,
    20032005 * and this information is not needed for normal conversion.
  • trunk/Source/JavaScriptCore/icu/unicode/ucol.h

    r196492 r215722  
    11/*
    22*******************************************************************************
    3 * Copyright (c) 1996-2013, International Business Machines Corporation and others.
     3* Copyright (c) 1996-2015, International Business Machines Corporation and others.
    44* All Rights Reserved.
    55*******************************************************************************
     
    2929 * string comparison. You use this service to build
    3030 * searching and sorting routines for natural language text.
    31  * <em>Important: </em>The ICU collation service has been reimplemented
    32  * in order to achieve better performance and UCA compliance.
    33  * For details, see the
    34  * <a href="http://source.icu-project.org/repos/icu/icuhtml/trunk/design/collation/ICU_collation_design.htm">
    35  * collation design document</a>.
    3631 * <p>
    3732 * For more information about the collation service see
    38  * <a href="http://icu-project.org/userguide/Collate_Intro.html">the users guide</a>.
     33 * <a href="http://userguide.icu-project.org/collation">the User Guide</a>.
    3934 * <p>
    4035 * Collation service provides correct sorting orders for most locales supported in ICU.
    4136 * If specific data for a locale is not available, the orders eventually falls back
    42  * to the <a href="http://www.unicode.org/unicode/reports/tr10/">UCA sort order</a>.
     37 * to the <a href="http://www.unicode.org/reports/tr35/tr35-collation.html#Root_Collation">CLDR root sort order</a>.
    4338 * <p>
    4439 * Sort ordering may be customized by providing your own set of rules. For more on
    45  * this subject see the
    46  * <a href="http://icu-project.org/userguide/Collate_Customization.html">
    47  * Collation customization</a> section of the users guide.
     40 * this subject see the <a href="http://userguide.icu-project.org/collation/customization">
     41 * Collation Customization</a> section of the User Guide.
    4842 * <p>
    4943 * @see         UCollationResult
     
    292286     /** The strength attribute. Can be either UCOL_PRIMARY, UCOL_SECONDARY,
    293287      * UCOL_TERTIARY, UCOL_QUATERNARY or UCOL_IDENTICAL. The usual strength
    294       * for most locales (except Japanese) is tertiary. Quaternary strength
     288      * for most locales (except Japanese) is tertiary.
     289      *
     290      * Quaternary strength
    295291      * is useful when combined with shifted setting for alternate handling
    296       * attribute and for JIS x 4061 collation, when it is used to distinguish
    297       * between Katakana  and Hiragana (this is achieved by setting the
    298       * UCOL_HIRAGANA_QUATERNARY mode to on. Otherwise, quaternary level
    299       * is affected only by the number of non ignorable code points in
    300       * the string. Identical strength is rarely useful, as it amounts
     292      * attribute and for JIS X 4061 collation, when it is used to distinguish
     293      * between Katakana and Hiragana.
     294      * Otherwise, quaternary level
     295      * is affected only by the number of non-ignorable code points in
     296      * the string.
     297      *
     298      * Identical strength is rarely useful, as it amounts
    301299      * to codepoints of the NFD form of the string.
    302300      * @stable ICU 2.0
     
    308306      * sort order.
    309307      *
    310       * This attribute is an implementation detail of the CLDR Japanese tailoring.
    311       * The implementation might change to use a different mechanism
     308      * This attribute was an implementation detail of the CLDR Japanese tailoring.
     309      * Since ICU 50, this attribute is not settable any more via API functions.
     310      * Since CLDR 25/ICU 53, explicit quaternary relations are used
    312311      * to achieve the same Japanese sort order.
    313       * Since ICU 50, this attribute is not settable any more via API functions.
    314       * @deprecated ICU 50 Implementation detail, cannot be set via API, might be removed from implementation.
     312      *
     313      * @deprecated ICU 50 Implementation detail, cannot be set via API, was removed from implementation.
    315314      */
    316315     UCOL_HIRAGANA_QUATERNARY_MODE = UCOL_STRENGTH + 1,
    317316#endif  /* U_HIDE_DEPRECATED_API */
    318      /** When turned on, this attribute generates a collation key
    319       * for the numeric value of substrings of digits.
     317     /**
     318      * When turned on, this attribute makes
     319      * substrings of digits sort according to their numeric values.
     320      *
    320321      * This is a way to get '100' to sort AFTER '2'. Note that the longest
    321       * digit substring that can be treated as a single collation element is
     322      * digit substring that can be treated as a single unit is
    322323      * 254 digits (not counting leading zeros). If a digit substring is
    323324      * longer than that, the digits beyond the limit will be treated as a
    324       * separate digit substring associated with a separate collation element.
     325      * separate digit substring.
     326      *
     327      * A "digit" in this sense is a code point with General_Category=Nd,
     328      * which does not include circled numbers, roman numerals, etc.
     329      * Only a contiguous digit substring is considered, that is,
     330      * non-negative integers without separators.
     331      * There is no support for plus/minus signs, decimals, exponents, etc.
     332      *
    325333      * @stable ICU 2.8
    326334      */
     
    355363/**
    356364 * Open a UCollator for comparing strings.
     365 *
     366 * For some languages, multiple collation types are available;
     367 * for example, "de@collation=phonebook".
     368 * Starting with ICU 54, collation attributes can be specified via locale keywords as well,
     369 * in the old locale extension syntax ("el@colCaseFirst=upper")
     370 * or in language tag syntax ("el-u-kf-upper").
     371 * See <a href="http://userguide.icu-project.org/collation/api">User Guide: Collation API</a>.
     372 *
    357373 * The UCollator pointer is used in all the calls to the Collation
    358374 * service. After finished, collator must be disposed of by calling
     
    362378 *            if NULL is passed for the locale, the default locale
    363379 *            collation rules will be used. If empty string ("") or
    364  *            "root" are passed, UCA rules will be used.
    365  * @param status A pointer to an UErrorCode to receive any errors
     380 *            "root" are passed, the root collator will be returned.
     381 * @param status A pointer to a UErrorCode to receive any errors
    366382 * @return A pointer to a UCollator, or 0 if an error occurred.
    367383 * @see ucol_openRules
     
    374390
    375391/**
    376  * Produce an UCollator instance according to the rules supplied.
     392 * Produce a UCollator instance according to the rules supplied.
    377393 * The rules are used to change the default ordering, defined in the
    378394 * UCA in a process called tailoring. The resulting UCollator pointer
     
    390406 *                    occurred during parsing. This argument can currently be set
    391407 *                    to NULL, but at users own risk. Please provide a real structure.
    392  * @param status A pointer to an UErrorCode to receive any errors
     408 * @param status A pointer to a UErrorCode to receive any errors
    393409 * @return A pointer to a UCollator. It is not guaranteed that NULL be returned in case
    394410 *         of error - please use status argument to check for errors.
     
    406422                UErrorCode         *status);
    407423
     424#ifndef U_HIDE_DEPRECATED_API
    408425/**
    409426 * Open a collator defined by a short form string.
    410427 * The structure and the syntax of the string is defined in the "Naming collators"
    411428 * section of the users guide:
    412  * http://icu-project.org/userguide/Collate_Concepts.html#Naming_Collators
     429 * http://userguide.icu-project.org/collation/concepts#TOC-Collator-naming-scheme
    413430 * Attributes are overriden by the subsequent attributes. So, for "S2_S3", final
    414431 * strength will be 3. 3066bis locale overrides individual locale parts.
     
    437454 * @see ucol_getShortDefinitionString
    438455 * @see ucol_normalizeShortDefinitionString
    439  * @stable ICU 3.0
    440  *
    441  */
    442 U_STABLE UCollator* U_EXPORT2
     456 * @deprecated ICU 54 Use ucol_open() with language tag collation keywords instead.
     457 */
     458U_DEPRECATED UCollator* U_EXPORT2
    443459ucol_openFromShortString( const char *definition,
    444460                          UBool forceDefaults,
    445461                          UParseError *parseError,
    446462                          UErrorCode *status);
     463#endif  /* U_HIDE_DEPRECATED_API */
    447464
    448465#ifndef U_HIDE_DEPRECATED_API
    449466/**
    450467 * Get a set containing the contractions defined by the collator. The set includes
    451  * both the UCA contractions and the contractions defined by the collator. This set
     468 * both the root collator's contractions and the contractions defined by the collator. This set
    452469 * will contain only strings. If a tailoring explicitly suppresses contractions from
    453  * the UCA (like Russian), removed contractions will not be in the resulting set.
     470 * the root collator (like Russian), removed contractions will not be in the resulting set.
    454471 * @param coll collator
    455472 * @param conts the set to hold the result. It gets emptied before
     
    468485/**
    469486 * Get a set containing the expansions defined by the collator. The set includes
    470  * both the UCA expansions and the expansions defined by the tailoring
     487 * both the root collator's expansions and the expansions defined by the tailoring
    471488 * @param coll collator
    472489 * @param contractions if not NULL, the set to hold the contractions
     
    546563* @param target The target UTF-8 string.
    547564* @param targetLength The length of target, or -1 if null-terminated.
    548 * @param status A pointer to an UErrorCode to receive any errors
     565* @param status A pointer to a UErrorCode to receive any errors
    549566* @return The result of comparing the strings; one of UCOL_EQUAL,
    550567* UCOL_GREATER, UCOL_LESS
     
    628645 * @return The result of comparing the strings; one of UCOL_EQUAL,
    629646 * UCOL_GREATER, UCOL_LESS
    630  * @param status A pointer to an UErrorCode to receive any errors
     647 * @param status A pointer to a UErrorCode to receive any errors
    631648 * @see ucol_strcoll
    632649 * @stable ICU 2.6
     
    669686 * @param dest The array to fill with the script ordering.
    670687 * @param destCapacity The length of dest. If it is 0, then dest may be NULL and the function
    671  * will only return the length of the result without writing any of the result string (pre-flighting).
     688 * will only return the length of the result without writing any codes (pre-flighting).
    672689 * @param pErrorCode Must be a valid pointer to an error code value, which must not indicate a
    673690 * failure before the function call.
     
    686703/**
    687704 * Sets the reordering codes for this collator.
    688  * Collation reordering allows scripts and some other defined blocks of characters
    689  * to be moved relative to each other as a block. This reordering is done on top of
     705 * Collation reordering allows scripts and some other groups of characters
     706 * to be moved relative to each other. This reordering is done on top of
    690707 * the DUCET/CLDR standard collation order. Reordering can specify groups to be placed
    691708 * at the start and/or the end of the collation order. These groups are specified using
    692709 * UScript codes and UColReorderCode entries.
     710 *
    693711 * <p>By default, reordering codes specified for the start of the order are placed in the
    694  * order given after a group of "special" non-script blocks. These special groups of characters
     712 * order given after several special non-script blocks. These special groups of characters
    695713 * are space, punctuation, symbol, currency, and digit. These special groups are represented with
    696714 * UColReorderCode entries. Script groups can be intermingled with
    697  * these special non-script blocks if those special blocks are explicitly specified in the reordering.
     715 * these special non-script groups if those special groups are explicitly specified in the reordering.
     716 *
    698717 * <p>The special code OTHERS stands for any script that is not explicitly
    699718 * mentioned in the list of reordering codes given. Anything that is after OTHERS
    700719 * will go at the very end of the reordering in the order given.
     720 *
    701721 * <p>The special reorder code DEFAULT will reset the reordering for this collator
    702722 * to the default for this collator. The default reordering may be the DUCET/CLDR order or may be a reordering that
    703723 * was specified when this collator was created from resource data or from rules. The
    704  * DEFAULT code <b>must</b> be the sole code supplied when it used. If not
    705  * that will result in an U_ILLEGAL_ARGUMENT_ERROR being set.
     724 * DEFAULT code <b>must</b> be the sole code supplied when it is used.
     725 * If not, then U_ILLEGAL_ARGUMENT_ERROR will be set.
     726 *
    706727 * <p>The special reorder code NONE will remove any reordering for this collator.
    707728 * The result of setting no reordering will be to have the DUCET/CLDR ordering used. The
    708  * NONE code <b>must</b> be the sole code supplied when it used.
     729 * NONE code <b>must</b> be the sole code supplied when it is used.
     730 *
    709731 * @param coll The UCollator to set.
    710732 * @param reorderCodes An array of script codes in the new order. This can be NULL if the
     
    728750 * Retrieves the reorder codes that are grouped with the given reorder code. Some reorder
    729751 * codes will be grouped and must reorder together.
     752 * Beginning with ICU 55, scripts only reorder together if they are primary-equal,
     753 * for example Hiragana and Katakana.
     754 *
    730755 * @param reorderCode The reorder code to determine equivalence for.
    731756 * @param dest The array to fill with the script ordering.
    732757 * @param destCapacity The length of dest. If it is 0, then dest may be NULL and the function
    733  * will only return the length of the result without writing any of the result string (pre-flighting).
     758 * will only return the length of the result without writing any codes (pre-flighting).
    734759 * @param pErrorCode Must be a valid pointer to an error code value, which must not indicate
    735760 * a failure before the function call.
     
    754779 * @param result A pointer to a buffer to receive the attribute.
    755780 * @param resultLength The maximum size of result.
    756  * @param status A pointer to an UErrorCode to receive any errors
     781 * @param status A pointer to a UErrorCode to receive any errors
    757782 * @return The total buffer size needed; if greater than resultLength,
    758783 * the output was truncated.
     
    851876
    852877/**
    853  * Return the functionally equivalent locale for the given
    854  * requested locale, with respect to given keyword, for the
    855  * collation service.  If two locales return the same result, then
    856  * collators instantiated for these locales will behave
    857  * equivalently.  The converse is not always true; two collators
     878 * Return the functionally equivalent locale for the specified
     879 * input locale, with respect to given keyword, for the
     880 * collation service. If two different input locale + keyword
     881 * combinations produce the same result locale, then collators
     882 * instantiated for these two different input locales will behave
     883 * equivalently. The converse is not always true; two collators
    858884 * may in fact be equivalent, but return different results, due to
    859  * internal details.  The return result has no other meaning than
     885 * internal details. The return result has no other meaning than
    860886 * that stated above, and implies nothing as to the relationship
    861  * between the two locales.  This is intended for use by
     887 * between the two locales. This is intended for use by
    862888 * applications who wish to cache collators, or otherwise reuse
    863  * collators when possible.  The functional equivalent may change
    864  * over time.  For more information, please see the <a
    865  * href="http://icu-project.org/userguide/locale.html#services">
     889 * collators when possible. The functional equivalent may change
     890 * over time. For more information, please see the <a
     891 * href="http://userguide.icu-project.org/locale#TOC-Locales-and-Services">
    866892 * Locales and Services</a> section of the ICU User Guide.
    867  * @param result fillin for the functionally equivalent locale
     893 * @param result fillin for the functionally equivalent result locale
    868894 * @param resultCapacity capacity of the fillin buffer
    869895 * @param keyword a particular keyword as enumerated by
    870896 * ucol_getKeywords.
    871  * @param locale the requested locale
     897 * @param locale the specified input locale
    872898 * @param isAvailable if non-NULL, pointer to a fillin parameter that
    873  * indicates whether the requested locale was 'available' to the
    874  * collation service. A locale is defined as 'available' if it
     899 * on return indicates whether the specified input locale was 'available'
     900 * to the collation service. A locale is defined as 'available' if it
    875901 * physically exists within the collation locale data.
    876902 * @param status pointer to input-output error code
    877  * @return the actual buffer size needed for the locale.  If greater
     903 * @return the actual buffer size needed for the locale. If greater
    878904 * than resultCapacity, the returned full name will be truncated and
    879905 * an error code will be returned.
     
    897923        int32_t            *length);
    898924
     925#ifndef U_HIDE_DEPRECATED_API
    899926/** Get the short definition string for a collator. This API harvests the collator's
    900927 *  locale and the attribute set and produces a string that can be used for opening
    901  *  a collator with the same properties using the ucol_openFromShortString API.
     928 *  a collator with the same attributes using the ucol_openFromShortString API.
    902929 *  This string will be normalized.
    903930 *  The structure and the syntax of the string is defined in the "Naming collators"
    904931 *  section of the users guide:
    905  *  http://icu-project.org/userguide/Collate_Concepts.html#Naming_Collators
     932 *  http://userguide.icu-project.org/collation/concepts#TOC-Collator-naming-scheme
    906933 *  This API supports preflighting.
    907934 *  @param coll a collator
     
    915942 *  @see ucol_openFromShortString
    916943 *  @see ucol_normalizeShortDefinitionString
    917  *  @stable ICU 3.0
    918  */
    919 U_STABLE int32_t U_EXPORT2
     944 *  @deprecated ICU 54
     945 */
     946U_DEPRECATED int32_t U_EXPORT2
    920947ucol_getShortDefinitionString(const UCollator *coll,
    921948                              const char *locale,
     
    941968 *  @see ucol_getShortDefinitionString
    942969 *
    943  *  @stable ICU 3.0
    944  */
    945 
    946 U_STABLE int32_t U_EXPORT2
     970 *  @deprecated ICU 54
     971 */
     972
     973U_DEPRECATED int32_t U_EXPORT2
    947974ucol_normalizeShortDefinitionString(const char *source,
    948975                                    char *destination,
     
    950977                                    UParseError *parseError,
    951978                                    UErrorCode *status);
     979#endif  /* U_HIDE_DEPRECATED_API */
    952980
    953981
     
    955983 * Get a sort key for a string from a UCollator.
    956984 * Sort keys may be compared using <TT>strcmp</TT>.
     985 *
     986 * Note that sort keys are often less efficient than simply doing comparison. 
     987 * For more details, see the ICU User Guide.
    957988 *
    958989 * Like ICU functions that write to an output buffer, the buffer contents
     
    10971128 * This is useful, for example, for combining sort keys from first and last names
    10981129 * to sort such pairs.
     1130 * See http://www.unicode.org/reports/tr10/#Merging_Sort_Keys
     1131 *
     1132 * The recommended way to achieve "merged" sorting is by
     1133 * concatenating strings with U+FFFE between them.
     1134 * The concatenation has the same sort order as the merged sort keys,
     1135 * but merge(getSortKey(str1), getSortKey(str2)) may differ from getSortKey(str1 + '\uFFFE' + str2).
     1136 * Using strings with U+FFFE may yield shorter sort keys.
     1137 *
     1138 * For details about Sort Key Features see
     1139 * http://userguide.icu-project.org/collation/api#TOC-Sort-Key-Features
     1140 *
    10991141 * It is possible to merge multiple sort keys by consecutively merging
    11001142 * another one with the intermediate result.
     
    11591201ucol_getAttribute(const UCollator *coll, UColAttribute attr, UErrorCode *status);
    11601202
    1161 /** Variable top
    1162  * is a two byte primary value which causes all the codepoints with primary values that
    1163  * are less or equal than the variable top to be shifted when alternate handling is set
    1164  * to UCOL_SHIFTED.
    1165  * Sets the variable top to a collation element value of a string supplied.
    1166  * @param coll collator which variable top needs to be changed
     1203/**
     1204 * Sets the variable top to the top of the specified reordering group.
     1205 * The variable top determines the highest-sorting character
     1206 * which is affected by UCOL_ALTERNATE_HANDLING.
     1207 * If that attribute is set to UCOL_NON_IGNORABLE, then the variable top has no effect.
     1208 * @param coll the collator
     1209 * @param group one of UCOL_REORDER_CODE_SPACE, UCOL_REORDER_CODE_PUNCTUATION,
     1210 *              UCOL_REORDER_CODE_SYMBOL, UCOL_REORDER_CODE_CURRENCY;
     1211 *              or UCOL_REORDER_CODE_DEFAULT to restore the default max variable group
     1212 * @param pErrorCode Standard ICU error code. Its input value must
     1213 *                   pass the U_SUCCESS() test, or else the function returns
     1214 *                   immediately. Check for U_FAILURE() on output or use with
     1215 *                   function chaining. (See User Guide for details.)
     1216 * @see ucol_getMaxVariable
     1217 * @stable ICU 53
     1218 */
     1219U_STABLE void U_EXPORT2
     1220ucol_setMaxVariable(UCollator *coll, UColReorderCode group, UErrorCode *pErrorCode);
     1221
     1222/**
     1223 * Returns the maximum reordering group whose characters are affected by UCOL_ALTERNATE_HANDLING.
     1224 * @param coll the collator
     1225 * @return the maximum variable reordering group.
     1226 * @see ucol_setMaxVariable
     1227 * @stable ICU 53
     1228 */
     1229U_STABLE UColReorderCode U_EXPORT2
     1230ucol_getMaxVariable(const UCollator *coll);
     1231
     1232#ifndef U_HIDE_DEPRECATED_API
     1233/**
     1234 * Sets the variable top to the primary weight of the specified string.
     1235 *
     1236 * Beginning with ICU 53, the variable top is pinned to
     1237 * the top of one of the supported reordering groups,
     1238 * and it must not be beyond the last of those groups.
     1239 * See ucol_setMaxVariable().
     1240 * @param coll the collator
    11671241 * @param varTop one or more (if contraction) UChars to which the variable top should be set
    11681242 * @param len length of variable top string. If -1 it is considered to be zero terminated.
    1169  * @param status error code. If error code is set, the return value is undefined.
    1170  *               Errors set by this function are: <br>
    1171  *    U_CE_NOT_FOUND_ERROR if more than one character was passed and there is no such
    1172  *    a contraction<br>
    1173  *    U_PRIMARY_TOO_LONG_ERROR if the primary for the variable top has more than two bytes
    1174  * @return a 32 bit value containing the value of the variable top in upper 16 bits.
    1175  *         Lower 16 bits are undefined
     1243 * @param status error code. If error code is set, the return value is undefined.
     1244 *               Errors set by this function are:<br>
     1245 *    U_CE_NOT_FOUND_ERROR if more than one character was passed and there is no such contraction<br>
     1246 *    U_ILLEGAL_ARGUMENT_ERROR if the variable top is beyond
     1247 *    the last reordering group supported by ucol_setMaxVariable()
     1248 * @return variable top primary weight
    11761249 * @see ucol_getVariableTop
    11771250 * @see ucol_restoreVariableTop
    1178  * @stable ICU 2.0
    1179  */
    1180 U_STABLE uint32_t U_EXPORT2
     1251 * @deprecated ICU 53 Call ucol_setMaxVariable() instead.
     1252 */
     1253U_DEPRECATED uint32_t U_EXPORT2
    11811254ucol_setVariableTop(UCollator *coll,
    11821255                    const UChar *varTop, int32_t len,
    11831256                    UErrorCode *status);
     1257#endif  /* U_HIDE_DEPRECATED_API */
    11841258
    11851259/**
    11861260 * Gets the variable top value of a Collator.
    1187  * Lower 16 bits are undefined and should be ignored.
    11881261 * @param coll collator which variable top needs to be retrieved
    11891262 * @param status error code (not changed by function). If error code is set,
    11901263 *               the return value is undefined.
    1191  * @return the variable top value of a Collator.
     1264 * @return the variable top primary weight
     1265 * @see ucol_getMaxVariable
    11921266 * @see ucol_setVariableTop
    11931267 * @see ucol_restoreVariableTop
     
    11961270U_STABLE uint32_t U_EXPORT2 ucol_getVariableTop(const UCollator *coll, UErrorCode *status);
    11971271
    1198 /**
    1199  * Sets the variable top to a collation element value supplied. Variable top is
    1200  * set to the upper 16 bits.
    1201  * Lower 16 bits are ignored.
    1202  * @param coll collator which variable top needs to be changed
    1203  * @param varTop CE value, as returned by ucol_setVariableTop or ucol)getVariableTop
    1204  * @param status error code (not changed by function)
     1272/**
     1273 * Sets the variable top to the specified primary weight.
     1274 *
     1275 * Beginning with ICU 53, the variable top is pinned to
     1276 * the top of one of the supported reordering groups,
     1277 * and it must not be beyond the last of those groups.
     1278 * See ucol_setMaxVariable().
     1279 * @param varTop primary weight, as returned by ucol_setVariableTop or ucol_getVariableTop
     1280 * @param status error code
    12051281 * @see ucol_getVariableTop
    12061282 * @see ucol_setVariableTop
    1207  * @stable ICU 2.0
    1208  */
    1209 U_STABLE void U_EXPORT2
     1283 * @deprecated ICU 53 Call ucol_setMaxVariable() instead.
     1284 */
     1285U_DEPRECATED void U_EXPORT2
    12101286ucol_restoreVariableTop(UCollator *coll, const uint32_t varTop, UErrorCode *status);
    12111287
     
    13031379
    13041380/**
    1305  * Get an Unicode set that contains all the characters and sequences tailored in
     1381 * Get a Unicode set that contains all the characters and sequences tailored in
    13061382 * this collator. The result must be disposed of by using uset_close.
    13071383 * @param coll        The UCollator for which we want to get tailored chars
     
    13161392
    13171393#ifndef U_HIDE_INTERNAL_API
    1318 /**
    1319  * Universal attribute getter that returns UCOL_DEFAULT if the value is default
    1320  * @param coll collator which attributes are to be changed
    1321  * @param attr attribute type
    1322  * @return attribute value or UCOL_DEFAULT if the value is default
    1323  * @param status to indicate whether the operation went on smoothly or there were errors
    1324  * @see UColAttribute
    1325  * @see UColAttributeValue
    1326  * @see ucol_setAttribute
    1327  * @internal ICU 3.0
    1328  */
    1329 U_INTERNAL UColAttributeValue  U_EXPORT2
    1330 ucol_getAttributeOrDefault(const UCollator *coll, UColAttribute attr, UErrorCode *status);
    1331 
    1332 /** Check whether two collators are equal. Collators are considered equal if they
    1333  *  will sort strings the same. This means that both the current attributes and the
    1334  *  rules must be equivalent. Currently used for RuleBasedCollator::operator==.
    1335  *  @param source first collator
    1336  *  @param target second collator
    1337  *  @return TRUE or FALSE
    1338  *  @internal ICU 3.0
    1339  */
    1340 U_INTERNAL UBool U_EXPORT2
    1341 ucol_equals(const UCollator *source, const UCollator *target);
    1342 
    13431394/** Calculates the set of unsafe code points, given a collator.
    13441395 *   A character is unsafe if you could append any character and cause the ordering to alter significantly.
     
    13561407                  USet *unsafe,
    13571408                  UErrorCode *status);
    1358 
    1359 /** Reset UCA's static pointers. You don't want to use this, unless your static memory can go away.
    1360  * @internal ICU 3.2.1
    1361  */
    1362 U_INTERNAL void U_EXPORT2
    1363 ucol_forgetUCA(void);
    13641409
    13651410/** Touches all resources needed for instantiating a collator from a short string definition,
     
    14101455 *  collator remains owned by the user and should stay around for
    14111456 *  the lifetime of the collator. The API also takes a base collator
    1412  *  which usualy should be UCA.
     1457 *  which must be the root collator.
    14131458 *  @param bin binary image owned by the user and required through the
    14141459 *             lifetime of the collator
    14151460 *  @param length size of the image. If negative, the API will try to
    14161461 *                figure out the length of the image
    1417  *  @param base fallback collator, usually UCA. Base is required to be
    1418  *              present through the lifetime of the collator. Currently
    1419  *              it cannot be NULL.
     1462 *  @param base Base collator, for lookup of untailored characters.
     1463 *              Must be the root collator, must not be NULL.
     1464 *              The base is required to be present through the lifetime of the collator.
    14201465 *  @param status for catching errors
    14211466 *  @return newly created collator
  • trunk/Source/JavaScriptCore/icu/unicode/uconfig.h

    r196492 r215722  
    11/* 
    22**********************************************************************
    3 *   Copyright (C) 2002-2013, International Business Machines
     3*   Copyright (C) 2002-2015, International Business Machines
    44*   Corporation and others.  All Rights Reserved.
    55**********************************************************************
     
    186186    /* Use the predefined value. */
    187187#elif defined(U_LIB_SUFFIX_C_NAME)
    188 #   define U_LIB_SUFFIX_C_NAME_STRING #U_LIB_SUFFIX_C_NAME
     188#   define CONVERT_TO_STRING(s) #s
     189#   define U_LIB_SUFFIX_C_NAME_STRING CONVERT_TO_STRING(U_LIB_SUFFIX_C_NAME)
    189190#else
    190191#   define U_LIB_SUFFIX_C_NAME_STRING ""
     
    200201 * for ICU to work on EBCDIC platforms (for the default converter).
    201202 * If you want "only collation" and do not build for EBCDIC,
    202  * then you can define UCONFIG_NO_LEGACY_CONVERSION 1 as well.
     203 * then you can define UCONFIG_NO_CONVERSION or UCONFIG_NO_LEGACY_CONVERSION to 1 as well.
    203204 *
    204205 * @stable ICU 2.4
     
    246247#endif
    247248
     249#if UCONFIG_NO_FILE_IO && defined(U_TIMEZONE_FILES_DIR)
     250#   error Contradictory file io switches in uconfig.h.
     251#endif
     252
    248253/**
    249254 * \def UCONFIG_NO_CONVERSION
     
    263268#if UCONFIG_NO_CONVERSION
    264269#   define UCONFIG_NO_LEGACY_CONVERSION 1
     270#endif
     271
     272/**
     273 * \def UCONFIG_ONLY_HTML_CONVERSION
     274 * This switch turns off all of the converters NOT listed in
     275 * the HTML encoding standard:
     276 * http://www.w3.org/TR/encoding/#names-and-labels
     277 *
     278 * This is not possible on EBCDIC platforms
     279 * because they need ibm-37 or ibm-1047 default converters.
     280 *
     281 * @draft ICU 55
     282 */
     283#ifndef UCONFIG_ONLY_HTML_CONVERSION
     284#   define UCONFIG_ONLY_HTML_CONVERSION 0
    265285#endif
    266286
     
    386406 */
    387407#ifndef UCONFIG_NO_SERVICE
    388 #   define UCONFIG_NO_SERVICE 1
     408#   define UCONFIG_NO_SERVICE 0
    389409#endif
    390410
     
    410430#endif
    411431
    412 #endif
     432/**
     433 * \def UCONFIG_NO_FILTERED_BREAK_ITERATION
     434 * This switch turns off filtered break iteration code.
     435 *
     436 * @internal
     437 */
     438#ifndef UCONFIG_NO_FILTERED_BREAK_ITERATION
     439#   define UCONFIG_NO_FILTERED_BREAK_ITERATION 0
     440
     441
     442
     443#endif
     444
     445#endif
  • trunk/Source/JavaScriptCore/icu/unicode/ucurr.h

    r203381 r215722  
    11/*
    22**********************************************************************
    3 * Copyright (c) 2002-2013, International Business Machines
     3* Copyright (c) 2002-2014, International Business Machines
    44* Corporation and others.  All Rights Reserved.
    55**********************************************************************
     
    1717
    1818#if !UCONFIG_NO_FORMATTING
     19
     20/**
     21 * Currency Usage used for Decimal Format
     22 * @draft ICU 54
     23 */
     24enum UCurrencyUsage {
     25#ifndef U_HIDE_DRAFT_API
     26    /**
     27     * a setting to specify currency usage which determines currency digit
     28     * and rounding for standard usage, for example: "50.00 NT$"
     29     * used as DEFAULT value
     30     * @draft ICU 54
     31     */
     32    UCURR_USAGE_STANDARD=0,
     33    /**
     34     * a setting to specify currency usage which determines currency digit
     35     * and rounding for cash usage, for example: "50 NT$"
     36     * @draft ICU 54
     37     */
     38    UCURR_USAGE_CASH=1,
     39#endif  /* U_HIDE_DRAFT_API */
     40    /**
     41     * One higher than the last enum UCurrencyUsage constant.
     42     * @draft ICU 54
     43     */
     44    UCURR_USAGE_COUNT=2
     45};
     46typedef enum UCurrencyUsage UCurrencyUsage;
    1947
    2048/**
     
    166194 * Returns the number of the number of fraction digits that should
    167195 * be displayed for the given currency.
     196 * This is equivalent to ucurr_getDefaultFractionDigitsForUsage(currency,UCURR_USAGE_STANDARD,ec);
    168197 * @param currency null-terminated 3-letter ISO 4217 code
    169198 * @param ec input-output error code
     
    176205                               UErrorCode* ec);
    177206
     207#ifndef U_HIDE_DRAFT_API
     208/**
     209 * Returns the number of the number of fraction digits that should
     210 * be displayed for the given currency with usage.
     211 * @param currency null-terminated 3-letter ISO 4217 code
     212 * @param usage enum usage for the currency
     213 * @param ec input-output error code
     214 * @return a non-negative number of fraction digits to be
     215 * displayed, or 0 if there is an error
     216 * @draft ICU 54
     217 */
     218U_DRAFT int32_t U_EXPORT2
     219ucurr_getDefaultFractionDigitsForUsage(const UChar* currency,
     220                                       const UCurrencyUsage usage,
     221                                       UErrorCode* ec);
     222#endif  /* U_HIDE_DRAFT_API */
     223
    178224/**
    179225 * Returns the rounding increment for the given currency, or 0.0 if no
    180226 * rounding is done by the currency.
     227 * This is equivalent to ucurr_getRoundingIncrementForUsage(currency,UCURR_USAGE_STANDARD,ec);
    181228 * @param currency null-terminated 3-letter ISO 4217 code
    182229 * @param ec input-output error code
     
    188235ucurr_getRoundingIncrement(const UChar* currency,
    189236                           UErrorCode* ec);
     237
     238#ifndef U_HIDE_DRAFT_API
     239/**
     240 * Returns the rounding increment for the given currency, or 0.0 if no
     241 * rounding is done by the currency given usage.
     242 * @param currency null-terminated 3-letter ISO 4217 code
     243 * @param usage enum usage for the currency
     244 * @param ec input-output error code
     245 * @return the non-negative rounding increment, or 0.0 if none,
     246 * or 0.0 if there is an error
     247 * @draft ICU 54
     248 */
     249U_DRAFT double U_EXPORT2
     250ucurr_getRoundingIncrementForUsage(const UChar* currency,
     251                                   const UCurrencyUsage usage,
     252                                   UErrorCode* ec);
     253#endif  /* U_HIDE_DRAFT_API */
    190254
    191255/**
  • trunk/Source/JavaScriptCore/icu/unicode/udatpg.h

    r196492 r215722  
    22*******************************************************************************
    33*
    4 *   Copyright (C) 2007-2012, International Business Machines
     4*   Copyright (C) 2007-2015, International Business Machines
    55*   Corporation and others.  All Rights Reserved.
    66*
     
    410410
    411411/**
    412  * The date time format is a message format pattern used to compose date and
    413  * time patterns. The default value is "{0} {1}", where {0} will be replaced
    414  * by the date pattern and {1} will be replaced by the time pattern.
     412 * The DateTimeFormat is a message format pattern used to compose date and
     413 * time patterns. The default pattern in the root locale is "{1} {0}", where
     414 * {1} will be replaced by the date pattern and {0} will be replaced by the
     415 * time pattern; however, other locales may specify patterns such as
     416 * "{1}, {0}" or "{1} 'at' {0}", etc.
    415417 * <p>
    416418 * This is used when the input skeleton contains both date and time fields,
    417419 * but there is not a close match among the added patterns. For example,
    418420 * suppose that this object was created by adding "dd-MMM" and "hh:mm", and
    419  * its datetimeFormat is the default "{0} {1}". Then if the input skeleton
     421 * its DateTimeFormat is the default "{1} {0}". Then if the input skeleton
    420422 * is "MMMdhmm", there is not an exact match, so the input skeleton is
    421423 * broken up into two components "MMMd" and "hmm". There are close matches
     
    425427 * @param dtpg a pointer to UDateTimePatternGenerator.
    426428 * @param dtFormat
    427  *            message format pattern, here {0} will be replaced by the date
    428  *            pattern and {1} will be replaced by the time pattern.
     429 *            message format pattern, here {1} will be replaced by the date
     430 *            pattern and {0} will be replaced by the time pattern.
    429431 * @param length the length of dtFormat.
    430432 * @stable ICU 3.8
  • trunk/Source/JavaScriptCore/icu/unicode/udisplaycontext.h

    r196492 r215722  
    11/*
    22*****************************************************************************************
    3 * Copyright (C) 2013, International Business Machines
     3* Copyright (C) 2014, International Business Machines
    44* Corporation and others. All Rights Reserved.
    55*****************************************************************************************
     
    1313#if !UCONFIG_NO_FORMATTING
    1414
    15 /* Dont hide with #ifndef U_HIDE_DRAFT_API, needed by virtual methods */
    1615/**
    1716 * \file
     
    2221 * Display context types, for getting values of a particular setting.
    2322 * Note, the specific numeric values are internal and may change.
    24  * @draft ICU 51
     23 * @stable ICU 51
    2524 */
    2625enum UDisplayContextType {
    27 #ifndef U_HIDE_DRAFT_API
    2826    /**
    2927     * Type to retrieve the dialect handling setting, e.g.
    3028     * UDISPCTX_STANDARD_NAMES or UDISPCTX_DIALECT_NAMES.
    31      * @draft ICU 51
     29     * @stable ICU 51
    3230     */
    3331    UDISPCTX_TYPE_DIALECT_HANDLING = 0,
     
    3634     * UDISPCTX_CAPITALIZATION_NONE, UDISPCTX_CAPITALIZATION_FOR_MIDDLE_OF_SENTENCE,
    3735     * UDISPCTX_CAPITALIZATION_FOR_BEGINNING_OF_SENTENCE, etc.
    38      * @draft ICU 51
     36     * @stable ICU 51
    3937     */
    4038    UDISPCTX_TYPE_CAPITALIZATION = 1
    41 #endif /* U_HIDE_DRAFT_API */
     39#ifndef U_HIDE_DRAFT_API
     40    ,
     41    /**
     42     * Type to retrieve the display length setting, e.g.
     43     * UDISPCTX_LENGTH_FULL, UDISPCTX_LENGTH_SHORT.
     44     * @draft ICU 54
     45     */
     46    UDISPCTX_TYPE_DISPLAY_LENGTH = 2
     47#endif  /* U_HIDE_DRAFT_API */
    4248};
    4349/**
    44 *  @draft ICU 51
     50*  @stable ICU 51
    4551*/
    4652typedef enum UDisplayContextType UDisplayContextType;
    4753
    48 /* Dont hide with #ifndef U_HIDE_DRAFT_API, needed by virtual methods */
    4954/**
    5055 * Display context settings.
    5156 * Note, the specific numeric values are internal and may change.
    52  * @draft ICU 51
     57 * @stable ICU 51
    5358 */
    5459enum UDisplayContext {
    55 #ifndef U_HIDE_DRAFT_API
    5660    /**
    5761     * ================================
     
    6468     * use standard names when generating a locale name,
    6569     * e.g. en_GB displays as 'English (United Kingdom)'.
    66      * @draft ICU 51
     70     * @stable ICU 51
    6771     */
    6872    UDISPCTX_STANDARD_NAMES = (UDISPCTX_TYPE_DIALECT_HANDLING<<8) + 0,
     
    7175     * use dialect names, when generating a locale name,
    7276     * e.g. en_GB displays as 'British English'.
    73      * @draft ICU 51
     77     * @stable ICU 51
    7478     */
    7579    UDISPCTX_DIALECT_NAMES = (UDISPCTX_TYPE_DIALECT_HANDLING<<8) + 1,
     
    8589    /**
    8690     * The capitalization context to be used is unknown (this is the default value).
    87      * @draft ICU 51
     91     * @stable ICU 51
    8892     */
    8993    UDISPCTX_CAPITALIZATION_NONE = (UDISPCTX_TYPE_CAPITALIZATION<<8) + 0,
     
    9195     * The capitalization context if a date, date symbol or display name is to be
    9296     * formatted with capitalization appropriate for the middle of a sentence.
    93      * @draft ICU 51
     97     * @stable ICU 51
    9498     */
    9599    UDISPCTX_CAPITALIZATION_FOR_MIDDLE_OF_SENTENCE = (UDISPCTX_TYPE_CAPITALIZATION<<8) + 1,
     
    97101     * The capitalization context if a date, date symbol or display name is to be
    98102     * formatted with capitalization appropriate for the beginning of a sentence.
    99      * @draft ICU 51
     103     * @stable ICU 51
    100104     */
    101105    UDISPCTX_CAPITALIZATION_FOR_BEGINNING_OF_SENTENCE = (UDISPCTX_TYPE_CAPITALIZATION<<8) + 2,
     
    103107     * The capitalization context if a date, date symbol or display name is to be
    104108     * formatted with capitalization appropriate for a user-interface list or menu item.
    105      * @draft ICU 51
     109     * @stable ICU 51
    106110     */
    107111    UDISPCTX_CAPITALIZATION_FOR_UI_LIST_OR_MENU = (UDISPCTX_TYPE_CAPITALIZATION<<8) + 3,
     
    110114     * formatted with capitalization appropriate for stand-alone usage such as an
    111115     * isolated name on a calendar page.
    112      * @draft ICU 51
     116     * @stable ICU 51
    113117     */
    114118    UDISPCTX_CAPITALIZATION_FOR_STANDALONE = (UDISPCTX_TYPE_CAPITALIZATION<<8) + 4
    115 #endif /* U_HIDE_DRAFT_API */
     119#ifndef U_HIDE_DRAFT_API
     120    ,
     121    /**
     122     * ================================
     123     * DISPLAY_LENGTH can be set to one of UDISPCTX_LENGTH_FULL or
     124     * UDISPCTX_LENGTH_SHORT. Use UDisplayContextType UDISPCTX_TYPE_DISPLAY_LENGTH
     125     * to get the value.
     126     */
     127    /**
     128     * A possible setting for DISPLAY_LENGTH:
     129     * use full names when generating a locale name,
     130     * e.g. "United States" for US.
     131     * @draft ICU 54
     132     */
     133    UDISPCTX_LENGTH_FULL = (UDISPCTX_TYPE_DISPLAY_LENGTH<<8) + 0,
     134    /**
     135     * A possible setting for DISPLAY_LENGTH:
     136     * use short names when generating a locale name,
     137     * e.g. "U.S." for US.
     138     * @draft ICU 54
     139     */
     140    UDISPCTX_LENGTH_SHORT = (UDISPCTX_TYPE_DISPLAY_LENGTH<<8) + 1
     141#endif  /* U_HIDE_DRAFT_API */
    116142};
    117143/**
    118 *  @draft ICU 51
     144*  @stable ICU 51
    119145*/
    120146typedef enum UDisplayContext UDisplayContext;
  • trunk/Source/JavaScriptCore/icu/unicode/uformattable.h

    r196492 r215722  
    11/*
    22********************************************************************************
    3 * Copyright (C) 2013, International Business Machines Corporation and others.
     3* Copyright (C) 2013-2014, International Business Machines Corporation and others.
    44* All Rights Reserved.
    55********************************************************************************
     
    3333#if !UCONFIG_NO_FORMATTING
    3434
    35 #ifndef U_HIDE_DRAFT_API
    36 
    3735#include "unicode/localpointer.h"
    3836
     
    4240 * or error.
    4341 * @see icu::Formattable::Type
    44  * @draft ICU 52
     42 * @stable ICU 52
    4543 */
    4644typedef enum UFormattableType {
     
    6058 * and parsing operations.
    6159 * @see icu::Formattable
    62  * @draft ICU 52
     60 * @stable ICU 52
    6361 */
    6462typedef void *UFormattable;
     
    6967 * parameter status error code.
    7068 * See {@link unum_parseToUFormattable} for example code.
    71  * @draft ICU 52
     69 * @stable ICU 52
    7270 * @return the new UFormattable
    7371 * @see ufmt_close
    7472 * @see icu::Formattable::Formattable()
    7573 */
    76 U_DRAFT UFormattable* U_EXPORT2
     74U_STABLE UFormattable* U_EXPORT2
    7775ufmt_open(UErrorCode* status);
    7876
     
    8078 * Cleanup any additional memory allocated by this UFormattable.
    8179 * @param fmt the formatter
    82  * @draft ICU 52
     80 * @stable ICU 52
    8381 * @see ufmt_open
    8482 */
    85 U_DRAFT void U_EXPORT2
     83U_STABLE void U_EXPORT2
    8684ufmt_close(UFormattable* fmt);
    8785
     
    9795 * @see LocalPointerBase
    9896 * @see LocalPointer
    99  * @draft ICU 52
     97 * @stable ICU 52
    10098 */
    10199U_DEFINE_LOCAL_OPEN_POINTER(LocalUFormattablePointer, UFormattable, ufmt_close);
     
    113111 * @see ufmt_isNumeric
    114112 * @see icu::Formattable::getType() const
    115  * @draft ICU 52
    116  */
    117 U_DRAFT UFormattableType U_EXPORT2
     113 * @stable ICU 52
     114 */
     115U_STABLE UFormattableType U_EXPORT2
    118116ufmt_getType(const UFormattable* fmt, UErrorCode *status);
    119117
     
    124122 * @see ufmt_getType
    125123 * @see icu::Formattable::isNumeric() const
    126  * @draft ICU 52
    127  */
    128 U_DRAFT UBool U_EXPORT2
     124 * @stable ICU 52
     125 */
     126U_STABLE UBool U_EXPORT2
    129127ufmt_isNumeric(const UFormattable* fmt);
    130128
     
    136134 * @param status the error code - any conversion or format errors
    137135 * @return the value
    138  * @draft ICU 52
     136 * @stable ICU 52
    139137 * @see icu::Formattable::getDate(UErrorCode&) const
    140138 */
    141 U_DRAFT UDate U_EXPORT2
     139U_STABLE UDate U_EXPORT2
    142140ufmt_getDate(const UFormattable* fmt, UErrorCode *status);
    143141
     
    154152 * @param status the error code - any conversion or format errors
    155153 * @return the value
    156  * @draft ICU 52
     154 * @stable ICU 52
    157155 * @see icu::Formattable::getDouble(UErrorCode&) const
    158156 */
    159 U_DRAFT double U_EXPORT2
     157U_STABLE double U_EXPORT2
    160158ufmt_getDouble(UFormattable* fmt, UErrorCode *status);
    161159
     
    175173 * @param status the error code - any conversion or format errors
    176174 * @return the value
    177  * @draft ICU 52
     175 * @stable ICU 52
    178176 * @see icu::Formattable::getLong(UErrorCode&) const
    179177 */
    180 U_DRAFT int32_t U_EXPORT2
     178U_STABLE int32_t U_EXPORT2
    181179ufmt_getLong(UFormattable* fmt, UErrorCode *status);
    182180
     
    196194 * @param status the error code - any conversion or format errors
    197195 * @return the value
    198  * @draft ICU 52
     196 * @stable ICU 52
    199197 * @see icu::Formattable::getInt64(UErrorCode&) const
    200198 */
    201 U_DRAFT int64_t U_EXPORT2
     199U_STABLE int64_t U_EXPORT2
    202200ufmt_getInt64(UFormattable* fmt, UErrorCode *status);
    203201
     
    209207 * @param status the error code - any conversion or format errors
    210208 * @return the value as a const void*. It is a polymorphic C++ object.
    211  * @draft ICU 52
     209 * @stable ICU 52
    212210 * @see icu::Formattable::getObject() const
    213211 */
    214 U_DRAFT const void *U_EXPORT2
     212U_STABLE const void *U_EXPORT2
    215213ufmt_getObject(const UFormattable* fmt, UErrorCode *status);
    216214
     
    224222 * @param len if non null, contains the string length on return
    225223 * @return the null terminated string value - must not be referenced after any other functions are called on this UFormattable.
    226  * @draft ICU 52
     224 * @stable ICU 52
    227225 * @see icu::Formattable::getString(UnicodeString&)const
    228226 */
    229 U_DRAFT const UChar* U_EXPORT2
     227U_STABLE const UChar* U_EXPORT2
    230228ufmt_getUChars(UFormattable* fmt, int32_t *len, UErrorCode *status);
    231229
     
    235233 * @param status the error code - any conversion or format errors. U_ILLEGAL_ARGUMENT_ERROR if not an array type.
    236234 * @return the number of array objects or undefined if not an array type
    237  * @draft ICU 52
     235 * @stable ICU 52
    238236 * @see ufmt_getArrayItemByIndex
    239237 */
    240 U_DRAFT int32_t U_EXPORT2
     238U_STABLE int32_t U_EXPORT2
    241239ufmt_getArrayLength(const UFormattable* fmt, UErrorCode *status);
    242240
     
    247245 * @param status the error code - any conversion or format errors. Returns an error if n is out of bounds.
    248246 * @return the nth array value, only valid while the containing UFormattable is valid. NULL if not an array.
    249  * @draft ICU 52
     247 * @stable ICU 52
    250248 * @see icu::Formattable::getArray(int32_t&, UErrorCode&) const
    251249 */
    252 U_DRAFT UFormattable * U_EXPORT2
     250U_STABLE UFormattable * U_EXPORT2
    253251ufmt_getArrayItemByIndex(UFormattable* fmt, int32_t n, UErrorCode *status);
    254252
     
    272270 * @param status the error code
    273271 * @return the character buffer as a NULL terminated string, which is owned by the object and must not be accessed if any other functions are called on this object.
    274  * @draft ICU 52
     272 * @stable ICU 52
    275273 * @see icu::Formattable::getDecimalNumber(UErrorCode&)
    276274 */
    277 U_DRAFT const char * U_EXPORT2
     275U_STABLE const char * U_EXPORT2
    278276ufmt_getDecNumChars(UFormattable *fmt, int32_t *len, UErrorCode *status);
    279 #endif  /* U_HIDE_DRAFT_API */
    280277
    281278#endif
  • trunk/Source/JavaScriptCore/icu/unicode/uloc.h

    r196492 r215722  
    11/*
    22**********************************************************************
    3 *   Copyright (C) 1997-2013, International Business Machines
     3*   Copyright (C) 1997-2014, International Business Machines
    44*   Corporation and others.  All Rights Reserved.
    55**********************************************************************
     
    273273 * @stable ICU 2.8
    274274 */
    275 #define ULOC_KEYWORDS_CAPACITY 50
     275#define ULOC_KEYWORDS_CAPACITY 96
    276276
    277277/**
     
    887887                     UErrorCode* status);
    888888
     889#ifndef U_HIDE_DRAFT_API
     890/**
     891 * Returns whether the locale's script is written right-to-left.
     892 * If there is no script subtag, then the likely script is used, see uloc_addLikelySubtags().
     893 * If no likely script is known, then FALSE is returned.
     894 *
     895 * A script is right-to-left according to the CLDR script metadata
     896 * which corresponds to whether the script's letters have Bidi_Class=R or AL.
     897 *
     898 * Returns TRUE for "ar" and "en-Hebr", FALSE for "zh" and "fa-Cyrl".
     899 *
     900 * @param locale input locale ID
     901 * @return TRUE if the locale's script is written right-to-left
     902 * @draft ICU 54
     903 */
     904U_DRAFT UBool U_EXPORT2
     905uloc_isRightToLeft(const char *locale);
     906#endif  /* U_HIDE_DRAFT_API */
     907
    889908/**
    890909 * enums for the  return value for the character and line orientation
     
    11331152                   UErrorCode* err);
    11341153
     1154#ifndef U_HIDE_DRAFT_API
     1155/**
     1156 * Converts the specified keyword (legacy key, or BCP 47 Unicode locale
     1157 * extension key) to the equivalent BCP 47 Unicode locale extension key.
     1158 * For example, BCP 47 Unicode locale extension key "co" is returned for
     1159 * the input keyword "collation".
     1160 * <p>
     1161 * When the specified keyword is unknown, but satisfies the BCP syntax,
     1162 * then the pointer to the input keyword itself will be returned.
     1163 * For example,
     1164 * <code>uloc_toUnicodeLocaleKey("ZZ")</code> returns "ZZ".
     1165 *
     1166 * @param keyword       the input locale keyword (either legacy key
     1167 *                      such as "collation" or BCP 47 Unicode locale extension
     1168 *                      key such as "co").
     1169 * @return              the well-formed BCP 47 Unicode locale extension key,
     1170 *                      or NULL if the specified locale keyword cannot be
     1171 *                      mapped to a well-formed BCP 47 Unicode locale extension
     1172 *                      key.
     1173 * @see uloc_toLegacyKey
     1174 * @draft ICU 54
     1175 */
     1176U_DRAFT const char* U_EXPORT2
     1177uloc_toUnicodeLocaleKey(const char* keyword);
     1178
     1179/**
     1180 * Converts the specified keyword value (legacy type, or BCP 47
     1181 * Unicode locale extension type) to the well-formed BCP 47 Unicode locale
     1182 * extension type for the specified keyword (category). For example, BCP 47
     1183 * Unicode locale extension type "phonebk" is returned for the input
     1184 * keyword value "phonebook", with the keyword "collation" (or "co").
     1185 * <p>
     1186 * When the specified keyword is not recognized, but the specified value
     1187 * satisfies the syntax of the BCP 47 Unicode locale extension type,
     1188 * or when the specified keyword allows 'variable' type and the specified
     1189 * value satisfies the syntax,  then the pointer to the input type value itself
     1190 * will be returned.
     1191 * For example,
     1192 * <code>uloc_toUnicodeLocaleType("Foo", "Bar")</code> returns "Bar",
     1193 * <code>uloc_toUnicodeLocaleType("variableTop", "00A4")</code> returns "00A4".
     1194 *
     1195 * @param keyword       the locale keyword (either legacy key such as
     1196 *                      "collation" or BCP 47 Unicode locale extension
     1197 *                      key such as "co").
     1198 * @param value         the locale keyword value (either legacy type
     1199 *                      such as "phonebook" or BCP 47 Unicode locale extension
     1200 *                      type such as "phonebk").
     1201 * @return              the well-formed BCP47 Unicode locale extension type,
     1202 *                      or NULL if the locale keyword value cannot be mapped to
     1203 *                      a well-formed BCP 47 Unicode locale extension type.
     1204 * @see uloc_toLegacyType
     1205 * @draft ICU 54
     1206 */
     1207U_DRAFT const char* U_EXPORT2
     1208uloc_toUnicodeLocaleType(const char* keyword, const char* value);
     1209
     1210/**
     1211 * Converts the specified keyword (BCP 47 Unicode locale extension key, or
     1212 * legacy key) to the legacy key. For example, legacy key "collation" is
     1213 * returned for the input BCP 47 Unicode locale extension key "co".
     1214 *
     1215 * @param keyword       the input locale keyword (either BCP 47 Unicode locale
     1216 *                      extension key or legacy key).
     1217 * @return              the well-formed legacy key, or NULL if the specified
     1218 *                      keyword cannot be mapped to a well-formed legacy key.
     1219 * @see toUnicodeLocaleKey
     1220 * @draft ICU 54
     1221 */
     1222U_DRAFT const char* U_EXPORT2
     1223uloc_toLegacyKey(const char* keyword);
     1224
     1225/**
     1226 * Converts the specified keyword value (BCP 47 Unicode locale extension type,
     1227 * or legacy type or type alias) to the canonical legacy type. For example,
     1228 * the legacy type "phonebook" is returned for the input BCP 47 Unicode
     1229 * locale extension type "phonebk" with the keyword "collation" (or "co").
     1230 * <p>
     1231 * When the specified keyword is not recognized, but the specified value
     1232 * satisfies the syntax of legacy key, or when the specified keyword
     1233 * allows 'variable' type and the specified value satisfies the syntax,
     1234 * then the pointer to the input type value itself will be returned.
     1235 * For example,
     1236 * <code>uloc_toLegacyType("Foo", "Bar")</code> returns "Bar",
     1237 * <code>uloc_toLegacyType("vt", "00A4")</code> returns "00A4".
     1238 *
     1239 * @param keyword       the locale keyword (either legacy keyword such as
     1240 *                      "collation" or BCP 47 Unicode locale extension
     1241 *                      key such as "co").
     1242 * @param value         the locale keyword value (either BCP 47 Unicode locale
     1243 *                      extension type such as "phonebk" or legacy keyword value
     1244 *                      such as "phonebook").
     1245 * @return              the well-formed legacy type, or NULL if the specified
     1246 *                      keyword value cannot be mapped to a well-formed legacy
     1247 *                      type.
     1248 * @see toUnicodeLocaleType
     1249 * @draft ICU 54
     1250 */
     1251U_DRAFT const char* U_EXPORT2
     1252uloc_toLegacyType(const char* keyword, const char* value);
     1253
     1254#endif  /* U_HIDE_DRAFT_API */
     1255
    11351256#endif /*_ULOC*/
  • trunk/Source/JavaScriptCore/icu/unicode/umachine.h

    r196492 r215722  
    22******************************************************************************
    33*
    4 *   Copyright (C) 1999-2012, International Business Machines
     4*   Copyright (C) 1999-2014, International Business Machines
    55*   Corporation and others.  All Rights Reserved.
    66*
     
    1414*   created by: Markus W. Scherer
    1515*
    16 *   This file defines basic types and constants for utf.h to be
     16*   This file defines basic types and constants for ICU to be
    1717*   platform-independent. umachine.h and utf.h are included into
    1818*   utypes.h to provide all the general definitions for ICU.
     
    116116/** This is used to declare a function as an internal ICU C API  */
    117117#define U_INTERNAL U_CAPI
     118
     119/**
     120 * \def U_OVERRIDE
     121 * Defined to the C++11 "override" keyword if available.
     122 * Denotes a class or member which is an override of the base class.
     123 * May result in an error if it applied to something not an override.
     124 * @internal
     125 */
     126
     127/**
     128 * \def U_FINAL
     129 * Defined to the C++11 "final" keyword if available.
     130 * Denotes a class or member which may not be overridden in subclasses.
     131 * May result in an error if subclasses attempt to override.
     132 * @internal
     133 */
     134
     135#if defined(__cplusplus) && __cplusplus>=201103L
     136/* C++11 */
     137#ifndef U_OVERRIDE
     138#define U_OVERRIDE override
     139#endif
     140#ifndef U_FINAL
     141#define U_FINAL final
     142#endif
     143#else
     144/* not C++11 - define to nothing */
     145#ifndef U_OVERRIDE
     146#define U_OVERRIDE
     147#endif
     148#ifndef U_FINAL
     149#define U_FINAL
     150#endif
     151#endif
    118152
    119153/*==========================================================================*/
  • trunk/Source/JavaScriptCore/icu/unicode/unum.h

    r196492 r215722  
    11/*
    22*******************************************************************************
    3 * Copyright (C) 1997-2013, International Business Machines Corporation and others.
     3* Copyright (C) 1997-2015, International Business Machines Corporation and others.
    44* All Rights Reserved.
    55* Modification History:
     
    1919#include "unicode/localpointer.h"
    2020#include "unicode/uloc.h"
     21#include "unicode/ucurr.h"
    2122#include "unicode/umisc.h"
    2223#include "unicode/parseerr.h"
    2324#include "unicode/uformattable.h"
     25#include "unicode/udisplaycontext.h"
    2426
    2527/**
     
    150152     * @stable ICU 2.0
    151153     */
    152     UNUM_CURRENCY,
     154    UNUM_CURRENCY=2,
    153155    /**
    154156     * Percent format
    155157     * @stable ICU 2.0
    156158     */
    157     UNUM_PERCENT,
     159    UNUM_PERCENT=3,
    158160    /**
    159161     * Scientific format
    160162     * @stable ICU 2.1
    161163     */
    162     UNUM_SCIENTIFIC,
    163     /**
    164      * Spellout rule-based format
     164    UNUM_SCIENTIFIC=4,
     165    /**
     166     * Spellout rule-based format. The default ruleset can be specified/changed using
     167     * unum_setTextAttribute with UNUM_DEFAULT_RULESET; the available public rulesets
     168     * can be listed using unum_getTextAttribute with UNUM_PUBLIC_RULESETS.
    165169     * @stable ICU 2.0
    166170     */
    167     UNUM_SPELLOUT,
     171    UNUM_SPELLOUT=5,
    168172    /**
    169      * Ordinal rule-based format
     173     * Ordinal rule-based format . The default ruleset can be specified/changed using
     174     * unum_setTextAttribute with UNUM_DEFAULT_RULESET; the available public rulesets
     175     * can be listed using unum_getTextAttribute with UNUM_PUBLIC_RULESETS.
    170176     * @stable ICU 3.0
    171177     */
    172     UNUM_ORDINAL,
     178    UNUM_ORDINAL=6,
    173179    /**
    174180     * Duration rule-based format
    175181     * @stable ICU 3.0
    176182     */
    177     UNUM_DURATION,
     183    UNUM_DURATION=7,
    178184    /**
    179185     * Numbering system rule-based format
    180186     * @stable ICU 4.2
    181187     */
    182     UNUM_NUMBERING_SYSTEM,
     188    UNUM_NUMBERING_SYSTEM=8,
    183189    /**
    184190     * Rule-based format defined by a pattern string.
    185191     * @stable ICU 3.0
    186192     */
    187     UNUM_PATTERN_RULEBASED,
     193    UNUM_PATTERN_RULEBASED=9,
    188194    /**
    189195     * Currency format with an ISO currency code, e.g., "USD1.00".
    190196     * @stable ICU 4.8
    191197     */
    192     UNUM_CURRENCY_ISO,
     198    UNUM_CURRENCY_ISO=10,
    193199    /**
    194200     * Currency format with a pluralized currency name,
     
    196202     * @stable ICU 4.8
    197203     */
    198     UNUM_CURRENCY_PLURAL,
     204    UNUM_CURRENCY_PLURAL=11,
     205    /**
     206     * Currency format for accounting, e.g., "($3.00)" for
     207     * negative currency amount instead of "-$3.00" ({@link #UNUM_CURRENCY}).
     208     * @stable ICU 53
     209     */
     210    UNUM_CURRENCY_ACCOUNTING=12,
     211#ifndef U_HIDE_DRAFT_API
     212    /**
     213     * Currency format with a currency symbol given CASH usage, e.g.,
     214     * "NT$3" instead of "NT$3.23".
     215     * @draft ICU 54
     216     */
     217    UNUM_CASH_CURRENCY=13,
     218#endif /* U_HIDE_DRAFT_API */
     219
    199220    /**
    200221     * One more than the highest number format style constant.
    201222     * @stable ICU 4.8
    202223     */
    203     UNUM_FORMAT_STYLE_COUNT,
     224    UNUM_FORMAT_STYLE_COUNT=14,
     225
    204226    /**
    205227     * Default format
     
    253275} UNumberFormatPadPosition;
    254276
    255 #ifndef U_HIDE_DRAFT_API
    256277/**
    257278 * Constants for specifying short or long format.
    258  * @draft ICU 51
     279 * @stable ICU 51
    259280 */
    260281typedef enum UNumberCompactStyle {
    261   /** @draft ICU 51 */
     282  /** @stable ICU 51 */
    262283  UNUM_SHORT,
    263   /** @draft ICU 51 */
     284  /** @stable ICU 51 */
    264285  UNUM_LONG
    265   /** @draft ICU 51 */
     286  /** @stable ICU 51 */
    266287} UNumberCompactStyle;
    267 #endif /* U_HIDE_DRAFT_API */
    268288
    269289/**
     
    324344 * used by this object.
    325345 * @param style The type of number format to open: one of
    326  * UNUM_DECIMAL, UNUM_CURRENCY, UNUM_PERCENT, UNUM_SCIENTIFIC, UNUM_SPELLOUT,
     346 * UNUM_DECIMAL, UNUM_CURRENCY, UNUM_PERCENT, UNUM_SCIENTIFIC,
     347 * UNUM_CURRENCY_ISO, UNUM_CURRENCY_PLURAL, UNUM_SPELLOUT,
     348 * UNUM_ORDINAL, UNUM_DURATION, UNUM_NUMBERING_SYSTEM,
    327349 * UNUM_PATTERN_DECIMAL, UNUM_PATTERN_RULEBASED, or UNUM_DEFAULT.
    328350 * If UNUM_PATTERN_DECIMAL or UNUM_PATTERN_RULEBASED is passed then the
     
    563585                          UErrorCode* status);
    564586
    565 #ifndef U_HIDE_DRAFT_API
    566587/**
    567588 * Format a UFormattable into a string.
     
    582603 * the output was truncated. Will return 0 on error.
    583604 * @see unum_parseToUFormattable
    584  * @draft ICU 52
    585  */
    586 U_DRAFT int32_t U_EXPORT2
     605 * @stable ICU 52
     606 */
     607U_STABLE int32_t U_EXPORT2
    587608unum_formatUFormattable(const UNumberFormat* fmt,
    588609                        const UFormattable *number,
     
    591612                        UFieldPosition *pos,
    592613                        UErrorCode *status);
    593 #endif  /* U_HIDE_DRAFT_API */
    594614
    595615/**
     
    727747                         UErrorCode* status);
    728748
    729 #ifndef U_HIDE_DRAFT_API
    730749/**
    731750 * Parse a UChar string into a UFormattable.
     
    744763 * @see ufmt_getType
    745764 * @see ufmt_close
    746  * @draft ICU 52
    747  */
    748 U_DRAFT UFormattable* U_EXPORT2
     765 * @stable ICU 52
     766 */
     767U_STABLE UFormattable* U_EXPORT2
    749768unum_parseToUFormattable(const UNumberFormat* fmt,
    750769                         UFormattable *result,
     
    753772                         int32_t* parsePos, /* 0 = start */
    754773                         UErrorCode* status);
    755 #endif  /* U_HIDE_DRAFT_API */
    756774
    757775/**
     
    806824
    807825#if UCONFIG_HAVE_PARSEALLINPUT
     826/* The UNumberFormatAttributeValue type cannot be #ifndef U_HIDE_INTERNAL_API, needed for .h variable declaration */
    808827/**
    809828 * @internal
    810829 */
    811830typedef enum UNumberFormatAttributeValue {
     831#ifndef U_HIDE_INTERNAL_API
    812832  /** @internal */
    813833  UNUM_NO = 0,
     
    816836  /** @internal */
    817837  UNUM_MAYBE = 2
     838#endif /* U_HIDE_INTERNAL_API */
    818839} UNumberFormatAttributeValue;
    819840#endif
     
    873894  UNUM_PARSE_ALL_INPUT = UNUM_LENIENT_PARSE + 1,
    874895#endif
    875 #ifndef U_HIDE_DRAFT_API
    876896  /**
    877897    * Scale, which adjusts the position of the
     
    882902    * <p>Example: setting the scale to -4, 123 formats as "0.0123"
    883903    *
    884    * @draft ICU 51 */
     904   * @stable ICU 51 */
    885905  UNUM_SCALE = UNUM_LENIENT_PARSE + 2,
    886 #endif /* U_HIDE_DRAFT_API */
    887906
    888907#ifndef U_HIDE_INTERNAL_API
     
    890909   * @internal */
    891910  UNUM_NUMERIC_ATTRIBUTE_COUNT = UNUM_LENIENT_PARSE + 3,
    892 
     911#endif  /* U_HIDE_INTERNAL_API */
     912
     913#ifndef U_HIDE_DRAFT_API
     914  /**
     915   * if this attribute is set to 0, it is set to UNUM_CURRENCY_STANDARD purpose,
     916   * otherwise it is UNUM_CURRENCY_CASH purpose
     917   * Default: 0 (UNUM_CURRENCY_STANDARD purpose)
     918   * @draft ICU 54
     919   */
     920  UNUM_CURRENCY_USAGE = UNUM_LENIENT_PARSE + 4,
     921#endif  /* U_HIDE_DRAFT_API */
     922
     923  /* The following cannot be #ifndef U_HIDE_INTERNAL_API, needed in .h file variable declararions */
    893924  /** One below the first bitfield-boolean item.
    894925   * All items after this one are stored in boolean form.
    895926   * @internal */
    896927  UNUM_MAX_NONBOOLEAN_ATTRIBUTE = 0x0FFF,
    897 #endif  /* U_HIDE_INTERNAL_API */
    898928
    899929  /** If 1, specifies that if setting the "max integer digits" attribute would truncate a value, set an error status rather than silently truncating.
     
    911941  UNUM_PARSE_NO_EXPONENT,
    912942
    913 #ifndef U_HIDE_INTERNAL_API
     943#ifndef U_HIDE_DRAFT_API
     944  /**
     945   * if this attribute is set to 1, specifies that, if the pattern contains a
     946   * decimal mark the input is required to have one. If this attribute is set to 0,
     947   * specifies that input does not have to contain a decimal mark.
     948   * Has no effect on formatting.
     949   * Default: 0 (unset)
     950   * @draft ICU 54
     951   */
     952  UNUM_PARSE_DECIMAL_MARK_REQUIRED = UNUM_PARSE_NO_EXPONENT+1,
     953#endif  /* U_HIDE_DRAFT_API */
     954
     955  /* The following cannot be #ifndef U_HIDE_INTERNAL_API, needed in .h file variable declararions */
    914956  /** Limit of boolean attributes.
    915957   * @internal */
    916   UNUM_LIMIT_BOOLEAN_ATTRIBUTE
    917 #endif  /* U_HIDE_INTERNAL_API */
     958  UNUM_LIMIT_BOOLEAN_ATTRIBUTE = UNUM_PARSE_NO_EXPONENT+2
    918959} UNumberFormatAttribute;
    919960
     
    10161057  UNUM_CURRENCY_CODE,
    10171058  /**
    1018    * The default rule set.  This is only available with rule-based formatters.
     1059   * The default rule set, such as "%spellout-numbering-year:", "%spellout-cardinal:",
     1060   * "%spellout-ordinal-masculine-plural:", "%spellout-ordinal-feminine:", or
     1061   * "%spellout-ordinal-neuter:". The available public rulesets can be listed using
     1062   * unum_getTextAttribute with UNUM_PUBLIC_RULESETS. This is only available with
     1063   * rule-based formatters.
    10191064   * @stable ICU 3.0
    10201065   */
     
    10231068   * The public rule sets.  This is only available with rule-based formatters.
    10241069   * This is a read-only attribute.  The public rulesets are returned as a
    1025    * single string, with each ruleset name delimited by ';' (semicolon).
     1070   * single string, with each ruleset name delimited by ';' (semicolon). See the
     1071   * CLDR LDML spec for more information about RBNF rulesets:
     1072   * http://www.unicode.org/reports/tr35/tr35-numbers.html#Rule-Based_Number_Formatting
    10261073   * @stable ICU 3.0
    10271074   */
     
    11811228   */
    11821229  UNUM_NINE_DIGIT_SYMBOL = 26,
     1230
     1231#ifndef U_HIDE_DRAFT_API
     1232  /** Multiplication sign
     1233   * @draft ICU 54
     1234   */
     1235  UNUM_EXPONENT_MULTIPLICATION_SYMBOL = 27,
     1236#endif  /* U_HIDE_DRAFT_API */
     1237
    11831238  /** count symbol constants */
    1184   UNUM_FORMAT_SYMBOL_COUNT = 27
     1239  UNUM_FORMAT_SYMBOL_COUNT = 28
    11851240} UNumberFormatSymbol;
    11861241
     
    12431298                     UErrorCode* status);
    12441299
     1300/**
     1301 * Set a particular UDisplayContext value in the formatter, such as
     1302 * UDISPCTX_CAPITALIZATION_FOR_STANDALONE.
     1303 * @param fmt The formatter for which to set a UDisplayContext value.
     1304 * @param value The UDisplayContext value to set.
     1305 * @param status A pointer to an UErrorCode to receive any errors
     1306 * @stable ICU 53
     1307 */
     1308U_STABLE void U_EXPORT2
     1309unum_setContext(UNumberFormat* fmt, UDisplayContext value, UErrorCode* status);
     1310
     1311/**
     1312 * Get the formatter's UDisplayContext value for the specified UDisplayContextType,
     1313 * such as UDISPCTX_TYPE_CAPITALIZATION.
     1314 * @param fmt The formatter to query.
     1315 * @param type The UDisplayContextType whose value to return
     1316 * @param status A pointer to an UErrorCode to receive any errors
     1317 * @return The UDisplayContextValue for the specified type.
     1318 * @stable ICU 53
     1319 */
     1320U_STABLE UDisplayContext U_EXPORT2
     1321unum_getContext(const UNumberFormat *fmt, UDisplayContextType type, UErrorCode* status);
     1322
    12451323#endif /* #if !UCONFIG_NO_FORMATTING */
    12461324
  • trunk/Source/JavaScriptCore/icu/unicode/unumsys.h

    r194387 r215722  
    11/*
    22*****************************************************************************************
    3 * Copyright (C) 2013, International Business Machines
     3* Copyright (C) 2013-2014, International Business Machines
    44* Corporation and others. All Rights Reserved.
    55*****************************************************************************************
     
    3535 */
    3636
    37 #ifndef U_HIDE_DRAFT_API
    38 
    3937/**
    4038 * Opaque UNumberingSystem object for use in C programs.
    41  * @draft ICU 52
     39 * @stable ICU 52
    4240 */
    4341struct UNumberingSystem;
    44 typedef struct UNumberingSystem UNumberingSystem;  /**< C typedef for struct UNumberingSystem. @draft ICU 52 */
     42typedef struct UNumberingSystem UNumberingSystem;  /**< C typedef for struct UNumberingSystem. @stable ICU 52 */
    4543
    4644/**
     
    5351 * @return          A UNumberingSystem for the specified locale, or NULL if an error
    5452 *                  occurred.
    55  * @draft ICU 52
     53 * @stable ICU 52
    5654 */
    57 U_DRAFT UNumberingSystem * U_EXPORT2
     55U_STABLE UNumberingSystem * U_EXPORT2
    5856unumsys_open(const char *locale, UErrorCode *status);
    5957
     
    7472 * @return          A UNumberingSystem for the specified name, or NULL if an error
    7573 *                  occurred.
    76  * @draft ICU 52
     74 * @stable ICU 52
    7775 */
    78 U_DRAFT UNumberingSystem * U_EXPORT2
     76U_STABLE UNumberingSystem * U_EXPORT2
    7977unumsys_openByName(const char *name, UErrorCode *status);
    8078
     
    8280 * Close a UNumberingSystem object. Once closed it may no longer be used.
    8381 * @param unumsys   The UNumberingSystem object to close.
    84  * @draft ICU 52
     82 * @stable ICU 52
    8583 */
    86 U_DRAFT void U_EXPORT2
     84U_STABLE void U_EXPORT2
    8785unumsys_close(UNumberingSystem *unumsys);
    8886
     
    9694 * @see LocalPointerBase
    9795 * @see LocalPointer
    98  * @draft ICU 52
     96 * @stable ICU 52
    9997 */
    10098U_DEFINE_LOCAL_OPEN_POINTER(LocalUNumberingSystemPointer, UNumberingSystem, unumsys_close);
     
    109107 * @return          A pointer to a UEnumeration that must be closed with uenum_close(),
    110108 *                  or NULL if an error occurred.
    111  * @draft ICU 52
     109 * @stable ICU 52
    112110 */
    113 U_DRAFT UEnumeration * U_EXPORT2
     111U_STABLE UEnumeration * U_EXPORT2
    114112unumsys_openAvailableNames(UErrorCode *status);
    115113
     
    121119 *                  NULL if the name is not one of the ICU predefined names. The pointer
    122120 *                  is only valid for the lifetime of the UNumberingSystem object.
    123  * @draft ICU 52
     121 * @stable ICU 52
    124122 */
    125 U_DRAFT const char * U_EXPORT2
     123U_STABLE const char * U_EXPORT2
    126124unumsys_getName(const UNumberingSystem *unumsys);
    127125
     
    132130 * @return          TRUE if the specified UNumberingSystem object is for an algorithmic
    133131 *                  system.
    134  * @draft ICU 52
     132 * @stable ICU 52
    135133 */
    136 U_DRAFT UBool U_EXPORT2
     134U_STABLE UBool U_EXPORT2
    137135unumsys_isAlgorithmic(const UNumberingSystem *unumsys);
    138136
     
    143141 * @param unumsys   The UNumberingSystem whose radix is desired.
    144142 * @return          The radix of the specified UNumberingSystem object.
    145  * @draft ICU 52
     143 * @stable ICU 52
    146144 */
    147 U_DRAFT int32_t U_EXPORT2
     145U_STABLE int32_t U_EXPORT2
    148146unumsys_getRadix(const UNumberingSystem *unumsys);
    149147
     
    162160 * @return          The total buffer size needed; if greater than resultLength, the
    163161 *                  output was truncated.
    164  * @draft ICU 52
     162 * @stable ICU 52
    165163 */
    166 U_DRAFT int32_t U_EXPORT2
     164U_STABLE int32_t U_EXPORT2
    167165unumsys_getDescription(const UNumberingSystem *unumsys, UChar *result,
    168166                       int32_t resultLength, UErrorCode *status);
    169 
    170 #endif  /* U_HIDE_DRAFT_API */
    171167
    172168#endif /* #if !UCONFIG_NO_FORMATTING */
  • trunk/Source/JavaScriptCore/icu/unicode/urename.h

    r196492 r215722  
    11/*
    22*******************************************************************************
    3 *   Copyright (C) 2002-2013, International Business Machines
     3*   Copyright (C) 2002-2015, International Business Machines
    44*   Corporation and others.  All Rights Reserved.
    55*******************************************************************************
     
    105105#define _UTF8Data U_ICU_ENTRY_POINT_RENAME(_UTF8Data)
    106106#define cmemory_cleanup U_ICU_ENTRY_POINT_RENAME(cmemory_cleanup)
    107 #define cmemory_inUse U_ICU_ENTRY_POINT_RENAME(cmemory_inUse)
     107#define gTimeZoneFilesInitOnce U_ICU_ENTRY_POINT_RENAME(gTimeZoneFilesInitOnce)
    108108#define izrule_clone U_ICU_ENTRY_POINT_RENAME(izrule_clone)
    109109#define izrule_close U_ICU_ENTRY_POINT_RENAME(izrule_close)
     
    204204#define u_austrcpy U_ICU_ENTRY_POINT_RENAME(u_austrcpy)
    205205#define u_austrncpy U_ICU_ENTRY_POINT_RENAME(u_austrncpy)
     206#define u_caseInsensitivePrefixMatch U_ICU_ENTRY_POINT_RENAME(u_caseInsensitivePrefixMatch)
    206207#define u_catclose U_ICU_ENTRY_POINT_RENAME(u_catclose)
    207208#define u_catgets U_ICU_ENTRY_POINT_RENAME(u_catgets)
     
    240241#define u_foldCase U_ICU_ENTRY_POINT_RENAME(u_foldCase)
    241242#define u_fopen U_ICU_ENTRY_POINT_RENAME(u_fopen)
     243#define u_fopen_u U_ICU_ENTRY_POINT_RENAME(u_fopen_u)
    242244#define u_forDigit U_ICU_ENTRY_POINT_RENAME(u_forDigit)
    243245#define u_formatMessage U_ICU_ENTRY_POINT_RENAME(u_formatMessage)
     
    271273#define u_getPropertyValueEnum U_ICU_ENTRY_POINT_RENAME(u_getPropertyValueEnum)
    272274#define u_getPropertyValueName U_ICU_ENTRY_POINT_RENAME(u_getPropertyValueName)
     275#define u_getTimeZoneFilesDirectory U_ICU_ENTRY_POINT_RENAME(u_getTimeZoneFilesDirectory)
    273276#define u_getUnicodeProperties U_ICU_ENTRY_POINT_RENAME(u_getUnicodeProperties)
    274277#define u_getUnicodeVersion U_ICU_ENTRY_POINT_RENAME(u_getUnicodeVersion)
     
    332335#define u_setMemoryFunctions U_ICU_ENTRY_POINT_RENAME(u_setMemoryFunctions)
    333336#define u_setMutexFunctions U_ICU_ENTRY_POINT_RENAME(u_setMutexFunctions)
     337#define u_setTimeZoneFilesDirectory U_ICU_ENTRY_POINT_RENAME(u_setTimeZoneFilesDirectory)
    334338#define u_shapeArabic U_ICU_ENTRY_POINT_RENAME(u_shapeArabic)
    335339#define u_snprintf U_ICU_ENTRY_POINT_RENAME(u_snprintf)
     
    414418#define u_vsscanf U_ICU_ENTRY_POINT_RENAME(u_vsscanf)
    415419#define u_vsscanf_u U_ICU_ENTRY_POINT_RENAME(u_vsscanf_u)
    416 #define u_writeDiff U_ICU_ENTRY_POINT_RENAME(u_writeDiff)
    417420#define u_writeIdenticalLevelRun U_ICU_ENTRY_POINT_RENAME(u_writeIdenticalLevelRun)
    418 #define u_writeIdenticalLevelRunTwoChars U_ICU_ENTRY_POINT_RENAME(u_writeIdenticalLevelRunTwoChars)
    419421#define ubidi_addPropertyStarts U_ICU_ENTRY_POINT_RENAME(ubidi_addPropertyStarts)
    420422#define ubidi_close U_ICU_ENTRY_POINT_RENAME(ubidi_close)
     
    495497#define ubrk_setUText U_ICU_ENTRY_POINT_RENAME(ubrk_setUText)
    496498#define ubrk_swap U_ICU_ENTRY_POINT_RENAME(ubrk_swap)
     499#define ucache_compareKeys U_ICU_ENTRY_POINT_RENAME(ucache_compareKeys)
     500#define ucache_deleteKey U_ICU_ENTRY_POINT_RENAME(ucache_deleteKey)
     501#define ucache_hashKeys U_ICU_ENTRY_POINT_RENAME(ucache_hashKeys)
    497502#define ucal_add U_ICU_ENTRY_POINT_RENAME(ucal_add)
    498503#define ucal_clear U_ICU_ENTRY_POINT_RENAME(ucal_clear)
     
    691696#define ucnvsel_selectForUTF8 U_ICU_ENTRY_POINT_RENAME(ucnvsel_selectForUTF8)
    692697#define ucnvsel_serialize U_ICU_ENTRY_POINT_RENAME(ucnvsel_serialize)
    693 #define ucol_allocWeights U_ICU_ENTRY_POINT_RENAME(ucol_allocWeights)
    694 #define ucol_assembleTailoringTable U_ICU_ENTRY_POINT_RENAME(ucol_assembleTailoringTable)
    695 #define ucol_buildPermutationTable U_ICU_ENTRY_POINT_RENAME(ucol_buildPermutationTable)
    696 #define ucol_calcSortKey U_ICU_ENTRY_POINT_RENAME(ucol_calcSortKey)
    697 #define ucol_calcSortKeySimpleTertiary U_ICU_ENTRY_POINT_RENAME(ucol_calcSortKeySimpleTertiary)
    698698#define ucol_cloneBinary U_ICU_ENTRY_POINT_RENAME(ucol_cloneBinary)
    699699#define ucol_close U_ICU_ENTRY_POINT_RENAME(ucol_close)
    700700#define ucol_closeElements U_ICU_ENTRY_POINT_RENAME(ucol_closeElements)
    701701#define ucol_countAvailable U_ICU_ENTRY_POINT_RENAME(ucol_countAvailable)
    702 #define ucol_createElements U_ICU_ENTRY_POINT_RENAME(ucol_createElements)
    703 #define ucol_doCE U_ICU_ENTRY_POINT_RENAME(ucol_doCE)
    704702#define ucol_equal U_ICU_ENTRY_POINT_RENAME(ucol_equal)
    705703#define ucol_equals U_ICU_ENTRY_POINT_RENAME(ucol_equals)
    706 #define ucol_findReorderingEntry U_ICU_ENTRY_POINT_RENAME(ucol_findReorderingEntry)
    707 #define ucol_forceHanImplicit U_ICU_ENTRY_POINT_RENAME(ucol_forceHanImplicit)
    708 #define ucol_forgetUCA U_ICU_ENTRY_POINT_RENAME(ucol_forgetUCA)
    709 #define ucol_freeOffsetBuffer U_ICU_ENTRY_POINT_RENAME(ucol_freeOffsetBuffer)
    710704#define ucol_getAttribute U_ICU_ENTRY_POINT_RENAME(ucol_getAttribute)
    711 #define ucol_getAttributeOrDefault U_ICU_ENTRY_POINT_RENAME(ucol_getAttributeOrDefault)
    712705#define ucol_getAvailable U_ICU_ENTRY_POINT_RENAME(ucol_getAvailable)
    713706#define ucol_getBound U_ICU_ENTRY_POINT_RENAME(ucol_getBound)
    714 #define ucol_getCEStrengthDifference U_ICU_ENTRY_POINT_RENAME(ucol_getCEStrengthDifference)
    715 #define ucol_getCollationKey U_ICU_ENTRY_POINT_RENAME(ucol_getCollationKey)
    716707#define ucol_getContractions U_ICU_ENTRY_POINT_RENAME(ucol_getContractions)
    717708#define ucol_getContractionsAndExpansions U_ICU_ENTRY_POINT_RENAME(ucol_getContractionsAndExpansions)
    718709#define ucol_getDisplayName U_ICU_ENTRY_POINT_RENAME(ucol_getDisplayName)
    719710#define ucol_getEquivalentReorderCodes U_ICU_ENTRY_POINT_RENAME(ucol_getEquivalentReorderCodes)
    720 #define ucol_getFirstCE U_ICU_ENTRY_POINT_RENAME(ucol_getFirstCE)
    721711#define ucol_getFunctionalEquivalent U_ICU_ENTRY_POINT_RENAME(ucol_getFunctionalEquivalent)
    722712#define ucol_getKeywordValues U_ICU_ENTRY_POINT_RENAME(ucol_getKeywordValues)
    723713#define ucol_getKeywordValuesForLocale U_ICU_ENTRY_POINT_RENAME(ucol_getKeywordValuesForLocale)
    724714#define ucol_getKeywords U_ICU_ENTRY_POINT_RENAME(ucol_getKeywords)
    725 #define ucol_getLeadBytesForReorderCode U_ICU_ENTRY_POINT_RENAME(ucol_getLeadBytesForReorderCode)
    726715#define ucol_getLocale U_ICU_ENTRY_POINT_RENAME(ucol_getLocale)
    727716#define ucol_getLocaleByType U_ICU_ENTRY_POINT_RENAME(ucol_getLocaleByType)
    728717#define ucol_getMaxExpansion U_ICU_ENTRY_POINT_RENAME(ucol_getMaxExpansion)
    729 #define ucol_getNextCE U_ICU_ENTRY_POINT_RENAME(ucol_getNextCE)
     718#define ucol_getMaxVariable U_ICU_ENTRY_POINT_RENAME(ucol_getMaxVariable)
    730719#define ucol_getOffset U_ICU_ENTRY_POINT_RENAME(ucol_getOffset)
    731 #define ucol_getPrevCE U_ICU_ENTRY_POINT_RENAME(ucol_getPrevCE)
    732720#define ucol_getReorderCodes U_ICU_ENTRY_POINT_RENAME(ucol_getReorderCodes)
    733 #define ucol_getReorderCodesForLeadByte U_ICU_ENTRY_POINT_RENAME(ucol_getReorderCodesForLeadByte)
    734721#define ucol_getRules U_ICU_ENTRY_POINT_RENAME(ucol_getRules)
    735722#define ucol_getRulesEx U_ICU_ENTRY_POINT_RENAME(ucol_getRulesEx)
     
    744731#define ucol_greater U_ICU_ENTRY_POINT_RENAME(ucol_greater)
    745732#define ucol_greaterOrEqual U_ICU_ENTRY_POINT_RENAME(ucol_greaterOrEqual)
    746 #define ucol_initBuffers U_ICU_ENTRY_POINT_RENAME(ucol_initBuffers)
    747 #define ucol_initCollator U_ICU_ENTRY_POINT_RENAME(ucol_initCollator)
    748 #define ucol_initInverseUCA U_ICU_ENTRY_POINT_RENAME(ucol_initInverseUCA)
    749 #define ucol_initUCA U_ICU_ENTRY_POINT_RENAME(ucol_initUCA)
    750 #define ucol_inv_getNextCE U_ICU_ENTRY_POINT_RENAME(ucol_inv_getNextCE)
    751 #define ucol_inv_getPrevCE U_ICU_ENTRY_POINT_RENAME(ucol_inv_getPrevCE)
    752 #define ucol_isTailored U_ICU_ENTRY_POINT_RENAME(ucol_isTailored)
    753733#define ucol_keyHashCode U_ICU_ENTRY_POINT_RENAME(ucol_keyHashCode)
    754734#define ucol_looksLikeCollationBinary U_ICU_ENTRY_POINT_RENAME(ucol_looksLikeCollationBinary)
    755735#define ucol_mergeSortkeys U_ICU_ENTRY_POINT_RENAME(ucol_mergeSortkeys)
    756736#define ucol_next U_ICU_ENTRY_POINT_RENAME(ucol_next)
    757 #define ucol_nextProcessed U_ICU_ENTRY_POINT_RENAME(ucol_nextProcessed)
    758737#define ucol_nextSortKeyPart U_ICU_ENTRY_POINT_RENAME(ucol_nextSortKeyPart)
    759 #define ucol_nextWeight U_ICU_ENTRY_POINT_RENAME(ucol_nextWeight)
    760738#define ucol_normalizeShortDefinitionString U_ICU_ENTRY_POINT_RENAME(ucol_normalizeShortDefinitionString)
    761739#define ucol_open U_ICU_ENTRY_POINT_RENAME(ucol_open)
     
    765743#define ucol_openFromShortString U_ICU_ENTRY_POINT_RENAME(ucol_openFromShortString)
    766744#define ucol_openRules U_ICU_ENTRY_POINT_RENAME(ucol_openRules)
    767 #define ucol_openRulesForImport U_ICU_ENTRY_POINT_RENAME(ucol_openRulesForImport)
    768 #define ucol_open_internal U_ICU_ENTRY_POINT_RENAME(ucol_open_internal)
    769745#define ucol_prepareShortStringOpen U_ICU_ENTRY_POINT_RENAME(ucol_prepareShortStringOpen)
    770746#define ucol_previous U_ICU_ENTRY_POINT_RENAME(ucol_previous)
    771 #define ucol_previousProcessed U_ICU_ENTRY_POINT_RENAME(ucol_previousProcessed)
    772747#define ucol_primaryOrder U_ICU_ENTRY_POINT_RENAME(ucol_primaryOrder)
    773 #define ucol_prv_getSpecialCE U_ICU_ENTRY_POINT_RENAME(ucol_prv_getSpecialCE)
    774 #define ucol_prv_getSpecialPrevCE U_ICU_ENTRY_POINT_RENAME(ucol_prv_getSpecialPrevCE)
    775748#define ucol_reset U_ICU_ENTRY_POINT_RENAME(ucol_reset)
    776749#define ucol_restoreVariableTop U_ICU_ENTRY_POINT_RENAME(ucol_restoreVariableTop)
     
    778751#define ucol_secondaryOrder U_ICU_ENTRY_POINT_RENAME(ucol_secondaryOrder)
    779752#define ucol_setAttribute U_ICU_ENTRY_POINT_RENAME(ucol_setAttribute)
     753#define ucol_setMaxVariable U_ICU_ENTRY_POINT_RENAME(ucol_setMaxVariable)
    780754#define ucol_setOffset U_ICU_ENTRY_POINT_RENAME(ucol_setOffset)
    781 #define ucol_setOptionsFromHeader U_ICU_ENTRY_POINT_RENAME(ucol_setOptionsFromHeader)
    782755#define ucol_setReorderCodes U_ICU_ENTRY_POINT_RENAME(ucol_setReorderCodes)
    783 #define ucol_setReqValidLocales U_ICU_ENTRY_POINT_RENAME(ucol_setReqValidLocales)
    784756#define ucol_setStrength U_ICU_ENTRY_POINT_RENAME(ucol_setStrength)
    785757#define ucol_setText U_ICU_ENTRY_POINT_RENAME(ucol_setText)
     
    789761#define ucol_strcollUTF8 U_ICU_ENTRY_POINT_RENAME(ucol_strcollUTF8)
    790762#define ucol_swap U_ICU_ENTRY_POINT_RENAME(ucol_swap)
    791 #define ucol_swapBinary U_ICU_ENTRY_POINT_RENAME(ucol_swapBinary)
    792763#define ucol_swapInverseUCA U_ICU_ENTRY_POINT_RENAME(ucol_swapInverseUCA)
    793764#define ucol_tertiaryOrder U_ICU_ENTRY_POINT_RENAME(ucol_tertiaryOrder)
    794 #define ucol_tok_assembleTokenList U_ICU_ENTRY_POINT_RENAME(ucol_tok_assembleTokenList)
    795 #define ucol_tok_closeTokenList U_ICU_ENTRY_POINT_RENAME(ucol_tok_closeTokenList)
    796 #define ucol_tok_getNextArgument U_ICU_ENTRY_POINT_RENAME(ucol_tok_getNextArgument)
    797 #define ucol_tok_getRulesFromBundle U_ICU_ENTRY_POINT_RENAME(ucol_tok_getRulesFromBundle)
    798 #define ucol_tok_initTokenList U_ICU_ENTRY_POINT_RENAME(ucol_tok_initTokenList)
    799 #define ucol_tok_parseNextToken U_ICU_ENTRY_POINT_RENAME(ucol_tok_parseNextToken)
    800 #define ucol_updateInternalState U_ICU_ENTRY_POINT_RENAME(ucol_updateInternalState)
    801765#define ucsdet_close U_ICU_ENTRY_POINT_RENAME(ucsdet_close)
    802766#define ucsdet_detect U_ICU_ENTRY_POINT_RENAME(ucsdet_detect)
     
    818782#define ucurr_forLocaleAndDate U_ICU_ENTRY_POINT_RENAME(ucurr_forLocaleAndDate)
    819783#define ucurr_getDefaultFractionDigits U_ICU_ENTRY_POINT_RENAME(ucurr_getDefaultFractionDigits)
     784#define ucurr_getDefaultFractionDigitsForUsage U_ICU_ENTRY_POINT_RENAME(ucurr_getDefaultFractionDigitsForUsage)
    820785#define ucurr_getKeywordValuesForLocale U_ICU_ENTRY_POINT_RENAME(ucurr_getKeywordValuesForLocale)
    821786#define ucurr_getName U_ICU_ENTRY_POINT_RENAME(ucurr_getName)
     
    823788#define ucurr_getPluralName U_ICU_ENTRY_POINT_RENAME(ucurr_getPluralName)
    824789#define ucurr_getRoundingIncrement U_ICU_ENTRY_POINT_RENAME(ucurr_getRoundingIncrement)
     790#define ucurr_getRoundingIncrementForUsage U_ICU_ENTRY_POINT_RENAME(ucurr_getRoundingIncrementForUsage)
    825791#define ucurr_isAvailable U_ICU_ENTRY_POINT_RENAME(ucurr_isAvailable)
    826792#define ucurr_openISOCurrencies U_ICU_ENTRY_POINT_RENAME(ucurr_openISOCurrencies)
    827793#define ucurr_register U_ICU_ENTRY_POINT_RENAME(ucurr_register)
    828794#define ucurr_unregister U_ICU_ENTRY_POINT_RENAME(ucurr_unregister)
     795#define udat_adoptNumberFormat U_ICU_ENTRY_POINT_RENAME(udat_adoptNumberFormat)
     796#define udat_adoptNumberFormatForFields U_ICU_ENTRY_POINT_RENAME(udat_adoptNumberFormatForFields)
    829797#define udat_applyPattern U_ICU_ENTRY_POINT_RENAME(udat_applyPattern)
    830798#define udat_applyPatternRelative U_ICU_ENTRY_POINT_RENAME(udat_applyPatternRelative)
     
    834802#define udat_countSymbols U_ICU_ENTRY_POINT_RENAME(udat_countSymbols)
    835803#define udat_format U_ICU_ENTRY_POINT_RENAME(udat_format)
     804#define udat_formatCalendar U_ICU_ENTRY_POINT_RENAME(udat_formatCalendar)
     805#define udat_formatCalendarForFields U_ICU_ENTRY_POINT_RENAME(udat_formatCalendarForFields)
     806#define udat_formatForFields U_ICU_ENTRY_POINT_RENAME(udat_formatForFields)
    836807#define udat_get2DigitYearStart U_ICU_ENTRY_POINT_RENAME(udat_get2DigitYearStart)
    837808#define udat_getAvailable U_ICU_ENTRY_POINT_RENAME(udat_getAvailable)
     809#define udat_getBooleanAttribute U_ICU_ENTRY_POINT_RENAME(udat_getBooleanAttribute)
    838810#define udat_getCalendar U_ICU_ENTRY_POINT_RENAME(udat_getCalendar)
    839811#define udat_getContext U_ICU_ENTRY_POINT_RENAME(udat_getContext)
    840812#define udat_getLocaleByType U_ICU_ENTRY_POINT_RENAME(udat_getLocaleByType)
    841813#define udat_getNumberFormat U_ICU_ENTRY_POINT_RENAME(udat_getNumberFormat)
     814#define udat_getNumberFormatForField U_ICU_ENTRY_POINT_RENAME(udat_getNumberFormatForField)
    842815#define udat_getSymbols U_ICU_ENTRY_POINT_RENAME(udat_getSymbols)
    843816#define udat_isLenient U_ICU_ENTRY_POINT_RENAME(udat_isLenient)
     
    847820#define udat_registerOpener U_ICU_ENTRY_POINT_RENAME(udat_registerOpener)
    848821#define udat_set2DigitYearStart U_ICU_ENTRY_POINT_RENAME(udat_set2DigitYearStart)
     822#define udat_setBooleanAttribute U_ICU_ENTRY_POINT_RENAME(udat_setBooleanAttribute)
    849823#define udat_setCalendar U_ICU_ENTRY_POINT_RENAME(udat_setCalendar)
    850824#define udat_setContext U_ICU_ENTRY_POINT_RENAME(udat_setContext)
     
    914888#define uenum_unext U_ICU_ENTRY_POINT_RENAME(uenum_unext)
    915889#define uenum_unextDefault U_ICU_ENTRY_POINT_RENAME(uenum_unextDefault)
     890#define ufieldpositer_close U_ICU_ENTRY_POINT_RENAME(ufieldpositer_close)
     891#define ufieldpositer_next U_ICU_ENTRY_POINT_RENAME(ufieldpositer_next)
     892#define ufieldpositer_open U_ICU_ENTRY_POINT_RENAME(ufieldpositer_open)
    916893#define ufile_close_translit U_ICU_ENTRY_POINT_RENAME(ufile_close_translit)
    917894#define ufile_fill_uchar_buffer U_ICU_ENTRY_POINT_RENAME(ufile_fill_uchar_buffer)
     
    10391016#define ulist_resetList U_ICU_ENTRY_POINT_RENAME(ulist_resetList)
    10401017#define ulist_reset_keyword_values_iterator U_ICU_ENTRY_POINT_RENAME(ulist_reset_keyword_values_iterator)
     1018#define ulistfmt_close U_ICU_ENTRY_POINT_RENAME(ulistfmt_close)
     1019#define ulistfmt_format U_ICU_ENTRY_POINT_RENAME(ulistfmt_format)
     1020#define ulistfmt_open U_ICU_ENTRY_POINT_RENAME(ulistfmt_open)
    10411021#define uloc_acceptLanguage U_ICU_ENTRY_POINT_RENAME(uloc_acceptLanguage)
    10421022#define uloc_acceptLanguageFromHTTP U_ICU_ENTRY_POINT_RENAME(uloc_acceptLanguageFromHTTP)
     
    10741054#define uloc_getTableStringWithFallback U_ICU_ENTRY_POINT_RENAME(uloc_getTableStringWithFallback)
    10751055#define uloc_getVariant U_ICU_ENTRY_POINT_RENAME(uloc_getVariant)
     1056#define uloc_isRightToLeft U_ICU_ENTRY_POINT_RENAME(uloc_isRightToLeft)
    10761057#define uloc_minimizeSubtags U_ICU_ENTRY_POINT_RENAME(uloc_minimizeSubtags)
    10771058#define uloc_openKeywordList U_ICU_ENTRY_POINT_RENAME(uloc_openKeywordList)
     
    10801061#define uloc_setKeywordValue U_ICU_ENTRY_POINT_RENAME(uloc_setKeywordValue)
    10811062#define uloc_toLanguageTag U_ICU_ENTRY_POINT_RENAME(uloc_toLanguageTag)
     1063#define uloc_toLegacyKey U_ICU_ENTRY_POINT_RENAME(uloc_toLegacyKey)
     1064#define uloc_toLegacyType U_ICU_ENTRY_POINT_RENAME(uloc_toLegacyType)
     1065#define uloc_toUnicodeLocaleKey U_ICU_ENTRY_POINT_RENAME(uloc_toUnicodeLocaleKey)
     1066#define uloc_toUnicodeLocaleType U_ICU_ENTRY_POINT_RENAME(uloc_toUnicodeLocaleType)
    10821067#define ulocdata_close U_ICU_ENTRY_POINT_RENAME(ulocdata_close)
    10831068#define ulocdata_getCLDRVersion U_ICU_ENTRY_POINT_RENAME(ulocdata_getCLDRVersion)
     
    10941079#define ulocimp_getLanguage U_ICU_ENTRY_POINT_RENAME(ulocimp_getLanguage)
    10951080#define ulocimp_getScript U_ICU_ENTRY_POINT_RENAME(ulocimp_getScript)
     1081#define ulocimp_toBcpKey U_ICU_ENTRY_POINT_RENAME(ulocimp_toBcpKey)
     1082#define ulocimp_toBcpType U_ICU_ENTRY_POINT_RENAME(ulocimp_toBcpType)
     1083#define ulocimp_toLegacyKey U_ICU_ENTRY_POINT_RENAME(ulocimp_toLegacyKey)
     1084#define ulocimp_toLegacyType U_ICU_ENTRY_POINT_RENAME(ulocimp_toLegacyType)
     1085#define ultag_isUnicodeLocaleKey U_ICU_ENTRY_POINT_RENAME(ultag_isUnicodeLocaleKey)
     1086#define ultag_isUnicodeLocaleType U_ICU_ENTRY_POINT_RENAME(ultag_isUnicodeLocaleType)
    10961087#define umsg_applyPattern U_ICU_ENTRY_POINT_RENAME(umsg_applyPattern)
    10971088#define umsg_autoQuoteApostrophe U_ICU_ENTRY_POINT_RENAME(umsg_autoQuoteApostrophe)
     
    11061097#define umsg_vformat U_ICU_ENTRY_POINT_RENAME(umsg_vformat)
    11071098#define umsg_vparse U_ICU_ENTRY_POINT_RENAME(umsg_vparse)
     1099#define umtx_condBroadcast U_ICU_ENTRY_POINT_RENAME(umtx_condBroadcast)
     1100#define umtx_condSignal U_ICU_ENTRY_POINT_RENAME(umtx_condSignal)
     1101#define umtx_condWait U_ICU_ENTRY_POINT_RENAME(umtx_condWait)
    11081102#define umtx_lock U_ICU_ENTRY_POINT_RENAME(umtx_lock)
    11091103#define umtx_unlock U_ICU_ENTRY_POINT_RENAME(umtx_unlock)
     
    11311125#define unorm2_spanQuickCheckYes U_ICU_ENTRY_POINT_RENAME(unorm2_spanQuickCheckYes)
    11321126#define unorm2_swap U_ICU_ENTRY_POINT_RENAME(unorm2_swap)
    1133 #define unorm_closeIter U_ICU_ENTRY_POINT_RENAME(unorm_closeIter)
    11341127#define unorm_compare U_ICU_ENTRY_POINT_RENAME(unorm_compare)
    11351128#define unorm_concatenate U_ICU_ENTRY_POINT_RENAME(unorm_concatenate)
     
    11401133#define unorm_next U_ICU_ENTRY_POINT_RENAME(unorm_next)
    11411134#define unorm_normalize U_ICU_ENTRY_POINT_RENAME(unorm_normalize)
    1142 #define unorm_openIter U_ICU_ENTRY_POINT_RENAME(unorm_openIter)
    11431135#define unorm_previous U_ICU_ENTRY_POINT_RENAME(unorm_previous)
    11441136#define unorm_quickCheck U_ICU_ENTRY_POINT_RENAME(unorm_quickCheck)
    11451137#define unorm_quickCheckWithOptions U_ICU_ENTRY_POINT_RENAME(unorm_quickCheckWithOptions)
    1146 #define unorm_setIter U_ICU_ENTRY_POINT_RENAME(unorm_setIter)
    11471138#define unum_applyPattern U_ICU_ENTRY_POINT_RENAME(unum_applyPattern)
    11481139#define unum_clone U_ICU_ENTRY_POINT_RENAME(unum_clone)
     
    11571148#define unum_getAttribute U_ICU_ENTRY_POINT_RENAME(unum_getAttribute)
    11581149#define unum_getAvailable U_ICU_ENTRY_POINT_RENAME(unum_getAvailable)
     1150#define unum_getContext U_ICU_ENTRY_POINT_RENAME(unum_getContext)
    11591151#define unum_getDoubleAttribute U_ICU_ENTRY_POINT_RENAME(unum_getDoubleAttribute)
    11601152#define unum_getLocaleByType U_ICU_ENTRY_POINT_RENAME(unum_getLocaleByType)
     
    11691161#define unum_parseToUFormattable U_ICU_ENTRY_POINT_RENAME(unum_parseToUFormattable)
    11701162#define unum_setAttribute U_ICU_ENTRY_POINT_RENAME(unum_setAttribute)
     1163#define unum_setContext U_ICU_ENTRY_POINT_RENAME(unum_setContext)
    11711164#define unum_setDoubleAttribute U_ICU_ENTRY_POINT_RENAME(unum_setDoubleAttribute)
    11721165#define unum_setSymbol U_ICU_ENTRY_POINT_RENAME(unum_setSymbol)
     
    12151208#define uprv_calloc U_ICU_ENTRY_POINT_RENAME(uprv_calloc)
    12161209#define uprv_ceil U_ICU_ENTRY_POINT_RENAME(uprv_ceil)
    1217 #define uprv_cnttab_addContraction U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_addContraction)
    1218 #define uprv_cnttab_changeContraction U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_changeContraction)
    1219 #define uprv_cnttab_changeLastCE U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_changeLastCE)
    1220 #define uprv_cnttab_clone U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_clone)
    1221 #define uprv_cnttab_close U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_close)
    1222 #define uprv_cnttab_constructTable U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_constructTable)
    1223 #define uprv_cnttab_findCE U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_findCE)
    1224 #define uprv_cnttab_findCP U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_findCP)
    1225 #define uprv_cnttab_getCE U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_getCE)
    1226 #define uprv_cnttab_insertContraction U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_insertContraction)
    1227 #define uprv_cnttab_isTailored U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_isTailored)
    1228 #define uprv_cnttab_open U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_open)
    1229 #define uprv_cnttab_setContraction U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_setContraction)
    1230 #define uprv_collIterateAtEnd U_ICU_ENTRY_POINT_RENAME(uprv_collIterateAtEnd)
    12311210#define uprv_compareASCIIPropertyNames U_ICU_ENTRY_POINT_RENAME(uprv_compareASCIIPropertyNames)
    12321211#define uprv_compareEBCDICPropertyNames U_ICU_ENTRY_POINT_RENAME(uprv_compareEBCDICPropertyNames)
     
    13151294#define uprv_decNumberXor U_ICU_ENTRY_POINT_RENAME(uprv_decNumberXor)
    13161295#define uprv_decNumberZero U_ICU_ENTRY_POINT_RENAME(uprv_decNumberZero)
     1296#define uprv_deleteConditionalCE32 U_ICU_ENTRY_POINT_RENAME(uprv_deleteConditionalCE32)
    13171297#define uprv_deleteUObject U_ICU_ENTRY_POINT_RENAME(uprv_deleteUObject)
    1318 #define uprv_delete_collIterate U_ICU_ENTRY_POINT_RENAME(uprv_delete_collIterate)
    13191298#define uprv_dl_close U_ICU_ENTRY_POINT_RENAME(uprv_dl_close)
    13201299#define uprv_dl_open U_ICU_ENTRY_POINT_RENAME(uprv_dl_open)
     
    13411320#define uprv_getUTCtime U_ICU_ENTRY_POINT_RENAME(uprv_getUTCtime)
    13421321#define uprv_haveProperties U_ICU_ENTRY_POINT_RENAME(uprv_haveProperties)
    1343 #define uprv_init_collIterate U_ICU_ENTRY_POINT_RENAME(uprv_init_collIterate)
    1344 #define uprv_init_pce U_ICU_ENTRY_POINT_RENAME(uprv_init_pce)
    13451322#define uprv_int32Comparator U_ICU_ENTRY_POINT_RENAME(uprv_int32Comparator)
    13461323#define uprv_isASCIILetter U_ICU_ENTRY_POINT_RENAME(uprv_isASCIILetter)
     
    13601337#define uprv_min U_ICU_ENTRY_POINT_RENAME(uprv_min)
    13611338#define uprv_modf U_ICU_ENTRY_POINT_RENAME(uprv_modf)
    1362 #define uprv_new_collIterate U_ICU_ENTRY_POINT_RENAME(uprv_new_collIterate)
    13631339#define uprv_parseCurrency U_ICU_ENTRY_POINT_RENAME(uprv_parseCurrency)
    13641340#define uprv_pathIsAbsolute U_ICU_ENTRY_POINT_RENAME(uprv_pathIsAbsolute)
     
    13801356#define uprv_tzname U_ICU_ENTRY_POINT_RENAME(uprv_tzname)
    13811357#define uprv_tzset U_ICU_ENTRY_POINT_RENAME(uprv_tzset)
    1382 #define uprv_uca_addAnElement U_ICU_ENTRY_POINT_RENAME(uprv_uca_addAnElement)
    1383 #define uprv_uca_assembleTable U_ICU_ENTRY_POINT_RENAME(uprv_uca_assembleTable)
    1384 #define uprv_uca_canonicalClosure U_ICU_ENTRY_POINT_RENAME(uprv_uca_canonicalClosure)
    1385 #define uprv_uca_closeTempTable U_ICU_ENTRY_POINT_RENAME(uprv_uca_closeTempTable)
    1386 #define uprv_uca_getCodePointFromRaw U_ICU_ENTRY_POINT_RENAME(uprv_uca_getCodePointFromRaw)
    1387 #define uprv_uca_getImplicitFromRaw U_ICU_ENTRY_POINT_RENAME(uprv_uca_getImplicitFromRaw)
    1388 #define uprv_uca_getRawFromCodePoint U_ICU_ENTRY_POINT_RENAME(uprv_uca_getRawFromCodePoint)
    1389 #define uprv_uca_getRawFromImplicit U_ICU_ENTRY_POINT_RENAME(uprv_uca_getRawFromImplicit)
    1390 #define uprv_uca_initImplicitConstants U_ICU_ENTRY_POINT_RENAME(uprv_uca_initImplicitConstants)
    1391 #define uprv_uca_initTempTable U_ICU_ENTRY_POINT_RENAME(uprv_uca_initTempTable)
    13921358#define uprv_uint16Comparator U_ICU_ENTRY_POINT_RENAME(uprv_uint16Comparator)
    13931359#define uprv_uint32Comparator U_ICU_ENTRY_POINT_RENAME(uprv_uint32Comparator)
     
    14231389#define uregex_group U_ICU_ENTRY_POINT_RENAME(uregex_group)
    14241390#define uregex_groupCount U_ICU_ENTRY_POINT_RENAME(uregex_groupCount)
     1391#define uregex_groupNumberFromCName U_ICU_ENTRY_POINT_RENAME(uregex_groupNumberFromCName)
     1392#define uregex_groupNumberFromName U_ICU_ENTRY_POINT_RENAME(uregex_groupNumberFromName)
    14251393#define uregex_groupUText U_ICU_ENTRY_POINT_RENAME(uregex_groupUText)
    1426 #define uregex_groupUTextDeep U_ICU_ENTRY_POINT_RENAME(uregex_groupUTextDeep)
    14271394#define uregex_hasAnchoringBounds U_ICU_ENTRY_POINT_RENAME(uregex_hasAnchoringBounds)
    14281395#define uregex_hasTransparentBounds U_ICU_ENTRY_POINT_RENAME(uregex_hasTransparentBounds)
     
    15191486#define ures_openDirect U_ICU_ENTRY_POINT_RENAME(ures_openDirect)
    15201487#define ures_openFillIn U_ICU_ENTRY_POINT_RENAME(ures_openFillIn)
     1488#define ures_openNoDefault U_ICU_ENTRY_POINT_RENAME(ures_openNoDefault)
    15211489#define ures_openU U_ICU_ENTRY_POINT_RENAME(ures_openU)
    15221490#define ures_resetIterator U_ICU_ENTRY_POINT_RENAME(ures_resetIterator)
     
    17231691#define utrans_getAvailableID U_ICU_ENTRY_POINT_RENAME(utrans_getAvailableID)
    17241692#define utrans_getID U_ICU_ENTRY_POINT_RENAME(utrans_getID)
     1693#define utrans_getSourceSet U_ICU_ENTRY_POINT_RENAME(utrans_getSourceSet)
    17251694#define utrans_getUnicodeID U_ICU_ENTRY_POINT_RENAME(utrans_getUnicodeID)
    17261695#define utrans_open U_ICU_ENTRY_POINT_RENAME(utrans_open)
     
    17321701#define utrans_setFilter U_ICU_ENTRY_POINT_RENAME(utrans_setFilter)
    17331702#define utrans_stripRules U_ICU_ENTRY_POINT_RENAME(utrans_stripRules)
     1703#define utrans_toRules U_ICU_ENTRY_POINT_RENAME(utrans_toRules)
    17341704#define utrans_trans U_ICU_ENTRY_POINT_RENAME(utrans_trans)
    17351705#define utrans_transIncremental U_ICU_ENTRY_POINT_RENAME(utrans_transIncremental)
  • trunk/Source/JavaScriptCore/icu/unicode/uscript.h

    r196492 r215722  
    11/*
    22 **********************************************************************
    3  *   Copyright (C) 1997-2013, International Business Machines
     3 *   Copyright (C) 1997-2015, International Business Machines
    44 *   Corporation and others.  All Rights Reserved.
    55 **********************************************************************
     
    2222 * \brief C API: Unicode Script Information
    2323 */
    24  
     24
    2525/**
    2626 * Constants for ISO 15924 script codes.
    2727 *
    28  * Many of these script codes - those from Unicode's ScriptNames.txt -
    29  * are character property values for Unicode's Script property.
    30  * See UAX #24 Script Names (http://www.unicode.org/reports/tr24/).
     28 * The current set of script code constants supports at least all scripts
     29 * that are encoded in the version of Unicode which ICU currently supports.
     30 * The names of the constants are usually derived from the
     31 * Unicode script property value aliases.
     32 * See UAX #24 Unicode Script Property (http://www.unicode.org/reports/tr24/)
     33 * and http://www.unicode.org/Public/UCD/latest/ucd/PropertyValueAliases.txt .
    3134 *
    3235 * Starting with ICU 3.6, constants for most ISO 15924 script codes
    33  * are included (currently excluding private-use codes Qaaa..Qabx).
    34  * For scripts for which there are codes in ISO 15924 but which are not
    35  * used in the Unicode Character Database (UCD), there are no Unicode characters
    36  * associated with those scripts.
    37  *
    38  * For example, there are no characters that have a UCD script code of
    39  * Hans or Hant. All Han ideographs have the Hani script code.
    40  * The Hans and Hant script codes are used with CLDR data.
    41  *
    42  * ISO 15924 script codes are included for use with CLDR and similar.
     36 * are included, for use with language tags, CLDR data, and similar.
     37 * Some of those codes are not used in the Unicode Character Database (UCD).
     38 * For example, there are no characters that have a UCD script property value of
     39 * Hans or Hant. All Han ideographs have the Hani script property value in Unicode.
     40 *
     41 * Private-use codes Qaaa..Qabx are not included.
     42 *
     43 * Starting with ICU 55, script codes are only added when their scripts
     44 * have been or will certainly be encoded in Unicode,
     45 * and have been assigned Unicode script property value aliases,
     46 * to ensure that their script names are stable and match the names of the constants.
     47 * Script codes like Latf and Aran that are not subject to separate encoding
     48 * may be added at any time.
    4349 *
    4450 * @stable ICU 2.2
     
    187193      USCRIPT_OLD_PERSIAN   = 61, /* Xpeo */
    188194
    189       /* New script codes from ISO 15924 */
     195      /* New script codes from Unicode and ISO 15924 */
    190196      /** @stable ICU 3.6 */
    191197      USCRIPT_BALINESE                      = 62, /* Bali */
     
    279285      USCRIPT_UNKNOWN                       = 103,/* Zzzz */ /* Unknown="Code for uncoded script", for unassigned code points */
    280286
    281       /* New script codes from ISO 15924 */
    282287      /** @stable ICU 3.8 */
    283288      USCRIPT_CARIAN                        = 104,/* Cari */
     
    305310      USCRIPT_MEITEI_MAYEK                  = 115,/* Mtei */
    306311
    307       /* New script codes from ISO 15924 */
    308312      /** @stable ICU 4.0 */
    309313      USCRIPT_IMPERIAL_ARAMAIC              = 116,/* Armi */
     
    335339      USCRIPT_SYMBOLS                       = 129,/* Zsym */
    336340
    337       /* New script codes from ISO 15924 */
    338341      /** @stable ICU 4.4 */
    339342      USCRIPT_BAMUM                         = 130,/* Bamu */
     
    345348      USCRIPT_OLD_SOUTH_ARABIAN             = 133,/* Sarb */
    346349
    347       /* New script codes from ISO 15924 */
    348350      /** @stable ICU 4.6 */
    349351      USCRIPT_BASSA_VAH                     = 134,/* Bass */
    350       /** @stable ICU 4.6 */
    351       USCRIPT_DUPLOYAN_SHORTAND             = 135,/* Dupl */
     352      /** @stable ICU 54 */
     353      USCRIPT_DUPLOYAN                      = 135,/* Dupl */
     354#ifndef U_HIDE_DEPRECATED_API
     355      /** @deprecated ICU 54 Typo, use USCRIPT_DUPLOYAN */
     356      USCRIPT_DUPLOYAN_SHORTAND             = USCRIPT_DUPLOYAN,
     357#endif  /* U_HIDE_DEPRECATED_API */
    352358      /** @stable ICU 4.6 */
    353359      USCRIPT_ELBASAN                       = 136,/* Elba */
     
    358364      /** @stable ICU 4.6 */
    359365      USCRIPT_LOMA                          = 139,/* Loma */
    360       /** @stable ICU 4.6 */
     366      /** Mende Kikakui @stable ICU 4.6 */
    361367      USCRIPT_MENDE                         = 140,/* Mend */
    362368      /** @stable ICU 4.6 */
     
    368374      /** @stable ICU 4.6 */
    369375      USCRIPT_PALMYRENE                     = 144,/* Palm */
    370       /** @stable ICU 4.6 */
    371       USCRIPT_SINDHI                        = 145,/* Sind */
     376      /** @stable ICU 54 */
     377      USCRIPT_KHUDAWADI                     = 145,/* Sind */
     378      /** @stable ICU 4.6 */
     379      USCRIPT_SINDHI                        = USCRIPT_KHUDAWADI,
    372380      /** @stable ICU 4.6 */
    373381      USCRIPT_WARANG_CITI                   = 146,/* Wara */
     
    404412      USCRIPT_MAHAJANI                      = 160,/* Mahj */
    405413
    406       /* Private use codes from Qaaa - Qabx are not supported */
    407 
    408       /** @stable ICU 2.2 */
    409       USCRIPT_CODE_LIMIT    = 161
     414      /** @stable ICU 54 */
     415      USCRIPT_AHOM                          = 161,/* Ahom */
     416      /** @stable ICU 54 */
     417      USCRIPT_HATRAN                        = 162,/* Hatr */
     418      /** @stable ICU 54 */
     419      USCRIPT_MODI                          = 163,/* Modi */
     420      /** @stable ICU 54 */
     421      USCRIPT_MULTANI                       = 164,/* Mult */
     422      /** @stable ICU 54 */
     423      USCRIPT_PAU_CIN_HAU                   = 165,/* Pauc */
     424      /** @stable ICU 54 */
     425      USCRIPT_SIDDHAM                       = 166,/* Sidd */
     426
     427      /**
     428       * One higher than the last script code constant.
     429       * This value increases as constants for script codes are added.
     430       *
     431       * There are constants for Unicode 7 script property values.
     432       * There are constants for ISO 15924 script codes assigned on or before 2013-10-12.
     433       * There are no constants for private use codes from Qaaa - Qabx
     434       * except as used in the UCD.
     435       *
     436       * @stable ICU 2.2
     437       */
     438      USCRIPT_CODE_LIMIT    = 167
    410439} UScriptCode;
    411440
    412441/**
    413  * Gets script codes associated with the given locale or ISO 15924 abbreviation or name.
     442 * Gets the script codes associated with the given locale or ISO 15924 abbreviation or name.
    414443 * Fills in USCRIPT_MALAYALAM given "Malayam" OR "Mlym".
    415444 * Fills in USCRIPT_LATIN given "en" OR "en_US"
    416  * If required capacity is greater than capacity of the destination buffer then the error code
    417  * is set to U_BUFFER_OVERFLOW_ERROR and the required capacity is returned
     445 * If the required capacity is greater than the capacity of the destination buffer,
     446 * then the error code is set to U_BUFFER_OVERFLOW_ERROR and the required capacity is returned.
    418447 *
    419448 * <p>Note: To search by short or long script alias only, use
    420  * u_getPropertyValueEnum(UCHAR_SCRIPT, alias) instead.  This does
     449 * u_getPropertyValueEnum(UCHAR_SCRIPT, alias) instead.  That does
    421450 * a fast lookup with no access of the locale data.
     451 *
    422452 * @param nameOrAbbrOrLocale name of the script, as given in
    423453 * PropertyValueAliases.txt, or ISO 15924 code or locale
     
    432462
    433463/**
    434  * Gets a script name associated with the given script code.
    435  * Returns  "Malayam" given USCRIPT_MALAYALAM
     464 * Returns the long Unicode script name, if there is one.
     465 * Otherwise returns the 4-letter ISO 15924 script code.
     466 * Returns "Malayam" given USCRIPT_MALAYALAM.
     467 *
    436468 * @param scriptCode UScriptCode enum
    437  * @return script long name as given in
    438  * PropertyValueAliases.txt, or NULL if scriptCode is invalid
     469 * @return long script name as given in PropertyValueAliases.txt, or the 4-letter code,
     470 * or NULL if scriptCode is invalid
    439471 * @stable ICU 2.4
    440472 */
     
    443475
    444476/**
    445  * Gets a script name associated with the given script code.
    446  * Returns  "Mlym" given USCRIPT_MALAYALAM
     477 * Returns the 4-letter ISO 15924 script code,
     478 * which is the same as the short Unicode script name if Unicode has names for the script.
     479 * Returns "Mlym" given USCRIPT_MALAYALAM.
     480 *
    447481 * @param scriptCode UScriptCode enum
    448  * @return script abbreviated name as given in
    449  * PropertyValueAliases.txt, or NULL if scriptCode is invalid
     482 * @return short script name (4-letter code), or NULL if scriptCode is invalid
    450483 * @stable ICU 2.4
    451484 */
     
    518551                            UErrorCode *errorCode);
    519552
    520 #ifndef U_HIDE_DRAFT_API
    521 
    522553/**
    523554 * Script usage constants.
     
    525556 * http://www.unicode.org/reports/tr31/#Table_Candidate_Characters_for_Exclusion_from_Identifiers
    526557 *
    527  * @draft ICU 51
     558 * @stable ICU 51
    528559 */
    529560typedef enum UScriptUsage {
    530     /** Not encoded in Unicode. @draft ICU 51 */
     561    /** Not encoded in Unicode. @stable ICU 51 */
    531562    USCRIPT_USAGE_NOT_ENCODED,
    532     /** Unknown script usage. @draft ICU 51 */
     563    /** Unknown script usage. @stable ICU 51 */
    533564    USCRIPT_USAGE_UNKNOWN,
    534     /** Candidate for Exclusion from Identifiers. @draft ICU 51 */
     565    /** Candidate for Exclusion from Identifiers. @stable ICU 51 */
    535566    USCRIPT_USAGE_EXCLUDED,
    536     /** Limited Use script. @draft ICU 51 */
     567    /** Limited Use script. @stable ICU 51 */
    537568    USCRIPT_USAGE_LIMITED_USE,
    538     /** Aspirational Use script. @draft ICU 51 */
     569    /** Aspirational Use script. @stable ICU 51 */
    539570    USCRIPT_USAGE_ASPIRATIONAL,
    540     /** Recommended script. @draft ICU 51 */
     571    /** Recommended script. @stable ICU 51 */
    541572    USCRIPT_USAGE_RECOMMENDED
    542573} UScriptUsage;
     
    552583 * @param pErrorCode standard ICU in/out error code, must pass U_SUCCESS() on input
    553584 * @return the string length, even if U_BUFFER_OVERFLOW_ERROR
    554  * @draft ICU 51
    555  */
    556 U_DRAFT int32_t U_EXPORT2
     585 * @stable ICU 51
     586 */
     587U_STABLE int32_t U_EXPORT2
    557588uscript_getSampleString(UScriptCode script, UChar *dest, int32_t capacity, UErrorCode *pErrorCode);
    558589
     
    570601 * @param script script code
    571602 * @return the sample character string
    572  * @draft ICU 51
     603 * @stable ICU 51
    573604 */
    574605U_COMMON_API icu::UnicodeString U_EXPORT2
     
    584615 * @return script usage
    585616 * @see UScriptUsage
    586  * @draft ICU 51
    587  */
    588 U_DRAFT UScriptUsage U_EXPORT2
     617 * @stable ICU 51
     618 */
     619U_STABLE UScriptUsage U_EXPORT2
    589620uscript_getUsage(UScriptCode script);
    590621
     
    595626 * @param script script code
    596627 * @return TRUE if the script is right-to-left
    597  * @draft ICU 51
    598  */
    599 U_DRAFT UBool U_EXPORT2
     628 * @stable ICU 51
     629 */
     630U_STABLE UBool U_EXPORT2
    600631uscript_isRightToLeft(UScriptCode script);
    601632
     
    607638 * @param script script code
    608639 * @return TRUE if the script allows line breaks between letters
    609  * @draft ICU 51
    610  */
    611 U_DRAFT UBool U_EXPORT2
     640 * @stable ICU 51
     641 */
     642U_STABLE UBool U_EXPORT2
    612643uscript_breaksBetweenLetters(UScriptCode script);
    613644
     
    618649 * @param script script code
    619650 * @return TRUE if the script is cased
    620  * @draft ICU 51
    621  */
    622 U_DRAFT UBool U_EXPORT2
     651 * @stable ICU 51
     652 */
     653U_STABLE UBool U_EXPORT2
    623654uscript_isCased(UScriptCode script);
    624655
    625 #endif  /* U_HIDE_DRAFT_API */
    626 
    627656#endif
  • trunk/Source/JavaScriptCore/icu/unicode/uset.h

    r196492 r215722  
    22*******************************************************************************
    33*
    4 *   Copyright (C) 2002-2012, International Business Machines
     4*   Copyright (C) 2002-2014, International Business Machines
    55*   Corporation and others.  All Rights Reserved.
    66*
     
    9999 * The functionality is straightforward for sets with only single code points,
    100100 * without strings (which is the common case):
    101  * - USET_SPAN_CONTAINED and USET_SPAN_SIMPLE
    102  *   work the same.
     101 * - USET_SPAN_CONTAINED and USET_SPAN_SIMPLE work the same.
     102 * - USET_SPAN_CONTAINED and USET_SPAN_SIMPLE are inverses of USET_SPAN_NOT_CONTAINED.
    103103 * - span() and spanBack() partition any string the same way when
    104104 *   alternating between span(USET_SPAN_NOT_CONTAINED) and
     
    150150typedef enum USetSpanCondition {
    151151    /**
    152      * Continue a span() while there is no set element at the current position.
     152     * Continues a span() while there is no set element at the current position.
     153     * Increments by one code point at a time.
    153154     * Stops before the first set element (character or string).
    154155     * (For code points only, this is like while contains(current)==FALSE).
     
    162163    USET_SPAN_NOT_CONTAINED = 0,
    163164    /**
    164      * Continue a span() while there is a set element at the current position.
     165     * Spans the longest substring that is a concatenation of set elements (characters or strings).
    165166     * (For characters only, this is like while contains(current)==TRUE).
    166167     *
     
    168169     * it returned consists only of set elements (characters or strings) that are in the set.
    169170     *
    170      * If a set contains strings, then the span will be the longest substring
    171      * matching any of the possible concatenations of set elements (characters or strings).
    172      * (There must be a single, non-overlapping concatenation of characters or strings.)
    173      * This is equivalent to a POSIX regular expression for (OR of each set element)*.
     171     * If a set contains strings, then the span will be the longest substring for which there
     172     * exists at least one non-overlapping concatenation of set elements (characters or strings).
     173     * This is equivalent to a POSIX regular expression for <code>(OR of each set element)*</code>.
     174     * (Java/ICU/Perl regex stops at the first match of an OR.)
    174175     *
    175176     * @stable ICU 3.8
     
    177178    USET_SPAN_CONTAINED = 1,
    178179    /**
    179      * Continue a span() while there is a set element at the current position.
     180     * Continues a span() while there is a set element at the current position.
     181     * Increments by the longest matching element at each position.
    180182     * (For characters only, this is like while contains(current)==TRUE).
    181183     *
  • trunk/Source/JavaScriptCore/icu/unicode/ustring.h

    r196492 r215722  
    11/*
    22**********************************************************************
    3 *   Copyright (C) 1998-2012, International Business Machines
     3*   Copyright (C) 1998-2014, International Business Machines
    44*   Corporation and others.  All Rights Reserved.
    55**********************************************************************
     
    13121312/**
    13131313 * Convert a UTF-16 string to UTF-8.
    1314  * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set.
    13151314 *
    13161315 * Same as u_strToUTF8() except for the additional subchar which is output for
     
    13571356/**
    13581357 * Convert a UTF-8 string to UTF-16.
    1359  * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set.
    13601358 *
    13611359 * Same as u_strFromUTF8() except for the additional subchar which is output for
     
    15221520/**
    15231521 * Convert a UTF-16 string to UTF-32.
    1524  * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set.
    15251522 *
    15261523 * Same as u_strToUTF32() except for the additional subchar which is output for
     
    15671564/**
    15681565 * Convert a UTF-32 string to UTF-16.
    1569  * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set.
    15701566 *
    15711567 * Same as u_strFromUTF32() except for the additional subchar which is output for
     
    16531649/**
    16541650 * Convert a Java Modified UTF-8 string to a 16-bit Unicode string.
    1655  * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set.
     1651 * If the input string is not well-formed and no substitution char is specified,
     1652 * then the U_INVALID_CHAR_FOUND error code is set.
    16561653 *
    16571654 * This function behaves according to the documentation for Java DataInput.readUTF()
  • trunk/Source/JavaScriptCore/icu/unicode/utf8.h

    r196492 r215722  
    22*******************************************************************************
    33*
    4 *   Copyright (C) 1999-2013, International Business Machines
     4*   Copyright (C) 1999-2014, International Business Machines
    55*   Corporation and others.  All Rights Reserved.
    66*
     
    7979 */
    8080#define U8_COUNT_TRAIL_BYTES(leadByte) \
    81     ((leadByte)<0xf0 ? \
    82         ((leadByte)>=0xc0)+((leadByte)>=0xe0) : \
    83         (leadByte)<0xfe ? 3+((leadByte)>=0xf8)+((leadByte)>=0xfc) : 0)
     81    ((uint8_t)(leadByte)<0xf0 ? \
     82        ((uint8_t)(leadByte)>=0xc0)+((uint8_t)(leadByte)>=0xe0) : \
     83        (uint8_t)(leadByte)<0xfe ? 3+((uint8_t)(leadByte)>=0xf8)+((uint8_t)(leadByte)>=0xfc) : 0)
    8484
    8585/**
     
    254254}
    255255
    256 #ifndef U_HIDE_DRAFT_API
    257256/**
    258257 * Get a code point from a string at a random-access offset,
     
    278277 * @param c output UChar32 variable, set to U+FFFD in case of an error
    279278 * @see U8_GET
    280  * @draft ICU 51
     279 * @stable ICU 51
    281280 */
    282281#define U8_GET_OR_FFFD(s, start, i, length, c) { \
     
    285284    U8_NEXT_OR_FFFD(s, _u8_get_index, length, c); \
    286285}
    287 #endif /* U_HIDE_DRAFT_API */
    288286
    289287/* definitions with forward iteration --------------------------------------- */
     
    369367}
    370368
    371 #ifndef U_HIDE_DRAFT_API
    372369/**
    373370 * Get a code point from a string at a code point boundary offset,
     
    392389 * @param c output UChar32 variable, set to U+FFFD in case of an error
    393390 * @see U8_NEXT
    394  * @draft ICU 51
     391 * @stable ICU 51
    395392 */
    396393#define U8_NEXT_OR_FFFD(s, i, length, c) { \
     
    420417    } \
    421418}
    422 #endif /* U_HIDE_DRAFT_API */
    423419
    424420/**
     
    677673}
    678674
    679 #ifndef U_HIDE_DRAFT_API
    680675/**
    681676 * Move the string offset from one code point boundary to the previous one
     
    700695 * @param c output UChar32 variable, set to U+FFFD in case of an error
    701696 * @see U8_PREV
    702  * @draft ICU 51
     697 * @stable ICU 51
    703698 */
    704699#define U8_PREV_OR_FFFD(s, start, i, c) { \
     
    708703    } \
    709704}
    710 #endif /* U_HIDE_DRAFT_API */
    711705
    712706/**
  • trunk/Source/JavaScriptCore/icu/unicode/utypes.h

    r196492 r215722  
    11/*
    22**********************************************************************
    3 *   Copyright (C) 1996-2012, International Business Machines
     3*   Copyright (C) 1996-2015, International Business Machines
    44*   Corporation and others.  All Rights Reserved.
    55**********************************************************************
     
    642642    U_REGEX_LOOK_BEHIND_LIMIT,            /**< Look-Behind pattern matches must have a bounded maximum length.    */
    643643    U_REGEX_SET_CONTAINS_STRING,          /**< Regexps cannot have UnicodeSets containing strings.*/
    644     U_REGEX_OCTAL_TOO_BIG,                /**< Octal character constants must be <= 0377.         */
    645     U_REGEX_MISSING_CLOSE_BRACKET,        /**< Missing closing bracket on a bracket expression.   */
     644#ifndef U_HIDE_DEPRECATED_API
     645    U_REGEX_OCTAL_TOO_BIG,                /**< Octal character constants must be <= 0377. @deprecated ICU 54. This error cannot occur. */
     646#endif  /* U_HIDE_DEPRECATED_API */
     647    U_REGEX_MISSING_CLOSE_BRACKET=U_REGEX_SET_CONTAINS_STRING+2, /**< Missing closing bracket on a bracket expression. */
    646648    U_REGEX_INVALID_RANGE,                /**< In a character range [x-y], x is greater than y.   */
    647649    U_REGEX_STACK_OVERFLOW,               /**< Regular expression backtrack stack overflow.       */
    648650    U_REGEX_TIME_OUT,                     /**< Maximum allowed match time exceeded                */
    649651    U_REGEX_STOPPED_BY_CALLER,            /**< Matching operation aborted by user callback fn.    */
    650     U_REGEX_ERROR_LIMIT,                  /**< This must always be the last value to indicate the limit for regexp errors */
     652#ifndef U_HIDE_DRAFT_API
     653    U_REGEX_PATTERN_TOO_BIG,              /**< Pattern exceeds limits on size or complexity. @draft ICU 55 */
     654    U_REGEX_INVALID_CAPTURE_GROUP_NAME,   /**< Invalid capture group name. @draft ICU 55 */
     655#endif  /* U_HIDE_DRAFT_API */
     656    U_REGEX_ERROR_LIMIT=U_REGEX_STOPPED_BY_CALLER+3, /**< This must always be the last value to indicate the limit for regexp errors */
    651657
    652658    /*
Note: See TracChangeset for help on using the changeset viewer.