dcfmtsym.h   dcfmtsym.h 
skipping to change at line 29 skipping to change at line 29
* 06/24/99 helena Integrated Alan's NF enhancements and Java2 bug fixes * 06/24/99 helena Integrated Alan's NF enhancements and Java2 bug fixes
* 09/22/00 grhoten Marked deprecation tags with a pointer to repla cement * 09/22/00 grhoten Marked deprecation tags with a pointer to repla cement
* functions. * functions.
*************************************************************************** ***** *************************************************************************** *****
*/ */
#ifndef DCFMTSYM_H #ifndef DCFMTSYM_H
#define DCFMTSYM_H #define DCFMTSYM_H
#include "unicode/utypes.h" #include "unicode/utypes.h"
#include "unicode/uchar.h"
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
#include "unicode/uobject.h" #include "unicode/uobject.h"
#include "unicode/locid.h" #include "unicode/locid.h"
/** /**
* \file * \file
* \brief C++ API: Symbols for formatting numbers. * \brief C++ API: Symbols for formatting numbers.
*/ */
skipping to change at line 127 skipping to change at line 128
kInfinitySymbol, kInfinitySymbol,
/** Nan symbol */ /** Nan symbol */
kNaNSymbol, kNaNSymbol,
/** Significant digit symbol /** Significant digit symbol
* @stable ICU 3.0 */ * @stable ICU 3.0 */
kSignificantDigitSymbol, kSignificantDigitSymbol,
/** The monetary grouping separator /** The monetary grouping separator
* @stable ICU 3.6 * @stable ICU 3.6
*/ */
kMonetaryGroupingSeparatorSymbol, kMonetaryGroupingSeparatorSymbol,
/** One
* @draft ICU 4.6
*/
kOneDigitSymbol,
/** Two
* @draft ICU 4.6
*/
kTwoDigitSymbol,
/** Three
* @draft ICU 4.6
*/
kThreeDigitSymbol,
/** Four
* @draft ICU 4.6
*/
kFourDigitSymbol,
/** Five
* @draft ICU 4.6
*/
kFiveDigitSymbol,
/** Six
* @draft ICU 4.6
*/
kSixDigitSymbol,
/** Seven
* @draft ICU 4.6
*/
kSevenDigitSymbol,
/** Eight
* @draft ICU 4.6
*/
kEightDigitSymbol,
/** Nine
* @draft ICU 4.6
*/
kNineDigitSymbol,
/** count symbol constants */ /** count symbol constants */
kFormatSymbolCount kFormatSymbolCount
}; };
/** /**
* Constants for specifying currency spacing * Constants for specifying currency spacing
* @draft ICU 4.2 * @draft ICU 4.2
*/ */
enum ECurrencySpacing { enum ECurrencySpacing {
kCurrencyMatch, kCurrencyMatch,
skipping to change at line 218 skipping to change at line 255
*/ */
inline UnicodeString getSymbol(ENumberFormatSymbol symbol) const; inline UnicodeString getSymbol(ENumberFormatSymbol symbol) const;
/** /**
* Set one of the format symbols by its enum constant. * Set one of the format symbols by its enum constant.
* Each symbol is stored as a string so that graphemes * Each symbol is stored as a string so that graphemes
* (characters with modifier letters) can be used. * (characters with modifier letters) can be used.
* *
* @param symbol Constant to indicate a number format symbol. * @param symbol Constant to indicate a number format symbol.
* @param value value of the format symbol * @param value value of the format symbol
* @param propogateDigits If false, setting the zero digit will not aut
omatically set 1-9.
* The default behavior is to automatically set 1-9 if zero is bein
g set and the value
* it is being set to corresponds to a known Unicode zero digit.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
void setSymbol(ENumberFormatSymbol symbol, const UnicodeString &value); void setSymbol(ENumberFormatSymbol symbol, const UnicodeString &value, const UBool propogateDigits);
/** /**
* Returns the locale for which this object was constructed. * Returns the locale for which this object was constructed.
* @stable ICU 2.6 * @stable ICU 2.6
*/ */
inline Locale getLocale() const; inline Locale getLocale() const;
/** /**
* Returns the locale for this object. Two flavors are available: * Returns the locale for this object. Two flavors are available:
* valid and actual locale. * valid and actual locale.
skipping to change at line 295 skipping to change at line 335
/** /**
* Initializes the symbols from the LocaleElements resource bundle. * Initializes the symbols from the LocaleElements resource bundle.
* Note: The organization of LocaleElements badly needs to be * Note: The organization of LocaleElements badly needs to be
* cleaned up. * cleaned up.
* *
* @param locale The locale to get symbols for. * @param locale The locale to get symbols for.
* @param success Input/output parameter, set to success o r * @param success Input/output parameter, set to success o r
* failure code upon return. * failure code upon return.
* @param useLastResortData determine if use last resort data * @param useLastResortData determine if use last resort data
*/ */
void initialize(const Locale& locale, UErrorCode& success); void initialize(const Locale& locale, UErrorCode& success, UBool useLas tResortData = FALSE);
/** /**
* Initialize the symbols with default values. * Initialize the symbols with default values.
*/ */
void initialize(); void initialize();
void setCurrencyForSymbols(); void setCurrencyForSymbols();
public: public:
/** /**
skipping to change at line 385 skipping to change at line 425
strPtr = &fSymbols[symbol]; strPtr = &fSymbols[symbol];
} else { } else {
strPtr = &fNoSymbol; strPtr = &fNoSymbol;
} }
return *strPtr; return *strPtr;
} }
// ------------------------------------- // -------------------------------------
inline void inline void
DecimalFormatSymbols::setSymbol(ENumberFormatSymbol symbol, const UnicodeSt ring &value) { DecimalFormatSymbols::setSymbol(ENumberFormatSymbol symbol, const UnicodeSt ring &value, const UBool propogateDigits = TRUE) {
if(symbol<kFormatSymbolCount) { if(symbol<kFormatSymbolCount) {
fSymbols[symbol]=value; fSymbols[symbol]=value;
} }
// If the zero digit is being set to a known zero digit according to Un
icode,
// then we automatically set the corresponding 1-9 digits
if ( propogateDigits && symbol == kZeroDigitSymbol && value.countChar32
() == 1 ) {
UChar32 sym = value.char32At(0);
if ( u_charDigitValue(sym) == 0 ) {
for ( int8_t i = 1 ; i<= 9 ; i++ ) {
sym++;
fSymbols[(int)kOneDigitSymbol+i-1] = UnicodeString(sym);
}
}
}
} }
// ------------------------------------- // -------------------------------------
inline Locale inline Locale
DecimalFormatSymbols::getLocale() const { DecimalFormatSymbols::getLocale() const {
return locale; return locale;
} }
inline const UChar* inline const UChar*
 End of changes. 7 change blocks. 
3 lines changed or deleted 59 lines changed or added


 format.h   format.h 
skipping to change at line 281 skipping to change at line 281
*/ */
virtual void setLenient(UBool lenient); virtual void setLenient(UBool lenient);
/** /**
* Returns the status of lenient parse mode. At the Format class level, * Returns the status of lenient parse mode. At the Format class level,
* lenient parse is on by default. Format subclasses may have different * lenient parse is on by default. Format subclasses may have different
* default behavior for lenient parse. * default behavior for lenient parse.
* *
* @see #setLenient * @see #setLenient
* @return Lenient parse mode status: TRUE if on, FALSE if off. * @return Lenient parse mode status: TRUE if on, FALSE if off.
* @stable ICU 2.0 * @draft ICU 4.6
*/ */
virtual UBool isLenient(void) const; virtual UBool isLenient(void) const;
protected: protected:
/** @stable ICU 2.8 */ /** @stable ICU 2.8 */
void setLocaleIDs(const char* valid, const char* actual); void setLocaleIDs(const char* valid, const char* actual);
protected: protected:
/** /**
* Default constructor for subclass use only. Does nothing. * Default constructor for subclass use only. Does nothing.
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added


 idna.h   idna.h 
skipping to change at line 54 skipping to change at line 54
* The uidna.h C API implements both UTS #46 (functions using UIDNA service object) * The uidna.h C API implements both UTS #46 (functions using UIDNA service object)
* and IDNA2003 (functions that do not use a service object). * and IDNA2003 (functions that do not use a service object).
* @draft ICU 4.6 * @draft ICU 4.6
*/ */
class U_COMMON_API IDNA : public UObject { class U_COMMON_API IDNA : public UObject {
public: public:
/** /**
* Returns an IDNA instance which implements UTS #46. * Returns an IDNA instance which implements UTS #46.
* Returns an unmodifiable instance, owned by the caller. * Returns an unmodifiable instance, owned by the caller.
* Cache it for multiple operations, and delete it when done. * Cache it for multiple operations, and delete it when done.
* The instance is thread-safe, that is, it can be used concurrently.
* *
* UTS #46 defines Unicode IDNA Compatibility Processing, * UTS #46 defines Unicode IDNA Compatibility Processing,
* updated to the latest version of Unicode and compatible with both * updated to the latest version of Unicode and compatible with both
* IDNA2003 and IDNA2008. * IDNA2003 and IDNA2008.
* *
* The worker functions use transitional processing, including deviatio n mappings, * The worker functions use transitional processing, including deviatio n mappings,
* unless UIDNA_NONTRANSITIONAL_TO_ASCII or UIDNA_NONTRANSITIONAL_TO_UN ICODE * unless UIDNA_NONTRANSITIONAL_TO_ASCII or UIDNA_NONTRANSITIONAL_TO_UN ICODE
* is used in which case the deviation characters are passed through wi thout change. * is used in which case the deviation characters are passed through wi thout change.
* *
* Disallowed characters are mapped to U+FFFD. * Disallowed characters are mapped to U+FFFD.
skipping to change at line 112 skipping to change at line 113
* @return dest * @return dest
* @draft ICU 4.6 * @draft ICU 4.6
*/ */
virtual UnicodeString & virtual UnicodeString &
labelToASCII(const UnicodeString &label, UnicodeString &dest, labelToASCII(const UnicodeString &label, UnicodeString &dest,
IDNAInfo &info, UErrorCode &errorCode) const = 0; IDNAInfo &info, UErrorCode &errorCode) const = 0;
/** /**
* Converts a single domain name label into its Unicode form for human- readable display. * Converts a single domain name label into its Unicode form for human- readable display.
* If any processing step fails, then info.hasErrors() will be TRUE. * If any processing step fails, then info.hasErrors() will be TRUE.
* The domain name might be modified according to the types of errors. * The label might be modified according to the types of errors.
* *
* The UErrorCode indicates an error only in exceptional cases, * The UErrorCode indicates an error only in exceptional cases,
* such as a U_MEMORY_ALLOCATION_ERROR. * such as a U_MEMORY_ALLOCATION_ERROR.
* *
* @param label Input domain name label * @param label Input domain name label
* @param dest Destination string object * @param dest Destination string object
* @param info Output container of IDNA processing details. * @param info Output container of IDNA processing details.
* @param errorCode Standard ICU error code. Its input value must * @param errorCode Standard ICU error code. Its input value must
* pass the U_SUCCESS() test, or else the function ret urns * pass the U_SUCCESS() test, or else the function ret urns
* immediately. Check for U_FAILURE() on output or use with * immediately. Check for U_FAILURE() on output or use with
 End of changes. 2 change blocks. 
1 lines changed or deleted 2 lines changed or added


 msgfmt.h   msgfmt.h 
skipping to change at line 262 skipping to change at line 262
* </dl> * </dl>
* <P> * <P>
* The argumentIndex is a non-negative integer, which corresponds to the * The argumentIndex is a non-negative integer, which corresponds to the
* index of the arguments presented in an array to be formatted. The * index of the arguments presented in an array to be formatted. The
* first argument has argumentIndex 0. * first argument has argumentIndex 0.
* <P> * <P>
* It is acceptable to have unused arguments in the array. With missing * It is acceptable to have unused arguments in the array. With missing
* arguments, or arguments that are not of the right class for the * arguments, or arguments that are not of the right class for the
* specified format, a failing UErrorCode result is set. * specified format, a failing UErrorCode result is set.
* <P> * <P>
* For more sophisticated patterns, you can use a ChoiceFormat to get * <strong>Creating internationalized messages that include plural forms, y
* output: ou
* can use a PluralFormat:</strong>
* <pre> * <pre>
* \code * \code
* UErrorCode success = U_ZERO_ERROR; * UErrorCode err = U_ZERO_ERROR;
* MessageFormat* form("The disk \"{1}\" contains {0}.", success); * UnicodeString t1("{0, plural, one{C''est # fichier} other{Ce sont # fic
* double filelimits[] = {0,1,2}; hiers}} dans la liste.");
* UnicodeString filepart[] = {"no files","one file","{0,number} files" * MessageFormat* msgFmt = new MessageFormat(t1, Locale("fr"), err);
}; * if (U_FAILURE(err)) {
* ChoiceFormat* fileform = new ChoiceFormat(filelimits, filepart, 3); * return err;
* form.setFormat(1, *fileform); // NOT zero, see below * }
*
* Formattable testArgs[] = {1273L, "MyDisk"};
*
* UnicodeString string;
* FieldPosition fpos = 0;
* cout << form.format(testArgs, 2, string, fpos, success) << endl;
* *
* // output, with different testArgs * Formattable args1[] = {(int32_t)0};
* // output: The disk "MyDisk" contains no files. * Formattable args2[] = {(int32_t)3};
* // output: The disk "MyDisk" contains one file. * FieldPosition ignore(FieldPosition::DONT_CARE);
* // output: The disk "MyDisk" contains 1,273 files. * UnicodeString result;
* \endcode * msgFmt->format(args1, 1, result, ignore, status);
* </pre> * cout << result << endl;
* You can either do this programmatically, as in the above example, * result.remove();
* or by using a pattern (see ChoiceFormat for more information) as in: * msgFmt->format(args2, 1, result, ignore, status);
* <pre> * cout << result << endl;
* \code
* form.applyPattern(
* "There {0,choice,0#are no files|1#is one file|1<are {0,number,integ
er} files}.");
* \endcode
* </pre>
* <P>
* <EM>Note:</EM> As we see above, the string produced by a ChoiceFormat in
* MessageFormat is treated specially; occurences of '{' are used to
* indicated subformats, and cause recursion. If you create both a
* MessageFormat and ChoiceFormat programmatically (instead of using
* the string patterns), then be careful not to produce a format that
* recurses on itself, which will cause an infinite loop.
* <P>
* <EM>Note:</EM> Subformats are numbered by their order in the pattern.
* This is <EM>not</EM> the same as the argumentIndex.
* <pre>
* \code
* For example: with "abc{2}def{3}ghi{0}...",
* *
* format0 affects the first variable {2} * // output, with different args
* format1 affects the second variable {3} * // output: C'est 0,0 fichier dans la liste.
* format2 affects the second variable {0} * // output: Ce sont 3 fichiers dans la liste."
* \endcode * \endcode
* </pre> * </pre>
* * Please check PluralFormat and PluralRules for details.
* <p><em>User subclasses are not supported.</em> While clients may write * </P>
* subclasses, such code will not necessarily work and will not be
* guaranteed to work stably from release to release.
*/ */
class U_I18N_API MessageFormat : public Format { class U_I18N_API MessageFormat : public Format {
public: public:
/** /**
* Enum type for kMaxFormat. * Enum type for kMaxFormat.
* @obsolete ICU 3.0. The 10-argument limit was removed as of ICU 2.6, * @obsolete ICU 3.0. The 10-argument limit was removed as of ICU 2.6,
* rendering this enum type obsolete. * rendering this enum type obsolete.
*/ */
enum EFormatNumber { enum EFormatNumber {
/** /**
 End of changes. 5 change blocks. 
50 lines changed or deleted 24 lines changed or added


 plurfmt.h   plurfmt.h 
skipping to change at line 69 skipping to change at line 69
* into two parts: * into two parts:
* <ul> * <ul>
* <li>It uses <code>PluralRules</code> that can define more complex * <li>It uses <code>PluralRules</code> that can define more complex
* conditions for a plural case than just a single interval. These plur al * conditions for a plural case than just a single interval. These plur al
* rules define both what plural cases exist in a language, and to * rules define both what plural cases exist in a language, and to
* which numbers these cases apply. * which numbers these cases apply.
* <li>It provides predefined plural rules for many locales. Thus, the prog rammer * <li>It provides predefined plural rules for many locales. Thus, the prog rammer
* need not worry about the plural cases of a language. On the flip sid e, * need not worry about the plural cases of a language. On the flip sid e,
* the localizer does not have to specify the plural cases; he can simp ly * the localizer does not have to specify the plural cases; he can simp ly
* use the predefined keywords. The whole plural formatting of messages can * use the predefined keywords. The whole plural formatting of messages can
* be done using localized patterns from resource bundles. * be done using localized patterns from resource bundles. For predefin
ed plural
* rules, see CLDR <i>Language Plural Rules</i> page at
* http://unicode.org/repos/cldr-tmp/trunk/diff/supplemental/language_pl
ural_rules.html
* </ul> * </ul>
* </p> * </p>
* <h4>Usage of <code>PluralFormat</code></h4> * <h4>Usage of <code>PluralFormat</code></h4>
* <p> * <p>
* This discussion assumes that you use <code>PluralFormat</code> with * This discussion assumes that you use <code>PluralFormat</code> with
* a predefined set of plural rules. You can create one using one of * a predefined set of plural rules. You can create one using one of
* the constructors that takes a <code>locale</code> object. To * the constructors that takes a <code>locale</code> object. To
* specify the message pattern, you can either pass it to the * specify the message pattern, you can either pass it to the
* constructor or set it explicitly using the * constructor or set it explicitly using the
* <code>applyPattern()</code> method. The <code>format()</code> * <code>applyPattern()</code> method. The <code>format()</code>
skipping to change at line 91 skipping to change at line 93
* matching plural case. This message will be returned. * matching plural case. This message will be returned.
* </p> * </p>
* <h5>Patterns and Their Interpretation</h5> * <h5>Patterns and Their Interpretation</h5>
* <p> * <p>
* The pattern text defines the message output for each plural case of the * The pattern text defines the message output for each plural case of the
* used locale. The pattern is a sequence of * used locale. The pattern is a sequence of
* <code><i>caseKeyword</i>{<i>message</i>}</code> clauses, separated by wh ite * <code><i>caseKeyword</i>{<i>message</i>}</code> clauses, separated by wh ite
* space characters. Each clause assigns the message <code><i>message</i></ code> * space characters. Each clause assigns the message <code><i>message</i></ code>
* to the plural case identified by <code><i>caseKeyword</i></code>. * to the plural case identified by <code><i>caseKeyword</i></code>.
* </p><p> * </p><p>
* You always have to define a message text for the default plural case * There are 6 predefined casekeyword in ICU - 'zero', 'one', 'two', 'few',
'many' and
* 'other'. You always have to define a message text for the default plural
case
* "<code>other</code>" which is contained in every rule set. If the plural * "<code>other</code>" which is contained in every rule set. If the plural
* rules of the <code>PluralFormat</code> object do not contain a plural ca se * rules of the <code>PluralFormat</code> object do not contain a plural ca se
* identified by <code><i>caseKeyword</i></code>, U_DEFAULT_KEYWORD_MISSING * identified by <code><i>caseKeyword</i></code>, U_DEFAULT_KEYWORD_MISSING
* will be set to status. * will be set to status.
* If you do not specify a message text for a particular plural case, the * If you do not specify a message text for a particular plural case, the
* message text of the plural case "<code>other</code>" gets assigned to th is * message text of the plural case "<code>other</code>" gets assigned to th is
* plural case. If you specify more than one message for the same plural ca se, * plural case. If you specify more than one message for the same plural ca se,
* U_DUPLICATE_KEYWORD will be set to status. * U_DUPLICATE_KEYWORD will be set to status.
* <br> * <br>
* Spaces between <code><i>caseKeyword</i></code> and * Spaces between <code><i>caseKeyword</i></code> and
skipping to change at line 124 skipping to change at line 127
* in the message text, if it is not contained in curly braces (to preserve * in the message text, if it is not contained in curly braces (to preserve
* <code>NumberFormat</code> patterns). <code>PluralFormat</code> will * <code>NumberFormat</code> patterns). <code>PluralFormat</code> will
* replace each of those pound signs by the number passed to the * replace each of those pound signs by the number passed to the
* <code>format()</code> method. It will be formatted using a * <code>format()</code> method. It will be formatted using a
* <code>NumberFormat</code> for the <code>PluralFormat</code>'s locale. If you * <code>NumberFormat</code> for the <code>PluralFormat</code>'s locale. If you
* need special number formatting, you have to explicitly specify a * need special number formatting, you have to explicitly specify a
* <code>NumberFormat</code> for the <code>PluralFormat</code> to use. * <code>NumberFormat</code> for the <code>PluralFormat</code> to use.
* </p> * </p>
* Example * Example
* <pre> * <pre>
* \code
* UErrorCode status = U_ZERO_ERROR; * UErrorCode status = U_ZERO_ERROR;
* MessageFormat* msgFmt = new MessageFormat(UnicodeString("{0, plural, * MessageFormat* msgFmt = new MessageFormat(UnicodeString("{0, plural,
* one{{0, number, C''est #,##0.0# fichier}} other {Ce sont # fichiers}} dans la liste."), * one{{0, number, C''est #,##0.0# fichier}} other {Ce sont # fichiers}} dans la liste."),
* Locale("fr"), status); * Locale("fr"), status);
* if (U_FAILURE(status)) { * if (U_FAILURE(status)) {
* return; * return;
* } * }
* Formattable args1[] = {(int32_t)0}; * Formattable args1[] = {(int32_t)0};
* Formattable args2[] = {(int32_t)3}; * Formattable args2[] = {(int32_t)3};
* FieldPosition ignore(FieldPosition::DONT_CARE); * FieldPosition ignore(FieldPosition::DONT_CARE);
* UnicodeString result; * UnicodeString result;
* msgFmt->format(args1, 1, result, ignore, status); * msgFmt->format(args1, 1, result, ignore, status);
* cout << result << endl; * cout << result << endl;
* result.remove(); * result.remove();
* msgFmt->format(args2, 1, result, ignore, status); * msgFmt->format(args2, 1, result, ignore, status);
* cout << result << endl; * cout << result << endl;
* \endcode
* </pre> * </pre>
* Produces the output:<br> * Produces the output:<br>
* <code>C'est 0,0 fichier dans la liste.</code><br> * <code>C'est 0,0 fichier dans la liste.</code><br>
* <code>Ce sont 3 fichiers dans la liste."</code> * <code>Ce sont 3 fichiers dans la liste.</code>
* <p> * <p>
* <strong>Note:</strong><br> * <strong>Note:</strong><br>
* Currently <code>PluralFormat</code> * Currently <code>PluralFormat</code>
* does not make use of quotes like <code>MessageFormat</code>. * does not make use of quotes like <code>MessageFormat</code>.
* If you use plural format strings with <code>MessageFormat</code> and w ant * If you use plural format strings with <code>MessageFormat</code> and w ant
* to use a quote sign "<code>'</code>", you have to write "<code>''</cod e>". * to use a quote sign <code>'</code>, you have to write <code>''</code>.
* <code>MessageFormat</code> unquotes this pattern and passes the unquo ted * <code>MessageFormat</code> unquotes this pattern and passes the unquo ted
* pattern to <code>PluralFormat</code>. It's a bit trickier if you use * pattern to <code>PluralFormat</code>. It's a bit trickier if you use
* nested formats that do quoting. In the example above, we wanted to ins ert * nested formats that do quoting. In the example above, we wanted to ins ert
* "<code>'</code>" in the number format pattern. Since * <code>'</code> in the number format pattern. Since
* <code>NumberFormat</code> supports quotes, we had to insert * <code>NumberFormat</code> supports quotes, we had to insert
* "<code>''</code>". But since <code>MessageFormat</code> unquotes the * <code>''</code>. But since <code>MessageFormat</code> unquotes the
* pattern before it gets passed to <code>PluralFormat</code>, we have to * pattern before it gets passed to <code>PluralFormat</code>, we have to
* double these quotes, i.e. write "<code>''''</code>". * double these quotes, i.e. write <code>''''</code>.
* </p> * </p>
* <h4>Defining Custom Plural Rules</h4> * <h4>Defining Custom Plural Rules</h4>
* <p>If you need to use <code>PluralFormat</code> with custom rules, you c an * <p>If you need to use <code>PluralFormat</code> with custom rules, you c an
* create a <code>PluralRules</code> object and pass it to * create a <code>PluralRules</code> object and pass it to
* <code>PluralFormat</code>'s constructor. If you also specify a locale in this * <code>PluralFormat</code>'s constructor. If you also specify a locale in this
* constructor, this locale will be used to format the number in the messag e * constructor, this locale will be used to format the number in the messag e
* texts. * texts.
* </p><p> * </p><p>
* For more information about <code>PluralRules</code>, see * For more information about <code>PluralRules</code>, see
* {@link PluralRules}. * {@link PluralRules}.
 End of changes. 9 change blocks. 
7 lines changed or deleted 16 lines changed or added


 plurrule.h   plurrule.h 
/* /*
*************************************************************************** **** *************************************************************************** ****
* Copyright (C) 2008-2009, International Business Machines Corporation and * Copyright (C) 2008-2010, International Business Machines Corporation and
* others. All Rights Reserved. * others. All Rights Reserved.
*************************************************************************** **** *************************************************************************** ****
* *
* *
* File PLURRULE.H * File PLURRULE.H
* *
* Modification History:* * Modification History:*
* Date Name Description * Date Name Description
* *
*************************************************************************** ***** *************************************************************************** *****
skipping to change at line 103 skipping to change at line 103
* {@link #select} method. * {@link #select} method.
* </p> * </p>
* *
* Examples:<pre> * Examples:<pre>
* UnicodeString keyword = pl->select(number); * UnicodeString keyword = pl->select(number);
* if (keyword== UnicodeString("one") { * if (keyword== UnicodeString("one") {
* ... * ...
* } * }
* else if ( ... ) * else if ( ... )
* </pre> * </pre>
* <strong>Note:</strong><br>
* <p>
* ICU defines plural rules for many locales based on CLDR <i>Language Pl
ural Rules</i>.
* For these predefined rules, see CLDR page at
* http://unicode.org/repos/cldr-tmp/trunk/diff/supplemental/language_pl
ural_rules.html
* </p>
*/ */
class U_I18N_API PluralRules : public UObject { class U_I18N_API PluralRules : public UObject {
public: public:
/** /**
* Constructor. * Constructor.
* @param status Output param set to success/failure code on exit, whi ch * @param status Output param set to success/failure code on exit, whi ch
* must not indicate a failure before the function call. * must not indicate a failure before the function call.
* *
* @stable ICU 4.0 * @stable ICU 4.0
 End of changes. 2 change blocks. 
1 lines changed or deleted 9 lines changed or added


 smpdtfmt.h   smpdtfmt.h 
skipping to change at line 1018 skipping to change at line 1018
void initGMTFormatters(UErrorCode &status); void initGMTFormatters(UErrorCode &status);
/** /**
* Initialize NumberFormat instances used for numbering system override s. * Initialize NumberFormat instances used for numbering system override s.
*/ */
void initNumberFormatters(const Locale &locale,UErrorCode &status); void initNumberFormatters(const Locale &locale,UErrorCode &status);
/** /**
* Get the numbering system to be used for a particular field. * Get the numbering system to be used for a particular field.
*/ */
using DateFormat::getNumberFormat; // Do not hide visibility of base NumberFormat * getNumberFormatByIndex(UDateFormatField index) const;
class function
NumberFormat * getNumberFormat(UDateFormatField index) const;
/** /**
* Parse the given override string and set up structures for number for mats * Parse the given override string and set up structures for number for mats
*/ */
void processOverrideString(const Locale &locale, const UnicodeString &s tr, int8_t type, UErrorCode &status); void processOverrideString(const Locale &locale, const UnicodeString &s tr, int8_t type, UErrorCode &status);
/** /**
* Used to map pattern characters to Calendar field identifiers. * Used to map pattern characters to Calendar field identifiers.
*/ */
static const UCalendarDateFields fgPatternIndexToCalendarField[]; static const UCalendarDateFields fgPatternIndexToCalendarField[];
 End of changes. 1 change blocks. 
3 lines changed or deleted 1 lines changed or added


 ubidi.h   ubidi.h 
skipping to change at line 419 skipping to change at line 419
* @see ubidi_getLogicalMap * @see ubidi_getLogicalMap
* @stable ICU 3.6 * @stable ICU 3.6
*/ */
#define UBIDI_MAP_NOWHERE (-1) #define UBIDI_MAP_NOWHERE (-1)
/** /**
* <code>UBiDiDirection</code> values indicate the text direction. * <code>UBiDiDirection</code> values indicate the text direction.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
enum UBiDiDirection { enum UBiDiDirection {
/** All left-to-right text. This is a 0 value. @stable ICU 2.0 */ /** Left-to-right text. This is a 0 value.
UBIDI_LTR, * <ul>
/** All right-to-left text. This is a 1 value. @stable ICU 2.0 */ * <li>As return value for <code>ubidi_getDirection()</code>, it means
UBIDI_RTL, * that the source string contains no right-to-left characters, or
/** Mixed-directional text. @stable ICU 2.0 */ * that the source string is empty and the paragraph level is even.
UBIDI_MIXED * <li> As return value for <code>ubidi_getBaseDirection()</code>, it
* means that the first strong character of the source string has
* a left-to-right direction.
* </ul>
* @stable ICU 2.0
*/
UBIDI_LTR,
/** Right-to-left text. This is a 1 value.
* <ul>
* <li>As return value for <code>ubidi_getDirection()</code>, it means
* that the source string contains no left-to-right characters, or
* that the source string is empty and the paragraph level is odd.
* <li> As return value for <code>ubidi_getBaseDirection()</code>, it
* means that the first strong character of the source string has
* a right-to-left direction.
* </ul>
* @stable ICU 2.0
*/
UBIDI_RTL,
/** Mixed-directional text.
* <p>As return value for <code>ubidi_getDirection()</code>, it means
* that the source string contains both left-to-right and
* right-to-left characters.
* @stable ICU 2.0
*/
UBIDI_MIXED,
/** No strongly directional text.
* <p>As return value for <code>ubidi_getBaseDirection()</code>, it means
* that the source string is missing or empty, or contains neither lef
t-to-right
* nor right-to-left characters.
* @draft ICU 4.6
*/
UBIDI_NEUTRAL
}; };
/** @stable ICU 2.0 */ /** @stable ICU 2.0 */
typedef enum UBiDiDirection UBiDiDirection; typedef enum UBiDiDirection UBiDiDirection;
/** /**
* Forward declaration of the <code>UBiDi</code> structure for the declarat ion of * Forward declaration of the <code>UBiDi</code> structure for the declarat ion of
* the API functions. Its fields are implementation-specific.<p> * the API functions. Its fields are implementation-specific.<p>
* This structure holds information about a paragraph (or multiple paragrap hs) * This structure holds information about a paragraph (or multiple paragrap hs)
* of text with Bidi-algorithm-related details, or about one line of * of text with Bidi-algorithm-related details, or about one line of
skipping to change at line 1162 skipping to change at line 1194
/** /**
* Get the directionality of the text. * Get the directionality of the text.
* *
* @param pBiDi is the paragraph or line <code>UBiDi</code> object. * @param pBiDi is the paragraph or line <code>UBiDi</code> object.
* *
* @return a value of <code>UBIDI_LTR</code>, <code>UBIDI_RTL</code> * @return a value of <code>UBIDI_LTR</code>, <code>UBIDI_RTL</code>
* or <code>UBIDI_MIXED</code> * or <code>UBIDI_MIXED</code>
* that indicates if the entire text * that indicates if the entire text
* represented by this object is unidirectional, * represented by this object is unidirectional,
* and which direction, or if it is mixed-directional. * and which direction, or if it is mixed-directional.
* Note - The value <code>UBIDI_NEUTRAL</code> is never returned from this method.
* *
* @see UBiDiDirection * @see UBiDiDirection
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE UBiDiDirection U_EXPORT2 U_STABLE UBiDiDirection U_EXPORT2
ubidi_getDirection(const UBiDi *pBiDi); ubidi_getDirection(const UBiDi *pBiDi);
/** /**
* Gets the base direction of the text provided according
* to the Unicode Bidirectional Algorithm. The base direction
* is derived from the first character in the string with bidirectional
* character type L, R, or AL. If the first such character has type L,
* <code>UBIDI_LTR</code> is returned. If the first such character has
* type R or AL, <code>UBIDI_RTL</code> is returned. If the string does
* not contain any character of these types, then
* <code>UBIDI_NEUTRAL</code> is returned.
*
* This is a lightweight function for use when only the base direction
* is needed and no further bidi processing of the text is needed.
*
* @param text is a pointer to the text whose base
* direction is needed.
* Note: the text must be (at least) @c length long.
*
* @param length is the length of the text;
* if <code>length==-1</code> then the text
* must be zero-terminated.
*
* @return <code>UBIDI_LTR</code>, <code>UBIDI_RTL</code>,
* <code>UBIDI_NEUTRAL</code>
*
* @see UBiDiDirection
* @draft ICU 4.6
*/
U_DRAFT UBiDiDirection U_EXPORT2
ubidi_getBaseDirection(const UChar *text, int32_t length );
/**
* Get the pointer to the text. * Get the pointer to the text.
* *
* @param pBiDi is the paragraph or line <code>UBiDi</code> object. * @param pBiDi is the paragraph or line <code>UBiDi</code> object.
* *
* @return The pointer to the text that the UBiDi object was created for. * @return The pointer to the text that the UBiDi object was created for.
* *
* @see ubidi_setPara * @see ubidi_setPara
* @see ubidi_setLine * @see ubidi_setLine
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
skipping to change at line 1401 skipping to change at line 1464
* range <code>[0..ubidi_countRuns(pBiDi)-1]</code>. * range <code>[0..ubidi_countRuns(pBiDi)-1]</code>.
* *
* @param pLogicalStart is the first logical character index in the text. * @param pLogicalStart is the first logical character index in the text.
* The pointer may be <code>NULL</code> if this index is not needed. * The pointer may be <code>NULL</code> if this index is not needed.
* *
* @param pLength is the number of characters (at least one) in the run. * @param pLength is the number of characters (at least one) in the run.
* The pointer may be <code>NULL</code> if this is not needed. * The pointer may be <code>NULL</code> if this is not needed.
* *
* @return the directionality of the run, * @return the directionality of the run,
* <code>UBIDI_LTR==0</code> or <code>UBIDI_RTL==1</code>, * <code>UBIDI_LTR==0</code> or <code>UBIDI_RTL==1</code>,
* never <code>UBIDI_MIXED</code>. * never <code>UBIDI_MIXED</code>,
* never <code>UBIDI_NEUTRAL</code>.
* *
* @see ubidi_countRuns * @see ubidi_countRuns
* *
* Example: * Example:
* <pre> * <pre>
* \code * \code
* int32_t i, count=ubidi_countRuns(pBiDi), * int32_t i, count=ubidi_countRuns(pBiDi),
* logicalStart, visualIndex=0, length; * logicalStart, visualIndex=0, length;
* for(i=0; i<count; ++i) { * for(i=0; i<count; ++i) {
* if(UBIDI_LTR==ubidi_getVisualRun(pBiDi, i, &logicalStart, &length)) { * if(UBIDI_LTR==ubidi_getVisualRun(pBiDi, i, &logicalStart, &length)) {
 End of changes. 4 change blocks. 
7 lines changed or deleted 72 lines changed or added


 uchar.h   uchar.h 
skipping to change at line 42 skipping to change at line 42
/*========================================================================= =*/ /*========================================================================= =*/
/** /**
* Unicode version number, default for the current ICU version. * Unicode version number, default for the current ICU version.
* The actual Unicode Character Database (UCD) data is stored in uprops.dat * The actual Unicode Character Database (UCD) data is stored in uprops.dat
* and may be generated from UCD files from a different Unicode version. * and may be generated from UCD files from a different Unicode version.
* Call u_getUnicodeVersion to get the actual Unicode version of the data. * Call u_getUnicodeVersion to get the actual Unicode version of the data.
* *
* @see u_getUnicodeVersion * @see u_getUnicodeVersion
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
#define U_UNICODE_VERSION "5.2" #define U_UNICODE_VERSION "6.0"
/** /**
* \file * \file
* \brief C API: Unicode Properties * \brief C API: Unicode Properties
* *
* This C API provides low-level access to the Unicode Character Database. * This C API provides low-level access to the Unicode Character Database.
* In addition to raw property values, some convenience functions calculate * In addition to raw property values, some convenience functions calculate
* derived properties, for example for Java-style programming. * derived properties, for example for Java-style programming.
* *
* Unicode assigns each code point (not just assigned character) values for * Unicode assigns each code point (not just assigned character) values for
skipping to change at line 395 skipping to change at line 395
/** Binary property print (a C/POSIX character class). /** Binary property print (a C/POSIX character class).
Implemented according to the UTS #18 Annex C Standard Recommendatio n. Implemented according to the UTS #18 Annex C Standard Recommendatio n.
See the uchar.h file documentation. See the uchar.h file documentation.
@stable ICU 3.4 */ @stable ICU 3.4 */
UCHAR_POSIX_PRINT=47, UCHAR_POSIX_PRINT=47,
/** Binary property xdigit (a C/POSIX character class). /** Binary property xdigit (a C/POSIX character class).
Implemented according to the UTS #18 Annex C Standard Recommendatio n. Implemented according to the UTS #18 Annex C Standard Recommendatio n.
See the uchar.h file documentation. See the uchar.h file documentation.
@stable ICU 3.4 */ @stable ICU 3.4 */
UCHAR_POSIX_XDIGIT=48, UCHAR_POSIX_XDIGIT=48,
/** Binary property Cased. For Lowercase, Uppercase and Titlecase chara cters. @draft ICU 4.4 */ /** Binary property Cased. For Lowercase, Uppercase and Titlecase chara cters. @stable ICU 4.4 */
UCHAR_CASED=49, UCHAR_CASED=49,
/** Binary property Case_Ignorable. Used in context-sensitive case mapp ings. @draft ICU 4.4 */ /** Binary property Case_Ignorable. Used in context-sensitive case mapp ings. @stable ICU 4.4 */
UCHAR_CASE_IGNORABLE=50, UCHAR_CASE_IGNORABLE=50,
/** Binary property Changes_When_Lowercased. @draft ICU 4.4 */ /** Binary property Changes_When_Lowercased. @stable ICU 4.4 */
UCHAR_CHANGES_WHEN_LOWERCASED=51, UCHAR_CHANGES_WHEN_LOWERCASED=51,
/** Binary property Changes_When_Uppercased. @draft ICU 4.4 */ /** Binary property Changes_When_Uppercased. @stable ICU 4.4 */
UCHAR_CHANGES_WHEN_UPPERCASED=52, UCHAR_CHANGES_WHEN_UPPERCASED=52,
/** Binary property Changes_When_Titlecased. @draft ICU 4.4 */ /** Binary property Changes_When_Titlecased. @stable ICU 4.4 */
UCHAR_CHANGES_WHEN_TITLECASED=53, UCHAR_CHANGES_WHEN_TITLECASED=53,
/** Binary property Changes_When_Casefolded. @draft ICU 4.4 */ /** Binary property Changes_When_Casefolded. @stable ICU 4.4 */
UCHAR_CHANGES_WHEN_CASEFOLDED=54, UCHAR_CHANGES_WHEN_CASEFOLDED=54,
/** Binary property Changes_When_Casemapped. @draft ICU 4.4 */ /** Binary property Changes_When_Casemapped. @stable ICU 4.4 */
UCHAR_CHANGES_WHEN_CASEMAPPED=55, UCHAR_CHANGES_WHEN_CASEMAPPED=55,
/** Binary property Changes_When_NFKC_Casefolded. @draft ICU 4.4 */ /** Binary property Changes_When_NFKC_Casefolded. @stable ICU 4.4 */
UCHAR_CHANGES_WHEN_NFKC_CASEFOLDED=56, UCHAR_CHANGES_WHEN_NFKC_CASEFOLDED=56,
/** One more than the last constant for binary Unicode properties. @sta ble ICU 2.1 */ /** One more than the last constant for binary Unicode properties. @sta ble ICU 2.1 */
UCHAR_BINARY_LIMIT=57, UCHAR_BINARY_LIMIT=57,
/** Enumerated property Bidi_Class. /** Enumerated property Bidi_Class.
Same as u_charDirection, returns UCharDirection values. @stable ICU 2.2 */ Same as u_charDirection, returns UCharDirection values. @stable ICU 2.2 */
UCHAR_BIDI_CLASS=0x1000, UCHAR_BIDI_CLASS=0x1000,
/** First constant for enumerated/integer Unicode properties. @stable I CU 2.2 */ /** First constant for enumerated/integer Unicode properties. @stable I CU 2.2 */
UCHAR_INT_START=UCHAR_BIDI_CLASS, UCHAR_INT_START=UCHAR_BIDI_CLASS,
/** Enumerated property Block. /** Enumerated property Block.
skipping to change at line 563 skipping to change at line 563
UCHAR_TITLECASE_MAPPING=0x400A, UCHAR_TITLECASE_MAPPING=0x400A,
/** String property Unicode_1_Name. /** String property Unicode_1_Name.
Corresponds to u_charName. @stable ICU 2.4 */ Corresponds to u_charName. @stable ICU 2.4 */
UCHAR_UNICODE_1_NAME=0x400B, UCHAR_UNICODE_1_NAME=0x400B,
/** String property Uppercase_Mapping. /** String property Uppercase_Mapping.
Corresponds to u_strToUpper in ustring.h. @stable ICU 2.4 */ Corresponds to u_strToUpper in ustring.h. @stable ICU 2.4 */
UCHAR_UPPERCASE_MAPPING=0x400C, UCHAR_UPPERCASE_MAPPING=0x400C,
/** One more than the last constant for string Unicode properties. @sta ble ICU 2.4 */ /** One more than the last constant for string Unicode properties. @sta ble ICU 2.4 */
UCHAR_STRING_LIMIT=0x400D, UCHAR_STRING_LIMIT=0x400D,
/** Provisional property Script_Extensions (new in Unicode 6.0).
As a provisional property, it may be modified or removed
in future versions of the Unicode Standard, and thus in ICU.
Some characters are commonly used in multiple scripts.
For more information, see UAX #24: http://www.unicode.org/reports/t
r24/.
Corresponds to uscript_hasScript and uscript_getScriptExtensions in
uscript.h.
@draft ICU 4.6 */
UCHAR_SCRIPT_EXTENSIONS=0x7000,
/** First constant for Unicode properties with unusual value types. @dr
aft ICU 4.6 */
UCHAR_OTHER_PROPERTY_START=UCHAR_SCRIPT_EXTENSIONS,
/** One more than the last constant for Unicode properties with unusual
value types.
* @draft ICU 4.6 */
UCHAR_OTHER_PROPERTY_LIMIT=0x7001,
/** Represents a nonexistent or invalid property or property value. @st able ICU 2.4 */ /** Represents a nonexistent or invalid property or property value. @st able ICU 2.4 */
UCHAR_INVALID_CODE = -1 UCHAR_INVALID_CODE = -1
} UProperty; } UProperty;
/** /**
* Data for enumerated Unicode general category types. * Data for enumerated Unicode general category types.
* See http://www.unicode.org/Public/UNIDATA/UnicodeData.html . * See http://www.unicode.org/Public/UNIDATA/UnicodeData.html .
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
typedef enum UCharCategory typedef enum UCharCategory
skipping to change at line 1289 skipping to change at line 1303
UBLOCK_CARIAN = 168, /*[102A0]*/ UBLOCK_CARIAN = 168, /*[102A0]*/
/** @stable ICU 4.0 */ /** @stable ICU 4.0 */
UBLOCK_LYDIAN = 169, /*[10920]*/ UBLOCK_LYDIAN = 169, /*[10920]*/
/** @stable ICU 4.0 */ /** @stable ICU 4.0 */
UBLOCK_MAHJONG_TILES = 170, /*[1F000]*/ UBLOCK_MAHJONG_TILES = 170, /*[1F000]*/
/** @stable ICU 4.0 */ /** @stable ICU 4.0 */
UBLOCK_DOMINO_TILES = 171, /*[1F030]*/ UBLOCK_DOMINO_TILES = 171, /*[1F030]*/
/* New blocks in Unicode 5.2 */ /* New blocks in Unicode 5.2 */
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_SAMARITAN = 172, /*[0800]*/ UBLOCK_SAMARITAN = 172, /*[0800]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_UNIFIED_CANADIAN_ABORIGINAL_SYLLABICS_EXTENDED = 173, /*[18B0]*/ UBLOCK_UNIFIED_CANADIAN_ABORIGINAL_SYLLABICS_EXTENDED = 173, /*[18B0]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_TAI_THAM = 174, /*[1A20]*/ UBLOCK_TAI_THAM = 174, /*[1A20]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_VEDIC_EXTENSIONS = 175, /*[1CD0]*/ UBLOCK_VEDIC_EXTENSIONS = 175, /*[1CD0]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_LISU = 176, /*[A4D0]*/ UBLOCK_LISU = 176, /*[A4D0]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_BAMUM = 177, /*[A6A0]*/ UBLOCK_BAMUM = 177, /*[A6A0]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_COMMON_INDIC_NUMBER_FORMS = 178, /*[A830]*/ UBLOCK_COMMON_INDIC_NUMBER_FORMS = 178, /*[A830]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_DEVANAGARI_EXTENDED = 179, /*[A8E0]*/ UBLOCK_DEVANAGARI_EXTENDED = 179, /*[A8E0]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_HANGUL_JAMO_EXTENDED_A = 180, /*[A960]*/ UBLOCK_HANGUL_JAMO_EXTENDED_A = 180, /*[A960]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_JAVANESE = 181, /*[A980]*/ UBLOCK_JAVANESE = 181, /*[A980]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_MYANMAR_EXTENDED_A = 182, /*[AA60]*/ UBLOCK_MYANMAR_EXTENDED_A = 182, /*[AA60]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_TAI_VIET = 183, /*[AA80]*/ UBLOCK_TAI_VIET = 183, /*[AA80]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_MEETEI_MAYEK = 184, /*[ABC0]*/ UBLOCK_MEETEI_MAYEK = 184, /*[ABC0]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_HANGUL_JAMO_EXTENDED_B = 185, /*[D7B0]*/ UBLOCK_HANGUL_JAMO_EXTENDED_B = 185, /*[D7B0]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_IMPERIAL_ARAMAIC = 186, /*[10840]*/ UBLOCK_IMPERIAL_ARAMAIC = 186, /*[10840]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_OLD_SOUTH_ARABIAN = 187, /*[10A60]*/ UBLOCK_OLD_SOUTH_ARABIAN = 187, /*[10A60]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_AVESTAN = 188, /*[10B00]*/ UBLOCK_AVESTAN = 188, /*[10B00]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_INSCRIPTIONAL_PARTHIAN = 189, /*[10B40]*/ UBLOCK_INSCRIPTIONAL_PARTHIAN = 189, /*[10B40]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_INSCRIPTIONAL_PAHLAVI = 190, /*[10B60]*/ UBLOCK_INSCRIPTIONAL_PAHLAVI = 190, /*[10B60]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_OLD_TURKIC = 191, /*[10C00]*/ UBLOCK_OLD_TURKIC = 191, /*[10C00]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_RUMI_NUMERAL_SYMBOLS = 192, /*[10E60]*/ UBLOCK_RUMI_NUMERAL_SYMBOLS = 192, /*[10E60]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_KAITHI = 193, /*[11080]*/ UBLOCK_KAITHI = 193, /*[11080]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_EGYPTIAN_HIEROGLYPHS = 194, /*[13000]*/ UBLOCK_EGYPTIAN_HIEROGLYPHS = 194, /*[13000]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_ENCLOSED_ALPHANUMERIC_SUPPLEMENT = 195, /*[1F100]*/ UBLOCK_ENCLOSED_ALPHANUMERIC_SUPPLEMENT = 195, /*[1F100]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_ENCLOSED_IDEOGRAPHIC_SUPPLEMENT = 196, /*[1F200]*/ UBLOCK_ENCLOSED_IDEOGRAPHIC_SUPPLEMENT = 196, /*[1F200]*/
/** @draft ICU 4.4 */ /** @stable ICU 4.4 */
UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_C = 197, /*[2A700]*/ UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_C = 197, /*[2A700]*/
/* New blocks in Unicode 6.0 */
/** @stable ICU 4.6 */
UBLOCK_MANDAIC = 198, /*[0840]*/
/** @stable ICU 4.6 */
UBLOCK_BATAK = 199, /*[1BC0]*/
/** @stable ICU 4.6 */
UBLOCK_ETHIOPIC_EXTENDED_A = 200, /*[AB00]*/
/** @stable ICU 4.6 */
UBLOCK_BRAHMI = 201, /*[11000]*/
/** @stable ICU 4.6 */
UBLOCK_BAMUM_SUPPLEMENT = 202, /*[16800]*/
/** @stable ICU 4.6 */
UBLOCK_KANA_SUPPLEMENT = 203, /*[1B000]*/
/** @stable ICU 4.6 */
UBLOCK_PLAYING_CARDS = 204, /*[1F0A0]*/
/** @stable ICU 4.6 */
UBLOCK_MISCELLANEOUS_SYMBOLS_AND_PICTOGRAPHS = 205, /*[1F300]*/
/** @stable ICU 4.6 */
UBLOCK_EMOTICONS = 206, /*[1F600]*/
/** @stable ICU 4.6 */
UBLOCK_TRANSPORT_AND_MAP_SYMBOLS = 207, /*[1F680]*/
/** @stable ICU 4.6 */
UBLOCK_ALCHEMICAL_SYMBOLS = 208, /*[1F700]*/
/** @stable ICU 4.6 */
UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_D = 209, /*[2B740]*/
/** @stable ICU 2.0 */ /** @stable ICU 2.0 */
UBLOCK_COUNT = 198, UBLOCK_COUNT = 210,
/** @stable ICU 2.0 */ /** @stable ICU 2.0 */
UBLOCK_INVALID_CODE=-1 UBLOCK_INVALID_CODE=-1
}; };
/** @stable ICU 2.0 */ /** @stable ICU 2.0 */
typedef enum UBlockCode UBlockCode; typedef enum UBlockCode UBlockCode;
/** /**
* East Asian Width constants. * East Asian Width constants.
skipping to change at line 1388 skipping to change at line 1429
* with ISO-10646; or an "extended" name that gives each * with ISO-10646; or an "extended" name that gives each
* Unicode code point a unique name. * Unicode code point a unique name.
* *
* @see u_charName * @see u_charName
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
typedef enum UCharNameChoice { typedef enum UCharNameChoice {
U_UNICODE_CHAR_NAME, U_UNICODE_CHAR_NAME,
U_UNICODE_10_CHAR_NAME, U_UNICODE_10_CHAR_NAME,
U_EXTENDED_CHAR_NAME, U_EXTENDED_CHAR_NAME,
U_CHAR_NAME_ALIAS, /**< Corrected name from NameAliases.txt. @ draft ICU 4.4 */ U_CHAR_NAME_ALIAS, /**< Corrected name from NameAliases.txt. @ stable ICU 4.4 */
U_CHAR_NAME_CHOICE_COUNT U_CHAR_NAME_CHOICE_COUNT
} UCharNameChoice; } UCharNameChoice;
/** /**
* Selector constants for u_getPropertyName() and * Selector constants for u_getPropertyName() and
* u_getPropertyValueName(). These selectors are used to choose which * u_getPropertyValueName(). These selectors are used to choose which
* name is returned for a given property or value. All properties and * name is returned for a given property or value. All properties and
* values have a long name. Most have a short name, but some do not. * values have a long name. Most have a short name, but some do not.
* Unicode allows for additional names, beyond the long and short * Unicode allows for additional names, beyond the long and short
* name, which would be indicated by U_LONG_PROPERTY_NAME + i, where * name, which would be indicated by U_LONG_PROPERTY_NAME + i, where
skipping to change at line 1476 skipping to change at line 1517
U_JG_BEH, U_JG_BEH,
U_JG_BETH, U_JG_BETH,
U_JG_DAL, U_JG_DAL,
U_JG_DALATH_RISH, U_JG_DALATH_RISH,
U_JG_E, U_JG_E,
U_JG_FEH, U_JG_FEH,
U_JG_FINAL_SEMKATH, U_JG_FINAL_SEMKATH,
U_JG_GAF, U_JG_GAF,
U_JG_GAMAL, U_JG_GAMAL,
U_JG_HAH, U_JG_HAH,
U_JG_HAMZA_ON_HEH_GOAL, U_JG_TEH_MARBUTA_GOAL, /**< @stable ICU 4.6 */
U_JG_HAMZA_ON_HEH_GOAL=U_JG_TEH_MARBUTA_GOAL,
U_JG_HE, U_JG_HE,
U_JG_HEH, U_JG_HEH,
U_JG_HEH_GOAL, U_JG_HEH_GOAL,
U_JG_HETH, U_JG_HETH,
U_JG_KAF, U_JG_KAF,
U_JG_KAPH, U_JG_KAPH,
U_JG_KNOTTED_HEH, U_JG_KNOTTED_HEH,
U_JG_LAM, U_JG_LAM,
U_JG_LAMADH, U_JG_LAMADH,
U_JG_MEEM, U_JG_MEEM,
skipping to change at line 1517 skipping to change at line 1559
U_JG_YEH, U_JG_YEH,
U_JG_YEH_BARREE, U_JG_YEH_BARREE,
U_JG_YEH_WITH_TAIL, U_JG_YEH_WITH_TAIL,
U_JG_YUDH, U_JG_YUDH,
U_JG_YUDH_HE, U_JG_YUDH_HE,
U_JG_ZAIN, U_JG_ZAIN,
U_JG_FE, /**< @stable ICU 2.6 */ U_JG_FE, /**< @stable ICU 2.6 */
U_JG_KHAPH, /**< @stable ICU 2.6 */ U_JG_KHAPH, /**< @stable ICU 2.6 */
U_JG_ZHAIN, /**< @stable ICU 2.6 */ U_JG_ZHAIN, /**< @stable ICU 2.6 */
U_JG_BURUSHASKI_YEH_BARREE, /**< @stable ICU 4.0 */ U_JG_BURUSHASKI_YEH_BARREE, /**< @stable ICU 4.0 */
U_JG_FARSI_YEH, /**< @draft ICU 4.4 */ U_JG_FARSI_YEH, /**< @stable ICU 4.4 */
U_JG_NYA, /**< @draft ICU 4.4 */ U_JG_NYA, /**< @stable ICU 4.4 */
U_JG_COUNT U_JG_COUNT
} UJoiningGroup; } UJoiningGroup;
/** /**
* Grapheme Cluster Break constants. * Grapheme Cluster Break constants.
* *
* @see UCHAR_GRAPHEME_CLUSTER_BREAK * @see UCHAR_GRAPHEME_CLUSTER_BREAK
* @stable ICU 3.4 * @stable ICU 3.4
*/ */
typedef enum UGraphemeClusterBreak { typedef enum UGraphemeClusterBreak {
 End of changes. 41 change blocks. 
40 lines changed or deleted 86 lines changed or added


 uidna.h   uidna.h 
skipping to change at line 105 skipping to change at line 105
* Opaque C service object type for the new IDNA API. * Opaque C service object type for the new IDNA API.
* @draft ICU 4.6 * @draft ICU 4.6
*/ */
struct UIDNA; struct UIDNA;
typedef struct UIDNA UIDNA; /**< C typedef for struct UIDNA. @draft ICU 4. 6 */ typedef struct UIDNA UIDNA; /**< C typedef for struct UIDNA. @draft ICU 4. 6 */
/** /**
* Returns a UIDNA instance which implements UTS #46. * Returns a UIDNA instance which implements UTS #46.
* Returns an unmodifiable instance, owned by the caller. * Returns an unmodifiable instance, owned by the caller.
* Cache it for multiple operations, and uidna_close() it when done. * Cache it for multiple operations, and uidna_close() it when done.
* The instance is thread-safe, that is, it can be used concurrently.
* *
* For details about the UTS #46 implementation see the IDNA C++ class in i dna.h. * For details about the UTS #46 implementation see the IDNA C++ class in i dna.h.
* *
* @param options Bit set to modify the processing and error checking. * @param options Bit set to modify the processing and error checking.
* See option bit set values in uidna.h. * See option bit set values in uidna.h.
* @param pErrorCode Standard ICU error code. Its input value must * @param pErrorCode Standard ICU error code. Its input value must
* pass the U_SUCCESS() test, or else the function returns * pass the U_SUCCESS() test, or else the function returns
* immediately. Check for U_FAILURE() on output or use wit h * immediately. Check for U_FAILURE() on output or use wit h
* function chaining. (See User Guide for details.) * function chaining. (See User Guide for details.)
* @return the UTS #46 UIDNA instance, if successful * @return the UTS #46 UIDNA instance, if successful
skipping to change at line 219 skipping to change at line 220
*/ */
U_DRAFT int32_t U_EXPORT2 U_DRAFT int32_t U_EXPORT2
uidna_labelToASCII(const UIDNA *idna, uidna_labelToASCII(const UIDNA *idna,
const UChar *label, int32_t length, const UChar *label, int32_t length,
UChar *dest, int32_t capacity, UChar *dest, int32_t capacity,
UIDNAInfo *pInfo, UErrorCode *pErrorCode); UIDNAInfo *pInfo, UErrorCode *pErrorCode);
/** /**
* Converts a single domain name label into its Unicode form for human-read able display. * Converts a single domain name label into its Unicode form for human-read able display.
* If any processing step fails, then pInfo->errors will be non-zero. * If any processing step fails, then pInfo->errors will be non-zero.
* The domain name might be modified according to the types of errors. * The label might be modified according to the types of errors.
* *
* The UErrorCode indicates an error only in exceptional cases, * The UErrorCode indicates an error only in exceptional cases,
* such as a U_MEMORY_ALLOCATION_ERROR. * such as a U_MEMORY_ALLOCATION_ERROR.
* *
* @param idna UIDNA instance * @param idna UIDNA instance
* @param label Input domain name label * @param label Input domain name label
* @param length Label length, or -1 if NUL-terminated * @param length Label length, or -1 if NUL-terminated
* @param dest Destination string buffer * @param dest Destination string buffer
* @param capacity Destination buffer capacity * @param capacity Destination buffer capacity
* @param pInfo Output container of IDNA processing details. * @param pInfo Output container of IDNA processing details.
skipping to change at line 407 skipping to change at line 408
*/ */
enum { enum {
/** /**
* A non-final domain name label (or the whole domain name) is empty. * A non-final domain name label (or the whole domain name) is empty.
* @draft ICU 4.6 * @draft ICU 4.6
*/ */
UIDNA_ERROR_EMPTY_LABEL=1, UIDNA_ERROR_EMPTY_LABEL=1,
/** /**
* A domain name label is longer than 63 bytes. * A domain name label is longer than 63 bytes.
* (See STD13/RFC1034 3.1. Name space specifications and terminology.) * (See STD13/RFC1034 3.1. Name space specifications and terminology.)
* This is only checked in ToASCII operations, and only if the UIDNA_US E_STD3_RULES is set. * This is only checked in ToASCII operations, and only if the output l abel is all-ASCII.
* @draft ICU 4.6 * @draft ICU 4.6
*/ */
UIDNA_ERROR_LABEL_TOO_LONG=2, UIDNA_ERROR_LABEL_TOO_LONG=2,
/** /**
* A domain name is longer than 255 bytes in its storage form. * A domain name is longer than 255 bytes in its storage form.
* (See STD13/RFC1034 3.1. Name space specifications and terminology.) * (See STD13/RFC1034 3.1. Name space specifications and terminology.)
* This is only checked in ToASCII operations, and only if the UIDNA_US E_STD3_RULES is set. * This is only checked in ToASCII operations, and only if the output d omain name is all-ASCII.
* @draft ICU 4.6 * @draft ICU 4.6
*/ */
UIDNA_ERROR_DOMAIN_NAME_TOO_LONG=4, UIDNA_ERROR_DOMAIN_NAME_TOO_LONG=4,
/** /**
* A label starts with a hyphen-minus ('-'). * A label starts with a hyphen-minus ('-').
* @draft ICU 4.6 * @draft ICU 4.6
*/ */
UIDNA_ERROR_LEADING_HYPHEN=8, UIDNA_ERROR_LEADING_HYPHEN=8,
/** /**
* A label ends with a hyphen-minus ('-'). * A label ends with a hyphen-minus ('-').
 End of changes. 4 change blocks. 
3 lines changed or deleted 4 lines changed or added


 uloc.h   uloc.h 
skipping to change at line 284 skipping to change at line 284
*/ */
#define ULOC_KEYWORDS_CAPACITY 50 #define ULOC_KEYWORDS_CAPACITY 50
/** /**
* Useful constant for the maximum total size of keywords and their values in a locale * Useful constant for the maximum total size of keywords and their values in a locale
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
#define ULOC_KEYWORD_AND_VALUES_CAPACITY 100 #define ULOC_KEYWORD_AND_VALUES_CAPACITY 100
/** /**
* Character separating keywords from the locale string * Invariant character separating keywords from the locale string
* different for EBCDIC - TODO
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
#define ULOC_KEYWORD_SEPARATOR '@' #define ULOC_KEYWORD_SEPARATOR '@'
/** /**
* Character for assigning value to a keyword * Unicode code point for '@' separating keywords from the locale string.
* @see ULOC_KEYWORD_SEPARATOR
* @draft ICU 4.6
*/
#define ULOC_KEYWORD_SEPARATOR_UNICODE 0x40
/**
* Invariant character for assigning value to a keyword
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
#define ULOC_KEYWORD_ASSIGN '=' #define ULOC_KEYWORD_ASSIGN '='
/** /**
* Character separating keywords * Unicode code point for '=' for assigning value to a keyword.
* @see ULOC_KEYWORD_ASSIGN
* @draft ICU 4.6
*/
#define ULOC_KEYWORD_ASSIGN_UNICODE 0x3D
/**
* Invariant character separating keywords
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
#define ULOC_KEYWORD_ITEM_SEPARATOR ';' #define ULOC_KEYWORD_ITEM_SEPARATOR ';'
/** /**
* Unicode code point for ';' separating keywords
* @see ULOC_KEYWORD_ITEM_SEPARATOR
* @draft ICU 4.6
*/
#define ULOC_KEYWORD_ITEM_SEPARATOR_UNICODE 0x3B
/**
* Constants for *_getLocale() * Constants for *_getLocale()
* Allow user to select whether she wants information on * Allow user to select whether she wants information on
* requested, valid or actual locale. * requested, valid or actual locale.
* For example, a collator for "en_US_CALIFORNIA" was * For example, a collator for "en_US_CALIFORNIA" was
* requested. In the current state of ICU (2.0), * requested. In the current state of ICU (2.0),
* the requested locale is "en_US_CALIFORNIA", * the requested locale is "en_US_CALIFORNIA",
* the valid locale is "en_US" (most specific locale supported by ICU) * the valid locale is "en_US" (most specific locale supported by ICU)
* and the actual locale is "root" (the collation data comes unmodified * and the actual locale is "root" (the collation data comes unmodified
* from the UCA) * from the UCA)
* The locale is considered supported by ICU if there is a core ICU bundle * The locale is considered supported by ICU if there is a core ICU bundle
 End of changes. 6 change blocks. 
4 lines changed or deleted 26 lines changed or added


 unum.h   unum.h 
skipping to change at line 895 skipping to change at line 895
UNUM_INFINITY_SYMBOL = 14, UNUM_INFINITY_SYMBOL = 14,
/** Nan symbol */ /** Nan symbol */
UNUM_NAN_SYMBOL = 15, UNUM_NAN_SYMBOL = 15,
/** Significant digit symbol /** Significant digit symbol
* @stable ICU 3.0 */ * @stable ICU 3.0 */
UNUM_SIGNIFICANT_DIGIT_SYMBOL = 16, UNUM_SIGNIFICANT_DIGIT_SYMBOL = 16,
/** The monetary grouping separator /** The monetary grouping separator
* @stable ICU 3.6 * @stable ICU 3.6
*/ */
UNUM_MONETARY_GROUPING_SEPARATOR_SYMBOL = 17, UNUM_MONETARY_GROUPING_SEPARATOR_SYMBOL = 17,
/** One
* @draft ICU 4.6
*/
UNUM_ONE_DIGIT_SYMBOL = 18,
/** Two
* @draft ICU 4.6
*/
UNUM_TWO_DIGIT_SYMBOL = 19,
/** Three
* @draft ICU 4.6
*/
UNUM_THREE_DIGIT_SYMBOL = 20,
/** Four
* @draft ICU 4.6
*/
UNUM_FOUR_DIGIT_SYMBOL = 21,
/** Five
* @draft ICU 4.6
*/
UNUM_FIVE_DIGIT_SYMBOL = 22,
/** Six
* @draft ICU 4.6
*/
UNUM_SIX_DIGIT_SYMBOL = 23,
/** Seven
* @draft ICU 4.6
*/
UNUM_SEVEN_DIGIT_SYMBOL = 24,
/** Eight
* @draft ICU 4.6
*/
UNUM_EIGHT_DIGIT_SYMBOL = 25,
/** Nine
* @draft ICU 4.6
*/
UNUM_NINE_DIGIT_SYMBOL = 26,
/** count symbol constants */ /** count symbol constants */
UNUM_FORMAT_SYMBOL_COUNT = 18 UNUM_FORMAT_SYMBOL_COUNT = 27
} UNumberFormatSymbol; } UNumberFormatSymbol;
/** /**
* Get a symbol associated with a UNumberFormat. * Get a symbol associated with a UNumberFormat.
* A UNumberFormat uses symbols to represent the special locale-dependent * A UNumberFormat uses symbols to represent the special locale-dependent
* characters in a number, for example the percent sign. This API is not * characters in a number, for example the percent sign. This API is not
* supported for rule-based formatters. * supported for rule-based formatters.
* @param fmt The formatter to query. * @param fmt The formatter to query.
* @param symbol The UNumberFormatSymbol constant for the symbol to get * @param symbol The UNumberFormatSymbol constant for the symbol to get
* @param buffer The string buffer that will receive the symbol string; * @param buffer The string buffer that will receive the symbol string;
 End of changes. 2 change blocks. 
1 lines changed or deleted 37 lines changed or added


 uregex.h   uregex.h 
skipping to change at line 160 skipping to change at line 160
* @param flags Flags that alter the default matching behavior fo r * @param flags Flags that alter the default matching behavior fo r
* the regular expression, UREGEX_CASE_INSENSITIVE, for * the regular expression, UREGEX_CASE_INSENSITIVE, for
* example. For default behavior, set this paramete r to zero. * example. For default behavior, set this paramete r to zero.
* See <code>enum URegexpFlag</code>. All desired f lags * See <code>enum URegexpFlag</code>. All desired f lags
* are bitwise-ORed together. * are bitwise-ORed together.
* @param pe Receives the position (line and column nubers) of any syntax * @param pe Receives the position (line and column nubers) of any syntax
* error within the source regular expression string . If this * error within the source regular expression string . If this
* information is not wanted, pass NULL for this par ameter. * information is not wanted, pass NULL for this par ameter.
* @param status Receives error detected by this function. * @param status Receives error detected by this function.
* *
* @internal ICU 4.4 technology preview * @draft ICU 4.4
*/ */
U_INTERNAL URegularExpression * U_EXPORT2 U_DRAFT URegularExpression * U_EXPORT2
uregex_openUText(UText *pattern, uregex_openUText(UText *pattern,
uint32_t flags, uint32_t flags,
UParseError *pe, UParseError *pe,
UErrorCode *status); UErrorCode *status);
/** /**
* Open (compile) an ICU regular expression. The resulting regular expre ssion * Open (compile) an ICU regular expression. The resulting regular expre ssion
* handle can then be used to perform various matching operations. * handle can then be used to perform various matching operations.
* <p> * <p>
* This function is the same as uregex_open, except that the pattern * This function is the same as uregex_open, except that the pattern
skipping to change at line 280 skipping to change at line 280
/** /**
* Returns the source text of the pattern for this regular expression. * Returns the source text of the pattern for this regular expression.
* This function will work even if the pattern was originally specified as a UChar string. * This function will work even if the pattern was originally specified as a UChar string.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param status Receives errors detected by this function. * @param status Receives errors detected by this function.
* @return the pattern text. The storage for the text is owned by the regu lar expression * @return the pattern text. The storage for the text is owned by the regu lar expression
* object, and must not be altered or deleted. * object, and must not be altered or deleted.
* *
* @internal ICU 4.4 technology preview * @draft ICU 4.4
*/ */
U_INTERNAL UText * U_EXPORT2 U_DRAFT UText * U_EXPORT2
uregex_patternUText(const URegularExpression *regexp, uregex_patternUText(const URegularExpression *regexp,
UErrorCode *status); UErrorCode *status);
/** /**
* Get the match mode flags that were specified when compiling this regula r expression. * Get the match mode flags that were specified when compiling this regula r expression.
* @param status Receives errors detected by this function. * @param status Receives errors detected by this function.
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @return The match mode flags * @return The match mode flags
* @see URegexpFlag * @see URegexpFlag
* @stable ICU 3.0 * @stable ICU 3.0
skipping to change at line 338 skipping to change at line 338
* <p> * <p>
* Regular expression matching operations work directly on the applicatio n's * Regular expression matching operations work directly on the applicatio n's
* string data; only a shallow clone is made. The subject string data mu st not be * string data; only a shallow clone is made. The subject string data mu st not be
* altered after calling this function until after all regular expression * altered after calling this function until after all regular expression
* operations involving this string data are completed. * operations involving this string data are completed.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param text The subject text string. * @param text The subject text string.
* @param status Receives errors detected by this function. * @param status Receives errors detected by this function.
* *
* @internal ICU 4.4 technology preview * @draft ICU 4.4
*/ */
U_INTERNAL void U_EXPORT2 U_DRAFT void U_EXPORT2
uregex_setUText(URegularExpression *regexp, uregex_setUText(URegularExpression *regexp,
UText *text, UText *text,
UErrorCode *status); UErrorCode *status);
/** /**
* Get the subject text that is currently associated with this * Get the subject text that is currently associated with this
* regular expression object. If the input was supplied using uregex_se tText(), * regular expression object. If the input was supplied using uregex_se tText(),
* that pointer will be returned. Otherwise, the characters in the inpu t will * that pointer will be returned. Otherwise, the characters in the inpu t will
* be extracted to a buffer and returned. In either case, ownership rem ains * be extracted to a buffer and returned. In either case, ownership rem ains
* with the regular expression object. * with the regular expression object.
skipping to change at line 384 skipping to change at line 384
* This function will work even if the input was originally specified as a UChar string. * This function will work even if the input was originally specified as a UChar string.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param dest A mutable UText in which to store the current input. * @param dest A mutable UText in which to store the current input.
* If NULL, a new UText will be created as an immutable shallow clone * If NULL, a new UText will be created as an immutable shallow clone
* of the actual input string. * of the actual input string.
* @param status Receives errors detected by this function. * @param status Receives errors detected by this function.
* @return The subject text currently associated with this regu lar expression. * @return The subject text currently associated with this regu lar expression.
* If a pre-allocated UText was provided, it will alway s be used and returned. * If a pre-allocated UText was provided, it will alway s be used and returned.
* *
* @internal ICU 4.4 technology preview * @draft ICU 4.4
*/ */
U_INTERNAL UText * U_EXPORT2 U_DRAFT UText * U_EXPORT2
uregex_getUText(URegularExpression *regexp, uregex_getUText(URegularExpression *regexp,
UText *dest, UText *dest,
UErrorCode *status); UErrorCode *status);
/** /**
* Attempts to match the input string against the pattern. * Attempts to match the input string against the pattern.
* To succeed, the match must extend to the end of the string, * To succeed, the match must extend to the end of the string,
* or cover the complete match region. * or cover the complete match region.
* *
* If startIndex >= zero the match operation starts at the specified * If startIndex >= zero the match operation starts at the specified
* index and must extend to the end of the input string. Any region * index and must extend to the end of the input string. Any region
* that has been specified is reset. * that has been specified is reset.
* *
* If startIndex == -1 the match must cover the input region, or the ent ire * If startIndex == -1 the match must cover the input region, or the ent ire
* input string if no region has been set. This directly corresponds to * input string if no region has been set. This directly corresponds to
* Matcher.matches() in Java * Matcher.matches() in Java
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param startIndex The input string index at which to begin matchin g, or -1 * @param startIndex The input string (native) index at which to begi n matching, or -1
* to match the input Region. * to match the input Region.
* @param status Receives errors detected by this function. * @param status Receives errors detected by this function.
* @return TRUE if there is a match * @return TRUE if there is a match
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE UBool U_EXPORT2 U_STABLE UBool U_EXPORT2
uregex_matches(URegularExpression *regexp, uregex_matches(URegularExpression *regexp,
int32_t startIndex, int32_t startIndex,
UErrorCode *status); UErrorCode *status);
/** /**
* 64bit version of uregex_matches.
* @draft ICU 4.6
*/
U_DRAFT UBool U_EXPORT2
uregex_matches64(URegularExpression *regexp,
int64_t startIndex,
UErrorCode *status);
/**
* Attempts to match the input string, starting from the specified index , against the pattern. * Attempts to match the input string, starting from the specified index , against the pattern.
* The match may be of any length, and is not required to extend to the end * The match may be of any length, and is not required to extend to the end
* of the input string. Contrast with uregex_matches(). * of the input string. Contrast with uregex_matches().
* *
* <p>If startIndex is >= 0 any input region that was set for this * <p>If startIndex is >= 0 any input region that was set for this
* URegularExpression is reset before the operation begins. * URegularExpression is reset before the operation begins.
* *
* <p>If the specified starting index == -1 the match begins at the star t of the input * <p>If the specified starting index == -1 the match begins at the star t of the input
* region, or at the start of the full string if no region has been spec ified. * region, or at the start of the full string if no region has been spec ified.
* This corresponds directly with Matcher.lookingAt() in Java. * This corresponds directly with Matcher.lookingAt() in Java.
* *
* <p>If the match succeeds then more information can be obtained via th e * <p>If the match succeeds then more information can be obtained via th e
* <code>uregexp_start()</code>, <code>uregexp_end()</code>, * <code>uregexp_start()</code>, <code>uregexp_end()</code>,
* and <code>uregexp_group()</code> functions.</p> * and <code>uregexp_group()</code> functions.</p>
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param startIndex The input string index at which to begin matchi ng, or * @param startIndex The input string (native) index at which to beg in matching, or
* -1 to match the Input Region * -1 to match the Input Region
* @param status A reference to a UErrorCode to receive any erro rs. * @param status A reference to a UErrorCode to receive any erro rs.
* @return TRUE if there is a match. * @return TRUE if there is a match.
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE UBool U_EXPORT2 U_STABLE UBool U_EXPORT2
uregex_lookingAt(URegularExpression *regexp, uregex_lookingAt(URegularExpression *regexp,
int32_t startIndex, int32_t startIndex,
UErrorCode *status); UErrorCode *status);
/** /**
* 64bit version of uregex_lookingAt.
* @draft ICU 4.6
*/
U_DRAFT UBool U_EXPORT2
uregex_lookingAt64(URegularExpression *regexp,
int64_t startIndex,
UErrorCode *status);
/**
* Find the first matching substring of the input string that matches th e pattern. * Find the first matching substring of the input string that matches th e pattern.
* If startIndex is >= zero the search for a match begins at the specifi ed index, * If startIndex is >= zero the search for a match begins at the specifi ed index,
* and any match region is reset. This corresponds directly with * and any match region is reset. This corresponds directly with
* Matcher.find(startIndex) in Java. * Matcher.find(startIndex) in Java.
* *
* If startIndex == -1 the search begins at the start of the input regio n, * If startIndex == -1 the search begins at the start of the input regio n,
* or at the start of the full string if no region has been spec ified. * or at the start of the full string if no region has been spec ified.
* *
* If a match is found, <code>uregex_start(), uregex_end()</code>, and * If a match is found, <code>uregex_start(), uregex_end()</code>, and
* <code>uregex_group()</code> will provide more information regarding t he match. * <code>uregex_group()</code> will provide more information regarding t he match.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param startIndex The position in the input string to begin the se arch, or * @param startIndex The position (native) in the input string to beg in the search, or
* -1 to search within the Input Region. * -1 to search within the Input Region.
* @param status A reference to a UErrorCode to receive any error s. * @param status A reference to a UErrorCode to receive any error s.
* @return TRUE if a match is found. * @return TRUE if a match is found.
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE UBool U_EXPORT2 U_STABLE UBool U_EXPORT2
uregex_find(URegularExpression *regexp, uregex_find(URegularExpression *regexp,
int32_t startIndex, int32_t startIndex,
UErrorCode *status); UErrorCode *status);
/** /**
* 64bit version of uregex_find.
* @draft ICU 4.6
*/
U_DRAFT UBool U_EXPORT2
uregex_find64(URegularExpression *regexp,
int64_t startIndex,
UErrorCode *status);
/**
* Find the next pattern match in the input string. Begin searching * Find the next pattern match in the input string. Begin searching
* the input at the location following the end of he previous match, * the input at the location following the end of he previous match,
* or at the start of the string (or region) if there is no * or at the start of the string (or region) if there is no
* previous match. If a match is found, <code>uregex_start(), uregex_end ()</code>, and * previous match. If a match is found, <code>uregex_start(), uregex_end ()</code>, and
* <code>uregex_group()</code> will provide more information regarding th e match. * <code>uregex_group()</code> will provide more information regarding th e match.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param status A reference to a UErrorCode to receive any errors . * @param status A reference to a UErrorCode to receive any errors .
* @return TRUE if a match is found. * @return TRUE if a match is found.
* @see uregex_reset * @see uregex_reset
skipping to change at line 519 skipping to change at line 546
* or -1 if no applicable match. * or -1 if no applicable match.
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE int32_t U_EXPORT2 U_STABLE int32_t U_EXPORT2
uregex_group(URegularExpression *regexp, uregex_group(URegularExpression *regexp,
int32_t groupNum, int32_t groupNum,
UChar *dest, UChar *dest,
int32_t destCapacity, int32_t destCapacity,
UErrorCode *status); UErrorCode *status);
/** Returns a shallow immutable clone of the entire input string. The retu
rned UText current native index
* is set to the beginning of the requested capture group. The capture
group length is also
* returned via groupLength.
* Group #0 is the complete string of matched text.
* Group #1 is the text matched by the first set of capturing parentheses.
*
* @param regexp The compiled regular expression.
* @param groupNum The capture group to extract. Group 0 is the c
omplete
* match. The value of this parameter must be
* less than or equal to the number of capture gro
ups in
* the pattern.
* @param dest A mutable UText in which to store the current i
nput.
* If NULL, a new UText will be created as an immu
table shallow clone
* of the entire input string.
* @param groupLength The group length of the desired capture group.
* @param status A reference to a UErrorCode to receive any erro
rs.
* @return The subject text currently associated with this
regular expression.
* If a pre-allocated UText was provided, it will
always be used and returned.
*
* @draft ICU 4.6
*/
U_DRAFT UText * U_EXPORT2
uregex_groupUText(URegularExpression *regexp,
int32_t groupNum,
UText *dest,
int64_t *groupLength,
UErrorCode *status);
/** Extract the string for the specified matching expression or subexpressi on. /** Extract the string for the specified matching expression or subexpressi on.
* Group #0 is the complete string of matched text. * Group #0 is the complete string of matched text.
* Group #1 is the text matched by the first set of capturing parentheses. * Group #1 is the text matched by the first set of capturing parentheses.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param groupNum The capture group to extract. Group 0 is the c omplete * @param groupNum The capture group to extract. Group 0 is the c omplete
* match. The value of this parameter must be * match. The value of this parameter must be
* less than or equal to the number of capture gro ups in * less than or equal to the number of capture gro ups in
* the pattern. * the pattern.
* @param dest Mutable UText to receive the matching string da ta. * @param dest Mutable UText to receive the matching string da ta.
* If NULL, a new UText will be created (which may not be mutable). * If NULL, a new UText will be created (which may not be mutable).
* @param status A reference to a UErrorCode to receive any erro rs. * @param status A reference to a UErrorCode to receive any erro rs.
* @return The matching string data. If a pre-allocated UT ext was provided, * @return The matching string data. If a pre-allocated UT ext was provided,
* it will always be used and returned. * it will always be used and returned.
* *
* @internal ICU 4.4 technology preview * @internal ICU 4.4 technology preview
*/ */
U_INTERNAL UText * U_EXPORT2 U_INTERNAL UText * U_EXPORT2
uregex_groupUText(URegularExpression *regexp, uregex_groupUTextDeep(URegularExpression *regexp,
int32_t groupNum, int32_t groupNum,
UText *dest, UText *dest,
UErrorCode *status); UErrorCode *status);
/** /**
* Returns the index in the input string of the start of the text matche d by the * Returns the index in the input string of the start of the text matche d by the
* specified capture group during the previous match operation. Return -1 if * specified capture group during the previous match operation. Return -1 if
* the capture group was not part of the last match. * the capture group was not part of the last match.
* Group #0 refers to the complete range of matched text. * Group #0 refers to the complete range of matched text.
* Group #1 refers to the text matched by the first set of capturing par entheses. * Group #1 refers to the text matched by the first set of capturing par entheses.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param groupNum The capture group number * @param groupNum The capture group number
* @param status A reference to a UErrorCode to receive any erro rs. * @param status A reference to a UErrorCode to receive any erro rs.
* @return the starting position in the input of the text matched * @return the starting (native) position in the input of the text matched
* by the specified group. * by the specified group.
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE int32_t U_EXPORT2 U_STABLE int32_t U_EXPORT2
uregex_start(URegularExpression *regexp, uregex_start(URegularExpression *regexp,
int32_t groupNum, int32_t groupNum,
UErrorCode *status); UErrorCode *status);
/** /**
* 64bit version of uregex_start.
* @draft ICU 4.6
*/
U_DRAFT int64_t U_EXPORT2
uregex_start64(URegularExpression *regexp,
int32_t groupNum,
UErrorCode *status);
/**
* Returns the index in the input string of the position following the e nd * Returns the index in the input string of the position following the e nd
* of the text matched by the specified capture group. * of the text matched by the specified capture group.
* Return -1 if the capture group was not part of the last match. * Return -1 if the capture group was not part of the last match.
* Group #0 refers to the complete range of matched text. * Group #0 refers to the complete range of matched text.
* Group #1 refers to the text matched by the first set of capturing par entheses. * Group #1 refers to the text matched by the first set of capturing par entheses.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param groupNum The capture group number * @param groupNum The capture group number
* @param status A reference to a UErrorCode to receive any erro rs. * @param status A reference to a UErrorCode to receive any erro rs.
* @return the index of the position following the last ma tched character. * @return the (native) index of the position following th e last matched character.
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE int32_t U_EXPORT2 U_STABLE int32_t U_EXPORT2
uregex_end(URegularExpression *regexp, uregex_end(URegularExpression *regexp,
int32_t groupNum, int32_t groupNum,
UErrorCode *status); UErrorCode *status);
/** /**
* 64bit version of uregex_end.
* @draft ICU 4.6
*/
U_DRAFT int64_t U_EXPORT2
uregex_end64(URegularExpression *regexp,
int32_t groupNum,
UErrorCode *status);
/**
* Reset any saved state from the previous match. Has the effect of * Reset any saved state from the previous match. Has the effect of
* causing uregex_findNext to begin at the specified index, and causing * causing uregex_findNext to begin at the specified index, and causing
* uregex_start(), uregex_end() and uregex_group() to return an error * uregex_start(), uregex_end() and uregex_group() to return an error
* indicating that there is no match information available. Clears any * indicating that there is no match information available. Clears any
* match region that may have been set. * match region that may have been set.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param index The position in the text at which a * @param index The position (native) in the text at which a
* uregex_findNext() should begin searching. * uregex_findNext() should begin searching.
* @param status A reference to a UErrorCode to receive any erro rs. * @param status A reference to a UErrorCode to receive any erro rs.
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE void U_EXPORT2 U_STABLE void U_EXPORT2
uregex_reset(URegularExpression *regexp, uregex_reset(URegularExpression *regexp,
int32_t index, int32_t index,
UErrorCode *status); UErrorCode *status);
/**
* 64bit version of uregex_reset.
* @draft ICU 4.6
*/
U_DRAFT void U_EXPORT2
uregex_reset64(URegularExpression *regexp,
int64_t index,
UErrorCode *status);
/** Sets the limits of the matching region for this URegularExpression. /** Sets the limits of the matching region for this URegularExpression.
* The region is the part of the input string that will be considered when matching. * The region is the part of the input string that will be considered when matching.
* Invoking this method resets any saved state from the previous match, * Invoking this method resets any saved state from the previous match,
* then sets the region to start at the index specified by the start param eter * then sets the region to start at the index specified by the start param eter
* and end at the index specified by the end parameter. * and end at the index specified by the end parameter.
* *
* Depending on the transparency and anchoring being used (see useTranspar entBounds * Depending on the transparency and anchoring being used (see useTranspar entBounds
* and useAnchoringBounds), certain constructs such as anchors may behave differently * and useAnchoringBounds), certain constructs such as anchors may behave differently
* at or around the boundaries of the region * at or around the boundaries of the region
* *
* The function will fail if start is greater than limit, or if either ind ex * The function will fail if start is greater than limit, or if either ind ex
* is less than zero or greater than the length of the string being match ed. * is less than zero or greater than the length of the string being match ed.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param regionStart The index to begin searches at. * @param regionStart The (native) index to begin searches at.
* @param regionLimit The index to end searches at (exclusive). * @param regionLimit The (native) index to end searches at (exclusive).
* @param status A pointer to a UErrorCode to receive any errors. * @param status A pointer to a UErrorCode to receive any errors.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
U_STABLE void U_EXPORT2 U_STABLE void U_EXPORT2
uregex_setRegion(URegularExpression *regexp, uregex_setRegion(URegularExpression *regexp,
int32_t regionStart, int32_t regionStart,
int32_t regionLimit, int32_t regionLimit,
UErrorCode *status); UErrorCode *status);
/** /**
* 64bit version of uregex_setRegion.
* @draft ICU 4.6
*/
U_DRAFT void U_EXPORT2
uregex_setRegion64(URegularExpression *regexp,
int64_t regionStart,
int64_t regionLimit,
UErrorCode *status);
/**
* Variation on uregex_setRegion to set the region without resetting the
start index
* without resetting the position for subsequent matches.
* @draft ICU 4.6
*/
U_DRAFT void U_EXPORT2
uregex_setRegionAndStart(URegularExpression *regexp,
int64_t regionStart,
int64_t regionLimit,
int64_t startIndex,
UErrorCode *status);
/**
* Reports the start index of the matching region. Any matches found are l imited to * Reports the start index of the matching region. Any matches found are l imited to
* to the region bounded by regionStart (inclusive) and regionEnd (exclusi ve). * to the region bounded by regionStart (inclusive) and regionEnd (exclusi ve).
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param status A pointer to a UErrorCode to receive any errors. * @param status A pointer to a UErrorCode to receive any errors.
* @return The starting index of this matcher's region. * @return The starting (native) index of this matcher's region.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
U_STABLE int32_t U_EXPORT2 U_STABLE int32_t U_EXPORT2
uregex_regionStart(const URegularExpression *regexp, uregex_regionStart(const URegularExpression *regexp,
UErrorCode *status); UErrorCode *status);
/** /**
* 64bit version of uregex_regionStart.
* @draft ICU 4.6
*/
U_DRAFT int64_t U_EXPORT2
uregex_regionStart64(const URegularExpression *regexp,
UErrorCode *status);
/**
* Reports the end index (exclusive) of the matching region for this URegu larExpression. * Reports the end index (exclusive) of the matching region for this URegu larExpression.
* Any matches found are limited to to the region bounded by regionStart ( inclusive) * Any matches found are limited to to the region bounded by regionStart ( inclusive)
* and regionEnd (exclusive). * and regionEnd (exclusive).
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param status A pointer to a UErrorCode to receive any errors. * @param status A pointer to a UErrorCode to receive any errors.
* @return The ending point of this matcher's region. * @return The ending point (native) of this matcher's region.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
U_STABLE int32_t U_EXPORT2 U_STABLE int32_t U_EXPORT2
uregex_regionEnd(const URegularExpression *regexp, uregex_regionEnd(const URegularExpression *regexp,
UErrorCode *status); UErrorCode *status);
/** /**
* 64bit version of uregex_regionEnd.
* @draft ICU 4.6
*/
U_DRAFT int64_t U_EXPORT2
uregex_regionEnd64(const URegularExpression *regexp,
UErrorCode *status);
/**
* Queries the transparency of region bounds for this URegularExpression. * Queries the transparency of region bounds for this URegularExpression.
* See useTransparentBounds for a description of transparent and opaque bo unds. * See useTransparentBounds for a description of transparent and opaque bo unds.
* By default, matching boundaries are opaque. * By default, matching boundaries are opaque.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param status A pointer to a UErrorCode to receive any errors. * @param status A pointer to a UErrorCode to receive any errors.
* @return TRUE if this matcher is using opaque bounds, false if it is not . * @return TRUE if this matcher is using opaque bounds, false if it is not .
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
U_STABLE UBool U_EXPORT2 U_STABLE UBool U_EXPORT2
skipping to change at line 798 skipping to change at line 919
* references to capture groups; these take the form of $1, $2, etc. * references to capture groups; these take the form of $1, $2, etc.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param replacement A string containing the replacement text. * @param replacement A string containing the replacement text.
* @param dest A mutable UText that will receive the result . * @param dest A mutable UText that will receive the result .
* If NULL, a new UText will be created (which may not be mutable). * If NULL, a new UText will be created (which may not be mutable).
* @param status A reference to a UErrorCode to receive any e rrors. * @param status A reference to a UErrorCode to receive any e rrors.
* @return A UText containing the results of the find a nd replace. * @return A UText containing the results of the find a nd replace.
* If a pre-allocated UText was provided, it w ill always be used and returned. * If a pre-allocated UText was provided, it w ill always be used and returned.
* *
* @internal ICU 4.4 technology preview * @draft ICU 4.4
*/ */
U_INTERNAL UText * U_EXPORT2 U_DRAFT UText * U_EXPORT2
uregex_replaceAllUText(URegularExpression *regexp, uregex_replaceAllUText(URegularExpression *regexp,
UText *replacement, UText *replacement,
UText *dest, UText *dest,
UErrorCode *status); UErrorCode *status);
/** /**
* Replaces the first substring of the input that matches the pattern * Replaces the first substring of the input that matches the pattern
* with the given replacement string. This is a convenience function t hat * with the given replacement string. This is a convenience function t hat
* provides a complete find-and-replace operation. * provides a complete find-and-replace operation.
* *
skipping to change at line 857 skipping to change at line 978
* references to capture groups; these take the form of $1, $2, etc. * references to capture groups; these take the form of $1, $2, etc.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param replacement A string containing the replacement text. * @param replacement A string containing the replacement text.
* @param dest A mutable UText that will receive the result . * @param dest A mutable UText that will receive the result .
* If NULL, a new UText will be created (which may not be mutable). * If NULL, a new UText will be created (which may not be mutable).
* @param status A reference to a UErrorCode to receive any e rrors. * @param status A reference to a UErrorCode to receive any e rrors.
* @return A UText containing the results of the find a nd replace. * @return A UText containing the results of the find a nd replace.
* If a pre-allocated UText was provided, it w ill always be used and returned. * If a pre-allocated UText was provided, it w ill always be used and returned.
* *
* @internal ICU 4.4 technology preview * @draft ICU 4.4
*/ */
U_INTERNAL UText * U_EXPORT2 U_DRAFT UText * U_EXPORT2
uregex_replaceFirstUText(URegularExpression *regexp, uregex_replaceFirstUText(URegularExpression *regexp,
UText *replacement, UText *replacement,
UText *dest, UText *dest,
UErrorCode *status); UErrorCode *status);
/** /**
* Implements a replace operation intended to be used as part of an * Implements a replace operation intended to be used as part of an
* incremental find-and-replace. * incremental find-and-replace.
* *
* <p>The input string, starting from the end of the previous match and ending at * <p>The input string, starting from the end of the previous match and ending at
skipping to change at line 939 skipping to change at line 1060
* operations, see replaceFirst() or replaceAll().</p> * operations, see replaceFirst() or replaceAll().</p>
* *
* @param regexp The regular expression object. * @param regexp The regular expression object.
* @param replacementText The string that will replace the matched por tion of the * @param replacementText The string that will replace the matched por tion of the
* input string as it is copied to the destination buffer. * input string as it is copied to the destination buffer.
* The replacement text may contain references ($1, for * The replacement text may contain references ($1, for
* example) to capture groups from the match. * example) to capture groups from the match.
* @param dest A mutable UText that will receive the result. Mu st not be NULL. * @param dest A mutable UText that will receive the result. Mu st not be NULL.
* @param status A reference to a UErrorCode to receive any error s. * @param status A reference to a UErrorCode to receive any error s.
* *
* @internal ICU 4.4 technology preview * @draft ICU 4.4
*/ */
U_INTERNAL void U_EXPORT2 U_DRAFT void U_EXPORT2
uregex_appendReplacementUText(URegularExpression *regexp, uregex_appendReplacementUText(URegularExpression *regexp,
UText *replacementText, UText *replacementText,
UText *dest, UText *dest,
UErrorCode *status); UErrorCode *status);
/** /**
* As the final step in a find-and-replace operation, append the remainder * As the final step in a find-and-replace operation, append the remainder
* of the input string, starting at the position following the last match, * of the input string, starting at the position following the last match,
* to the destination string. <code>uregex_appendTail()</code> is intended * to the destination string. <code>uregex_appendTail()</code> is intended
* to be invoked after one or more invocations of the * to be invoked after one or more invocations of the
skipping to change at line 990 skipping to change at line 1111
* to the destination string. <code>uregex_appendTailUText()</code> is int ended * to the destination string. <code>uregex_appendTailUText()</code> is int ended
* to be invoked after one or more invocations of the * to be invoked after one or more invocations of the
* <code>uregex_appendReplacementUText()</code> function. * <code>uregex_appendReplacementUText()</code> function.
* *
* @param regexp The regular expression object. This is needed t o * @param regexp The regular expression object. This is needed t o
* obtain the input string and with the position * obtain the input string and with the position
* of the last match within it. * of the last match within it.
* @param dest A mutable UText that will receive the result. Mu st not be NULL. * @param dest A mutable UText that will receive the result. Mu st not be NULL.
* @return The destination UText. * @return The destination UText.
* *
* @internal ICU 4.4 technology preview * @draft ICU 4.6
*/ */
U_INTERNAL UText * U_EXPORT2 U_DRAFT UText * U_EXPORT2
uregex_appendTailUText(URegularExpression *regexp, uregex_appendTailUText(URegularExpression *regexp,
UText *dest); UText *dest,
UErrorCode *status);
/** /**
* Split a string into fields. Somewhat like split() from Perl. * Split a string into fields. Somewhat like split() from Perl.
* The pattern matches identify delimiters that separate the input * The pattern matches identify delimiters that separate the input
* into fields. The input data between the matches becomes the * into fields. The input data between the matches becomes the
* fields themselves. * fields themselves.
* <p> * <p>
* Each of the fields is copied from the input string to the destination * Each of the fields is copied from the input string to the destination
* buffer, and NUL terminated. The position of each field within * buffer, and NUL terminated. The position of each field within
* the destination buffer is returned in the destFields array. * the destination buffer is returned in the destFields array.
skipping to change at line 1083 skipping to change at line 1205
* If the number of fields found is less than destCapacity , the * If the number of fields found is less than destCapacity , the
* extra strings in the destination array are not altered. * extra strings in the destination array are not altered.
* If the number of destination strings is less than the n umber * If the number of destination strings is less than the n umber
* of fields, the trailing part of the input string, inclu ding any * of fields, the trailing part of the input string, inclu ding any
* field delimiters, is placed in the last destination str ing. * field delimiters, is placed in the last destination str ing.
* This behavior mimics that of Perl. It is not an error condition, and no * This behavior mimics that of Perl. It is not an error condition, and no
* error status is returned when all destField positions a re used. * error status is returned when all destField positions a re used.
* @param status A reference to a UErrorCode to receive any errors. * @param status A reference to a UErrorCode to receive any errors.
* @return The number of fields into which the input string was sp lit. * @return The number of fields into which the input string was sp lit.
* *
* @internal ICU 4.4 technology preview * @draft ICU 4.4
*/ */
U_INTERNAL int32_t U_EXPORT2 U_DRAFT int32_t U_EXPORT2
uregex_splitUText(URegularExpression *regexp, uregex_splitUText(URegularExpression *regexp,
UText *destFields[], UText *destFields[],
int32_t destFieldsCapacity, int32_t destFieldsCapacity,
UErrorCode *status); UErrorCode *status);
/** /**
* Set a processing time limit for match operations with this URegularExpre ssion. * Set a processing time limit for match operations with this URegularExpre ssion.
* *
* Some patterns, when matching certain strings, can run in exponential tim e. * Some patterns, when matching certain strings, can run in exponential tim e.
* For practical purposes, the match operation may appear to be in an * For practical purposes, the match operation may appear to be in an
skipping to change at line 1229 skipping to change at line 1351
* @param status A reference to a UErrorCode to receive any errors. * @param status A reference to a UErrorCode to receive any errors.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
U_STABLE void U_EXPORT2 U_STABLE void U_EXPORT2
uregex_getMatchCallback(const URegularExpression *regexp, uregex_getMatchCallback(const URegularExpression *regexp,
URegexMatchCallback **callback, URegexMatchCallback **callback,
const void **context, const void **context,
UErrorCode *status); UErrorCode *status);
/** /**
* Function pointer for a regular expression find/findNext callback functio * Function pointer for a regular expression find callback function.
n. *
* When set, a callback function will be called during a find operation aft * When set, a callback function will be called during a find operation
er each * and for operations that depend on find, such as findNext, split and some
* attempt at a match. If the call back function returns FALSE, the find replace
* operation will be terminated early. * operations like replaceFirst.
* The callback will usually be called after each attempt at a match, but t
his is not a
* guarantee that the callback will be invoked at each character. For find
s where the
* match engine is invoked at each character, this may be close to true, bu
t less likely
* for more optimized loops where the pattern is known to only start, and t
he match
* engine invoked, at certain characters.
* When invoked, this callback will specify the index at which a match oper
ation is about
* to be attempted, giving the application the opportunity to terminate a l
ong-running
* find operation.
*
* If the call back function returns FALSE, the find operation will be term
inated early.
* *
* Note: the callback function must not call other functions on this * Note: the callback function must not call other functions on this
* URegularExpression * URegularExpression
* *
* @param context context pointer. The callback function will be invoked * @param context context pointer. The callback function will be invoked
* with the context specified at the time that * with the context specified at the time that
* uregex_setFindProgressCallback() is called. * uregex_setFindProgressCallback() is called.
* @param matchIndex the next index at which a match attempt will be attem pted for this * @param matchIndex the next index at which a match attempt will be attem pted for this
* find operation. If this callback interrupts the search, this is the * find operation. If this callback interrupts the search, this is the
* index at which a find/findNext operation may be re-initi ated. * index at which a find/findNext operation may be re-initi ated.
skipping to change at line 1254 skipping to change at line 1387
* FALSE to terminate the matching operation. * FALSE to terminate the matching operation.
* @draft ICU 4.6 * @draft ICU 4.6
*/ */
U_CDECL_BEGIN U_CDECL_BEGIN
typedef UBool U_CALLCONV URegexFindProgressCallback ( typedef UBool U_CALLCONV URegexFindProgressCallback (
const void *context, const void *context,
int64_t matchIndex); int64_t matchIndex);
U_CDECL_END U_CDECL_END
/** /**
* During find operations, this callback will be invoked after each return * Set the find progress callback function for this URegularExpression.
from a
* match attempt, specifying the next index at which a match operation is a
bout to be attempted,
* giving the application the opportunity to terminate a long-running find
operation.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param callback A pointer to the user-supplied callback function. * @param callback A pointer to the user-supplied callback function.
* @param context User context pointer. The value supplied at the * @param context User context pointer. The value supplied at the
* time the callback function is set will be saved * time the callback function is set will be saved
* and passed to the callback each time that it is cal led. * and passed to the callback each time that it is cal led.
* @param status A reference to a UErrorCode to receive any errors. * @param status A reference to a UErrorCode to receive any errors.
* @draft ICU 4.6 * @draft ICU 4.6
*/ */
U_DRAFT void U_EXPORT2 U_DRAFT void U_EXPORT2
uregex_setFindProgressCallback(URegularExpression *regexp, uregex_setFindProgressCallback(URegularExpression *regexp,
URegexFindProgressCallback *callback, URegexFindProgressCallback *callback,
const void *context, const void *context,
UErrorCode *status); UErrorCode *status);
/** /**
* Get the callback function for this URegularExpression. * Get the find progress callback function for this URegularExpression.
* *
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param callback Out paramater, receives a pointer to the user-suppl ied * @param callback Out paramater, receives a pointer to the user-suppl ied
* callback function. * callback function.
* @param context Out parameter, receives the user context pointer th at * @param context Out parameter, receives the user context pointer th at
* was set when uregex_setFindProgressCallback() was c alled. * was set when uregex_setFindProgressCallback() was c alled.
* @param status A reference to a UErrorCode to receive any errors. * @param status A reference to a UErrorCode to receive any errors.
* @draft ICU 4.6 * @draft ICU 4.6
*/ */
U_DRAFT void U_EXPORT2 U_DRAFT void U_EXPORT2
 End of changes. 42 change blocks. 
43 lines changed or deleted 187 lines changed or added


 uscript.h   uscript.h 
/* /*
********************************************************************** **********************************************************************
* Copyright (C) 1997-2009, International Business Machines * Copyright (C) 1997-2010, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
********************************************************************** **********************************************************************
* *
* File USCRIPT.H * File USCRIPT.H
* *
* Modification History: * Modification History:
* *
* Date Name Description * Date Name Description
* 07/06/2001 Ram Creation. * 07/06/2001 Ram Creation.
************************************************************************** **** ************************************************************************** ****
skipping to change at line 48 skipping to change at line 48
* For example, there are no characters that have a UCD script code of * For example, there are no characters that have a UCD script code of
* Hans or Hant. All Han ideographs have the Hani script code. * Hans or Hant. All Han ideographs have the Hani script code.
* The Hans and Hant script codes are used with CLDR data. * The Hans and Hant script codes are used with CLDR data.
* *
* ISO 15924 script codes are included for use with CLDR and similar. * ISO 15924 script codes are included for use with CLDR and similar.
* *
* @stable ICU 2.2 * @stable ICU 2.2
*/ */
typedef enum UScriptCode { typedef enum UScriptCode {
USCRIPT_INVALID_CODE = -1, USCRIPT_INVALID_CODE = -1,
USCRIPT_COMMON = 0 , /* Zyyy */ USCRIPT_COMMON = 0, /* Zyyy */
USCRIPT_INHERITED = 1, /* Zinh */ /* "Code for inherited script" , for non-spacing combining marks; also Qaai */ USCRIPT_INHERITED = 1, /* Zinh */ /* "Code for inherited script" , for non-spacing combining marks; also Qaai */
USCRIPT_ARABIC = 2, /* Arab */ USCRIPT_ARABIC = 2, /* Arab */
USCRIPT_ARMENIAN = 3, /* Armn */ USCRIPT_ARMENIAN = 3, /* Armn */
USCRIPT_BENGALI = 4, /* Beng */ USCRIPT_BENGALI = 4, /* Beng */
USCRIPT_BOPOMOFO = 5, /* Bopo */ USCRIPT_BOPOMOFO = 5, /* Bopo */
USCRIPT_CHEROKEE = 6, /* Cher */ USCRIPT_CHEROKEE = 6, /* Cher */
USCRIPT_COPTIC = 7, /* Copt */ USCRIPT_COPTIC = 7, /* Copt */
USCRIPT_CYRILLIC = 8, /* Cyrl */ USCRIPT_CYRILLIC = 8, /* Cyrl */
USCRIPT_DESERET = 9, /* Dsrt */ USCRIPT_DESERET = 9, /* Dsrt */
USCRIPT_DEVANAGARI = 10, /* Deva */ USCRIPT_DEVANAGARI = 10, /* Deva */
skipping to change at line 143 skipping to change at line 143
USCRIPT_TRADITIONAL_HAN = 74, /* Hant */ USCRIPT_TRADITIONAL_HAN = 74, /* Hant */
USCRIPT_PAHAWH_HMONG = 75, /* Hmng */ USCRIPT_PAHAWH_HMONG = 75, /* Hmng */
USCRIPT_OLD_HUNGARIAN = 76, /* Hung */ USCRIPT_OLD_HUNGARIAN = 76, /* Hung */
USCRIPT_HARAPPAN_INDUS = 77, /* Inds */ USCRIPT_HARAPPAN_INDUS = 77, /* Inds */
USCRIPT_JAVANESE = 78, /* Java */ USCRIPT_JAVANESE = 78, /* Java */
USCRIPT_KAYAH_LI = 79, /* Kali */ USCRIPT_KAYAH_LI = 79, /* Kali */
USCRIPT_LATIN_FRAKTUR = 80, /* Latf */ USCRIPT_LATIN_FRAKTUR = 80, /* Latf */
USCRIPT_LATIN_GAELIC = 81, /* Latg */ USCRIPT_LATIN_GAELIC = 81, /* Latg */
USCRIPT_LEPCHA = 82, /* Lepc */ USCRIPT_LEPCHA = 82, /* Lepc */
USCRIPT_LINEAR_A = 83, /* Lina */ USCRIPT_LINEAR_A = 83, /* Lina */
USCRIPT_MANDAEAN = 84, /* Mand */ /** @stable ICU 4.6 */
USCRIPT_MANDAIC = 84, /* Mand */
/** @stable ICU 3.6 */
USCRIPT_MANDAEAN = USCRIPT_MANDAIC,
USCRIPT_MAYAN_HIEROGLYPHS = 85, /* Maya */ USCRIPT_MAYAN_HIEROGLYPHS = 85, /* Maya */
USCRIPT_MEROITIC = 86, /* Mero */ /** @stable ICU 4.6 */
USCRIPT_MEROITIC_HIEROGLYPHS = 86, /* Mero */
/** @stable ICU 3.6 */
USCRIPT_MEROITIC = USCRIPT_MEROITIC_HIEROGLYPHS,
USCRIPT_NKO = 87, /* Nkoo */ USCRIPT_NKO = 87, /* Nkoo */
USCRIPT_ORKHON = 88, /* Orkh */ USCRIPT_ORKHON = 88, /* Orkh */
USCRIPT_OLD_PERMIC = 89, /* Perm */ USCRIPT_OLD_PERMIC = 89, /* Perm */
USCRIPT_PHAGS_PA = 90, /* Phag */ USCRIPT_PHAGS_PA = 90, /* Phag */
USCRIPT_PHOENICIAN = 91, /* Phnx */ USCRIPT_PHOENICIAN = 91, /* Phnx */
USCRIPT_PHONETIC_POLLARD = 92, /* Plrd */ USCRIPT_PHONETIC_POLLARD = 92, /* Plrd */
USCRIPT_RONGORONGO = 93, /* Roro */ USCRIPT_RONGORONGO = 93, /* Roro */
USCRIPT_SARATI = 94, /* Sara */ USCRIPT_SARATI = 94, /* Sara */
USCRIPT_ESTRANGELO_SYRIAC = 95, /* Syre */ USCRIPT_ESTRANGELO_SYRIAC = 95, /* Syre */
USCRIPT_WESTERN_SYRIAC = 96, /* Syrj */ USCRIPT_WESTERN_SYRIAC = 96, /* Syrj */
skipping to change at line 194 skipping to change at line 200
USCRIPT_MANICHAEAN = 121,/* Mani */ USCRIPT_MANICHAEAN = 121,/* Mani */
USCRIPT_INSCRIPTIONAL_PAHLAVI = 122,/* Phli */ USCRIPT_INSCRIPTIONAL_PAHLAVI = 122,/* Phli */
USCRIPT_PSALTER_PAHLAVI = 123,/* Phlp */ USCRIPT_PSALTER_PAHLAVI = 123,/* Phlp */
USCRIPT_BOOK_PAHLAVI = 124,/* Phlv */ USCRIPT_BOOK_PAHLAVI = 124,/* Phlv */
USCRIPT_INSCRIPTIONAL_PARTHIAN = 125,/* Prti */ USCRIPT_INSCRIPTIONAL_PARTHIAN = 125,/* Prti */
USCRIPT_SAMARITAN = 126,/* Samr */ USCRIPT_SAMARITAN = 126,/* Samr */
USCRIPT_TAI_VIET = 127,/* Tavt */ USCRIPT_TAI_VIET = 127,/* Tavt */
USCRIPT_MATHEMATICAL_NOTATION = 128,/* Zmth */ USCRIPT_MATHEMATICAL_NOTATION = 128,/* Zmth */
USCRIPT_SYMBOLS = 129,/* Zsym */ USCRIPT_SYMBOLS = 129,/* Zsym */
/* New script codes from ISO 15924 @draft ICU 4.4 */ /* New script codes from ISO 15924 @stable ICU 4.4 */
USCRIPT_BAMUM = 130,/* Bamu */ USCRIPT_BAMUM = 130,/* Bamu */
USCRIPT_LISU = 131,/* Lisu */ USCRIPT_LISU = 131,/* Lisu */
USCRIPT_NAKHI_GEBA = 132,/* Nkgb */ USCRIPT_NAKHI_GEBA = 132,/* Nkgb */
USCRIPT_OLD_SOUTH_ARABIAN = 133,/* Sarb */ USCRIPT_OLD_SOUTH_ARABIAN = 133,/* Sarb */
/* Private use codes from Qaaa - Qabx are not supported*/ /* New script codes from ISO 15924 @stable ICU 4.6 */
USCRIPT_CODE_LIMIT = 134 USCRIPT_BASSA_VAH = 134,/* Bass */
USCRIPT_DUPLOYAN_SHORTAND = 135,/* Dupl */
USCRIPT_ELBASAN = 136,/* Elba */
USCRIPT_GRANTHA = 137,/* Gran */
USCRIPT_KPELLE = 138,/* Kpel */
USCRIPT_LOMA = 139,/* Loma */
USCRIPT_MENDE = 140,/* Mend */
USCRIPT_MEROITIC_CURSIVE = 141,/* Merc */
USCRIPT_OLD_NORTH_ARABIAN = 142,/* Narb */
USCRIPT_NABATAEAN = 143,/* Nbat */
USCRIPT_PALMYRENE = 144,/* Palm */
USCRIPT_SINDHI = 145,/* Sind */
USCRIPT_WARANG_CITI = 146,/* Wara */
/* Private use codes from Qaaa - Qabx are not supported */
USCRIPT_CODE_LIMIT = 147
} UScriptCode; } UScriptCode;
/** /**
* Gets script codes associated with the given locale or ISO 15924 abbrevia tion or name. * Gets script codes associated with the given locale or ISO 15924 abbrevia tion or name.
* Fills in USCRIPT_MALAYALAM given "Malayam" OR "Mlym". * Fills in USCRIPT_MALAYALAM given "Malayam" OR "Mlym".
* Fills in USCRIPT_LATIN given "en" OR "en_US" * Fills in USCRIPT_LATIN given "en" OR "en_US"
* If required capacity is greater than capacity of the destination buffer then the error code * If required capacity is greater than capacity of the destination buffer then the error code
* is set to U_BUFFER_OVERFLOW_ERROR and the required capacity is returned * is set to U_BUFFER_OVERFLOW_ERROR and the required capacity is returned
* *
* <p>Note: To search by short or long script alias only, use * <p>Note: To search by short or long script alias only, use
skipping to change at line 258 skipping to change at line 279
* Gets the script code associated with the given codepoint. * Gets the script code associated with the given codepoint.
* Returns USCRIPT_MALAYALAM given 0x0D02 * Returns USCRIPT_MALAYALAM given 0x0D02
* @param codepoint UChar32 codepoint * @param codepoint UChar32 codepoint
* @param err the error status code. * @param err the error status code.
* @return The UScriptCode, or 0 if codepoint is invalid * @return The UScriptCode, or 0 if codepoint is invalid
* @stable ICU 2.4 * @stable ICU 2.4
*/ */
U_STABLE UScriptCode U_EXPORT2 U_STABLE UScriptCode U_EXPORT2
uscript_getScript(UChar32 codepoint, UErrorCode *err); uscript_getScript(UChar32 codepoint, UErrorCode *err);
/**
* Is code point c used in script sc?
* That is, does code point c have the Script property value sc,
* or do code point c's Script_Extensions include script code sc?
*
* Some characters are commonly used in multiple scripts.
* For more information, see UAX #24: http://www.unicode.org/reports/tr24/.
*
* The Script_Extensions property is provisional. It may be modified or rem
oved
* in future versions of the Unicode Standard, and thus in ICU.
* @param c code point
* @param sc script code
* @return TRUE if Script(c)==sc or sc is in Script_Extensions(c)
* @draft ICU 4.6
*/
U_DRAFT UBool U_EXPORT2
uscript_hasScript(UChar32 c, UScriptCode sc);
/**
* Writes code point c's Script_Extensions as a list of UScriptCode values
* to the output scripts array.
*
* Some characters are commonly used in multiple scripts.
* For more information, see UAX #24: http://www.unicode.org/reports/tr24/.
*
* If there are more than capacity script codes to be written, then
* U_BUFFER_OVERFLOW_ERROR is set and the number of Script_Extensions is re
turned.
* (Usual ICU buffer handling behavior.)
*
* The Script_Extensions property is provisional. It may be modified or rem
oved
* in future versions of the Unicode Standard, and thus in ICU.
* @param c code point
* @param scripts output script code array
* @param capacity capacity of the scripts array
* @param errorCode Standard ICU error code. Its input value must
* pass the U_SUCCESS() test, or else the function returns
* immediately. Check for U_FAILURE() on output or use wit
h
* function chaining. (See User Guide for details.)
* @return number of script codes in c's Script_Extensions,
* written to scripts unless U_BUFFER_OVERFLOW_ERROR indicates insu
fficient capacity
* @draft ICU 4.6
*/
U_DRAFT int32_t U_EXPORT2
uscript_getScriptExtensions(UChar32 c,
UScriptCode *scripts, int32_t capacity,
UErrorCode *pErrorCode);
#endif #endif
 End of changes. 7 change blocks. 
7 lines changed or deleted 80 lines changed or added


 ustdio.h   ustdio.h 
skipping to change at line 304 skipping to change at line 304
* be used. * be used.
* @return A new UFILE, or NULL if an error occurred. * @return A new UFILE, or NULL if an error occurred.
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE UFILE* U_EXPORT2 U_STABLE UFILE* U_EXPORT2
u_fstropen(UChar *stringBuf, u_fstropen(UChar *stringBuf,
int32_t capacity, int32_t capacity,
const char *locale); const char *locale);
/** /**
* Close a UFILE. * Close a UFILE. Implies u_fflush first.
* @param file The UFILE to close. * @param file The UFILE to close.
* @stable ICU 3.0 * @stable ICU 3.0
* @see u_fflush
*/ */
U_STABLE void U_EXPORT2 U_STABLE void U_EXPORT2
u_fclose(UFILE *file); u_fclose(UFILE *file);
#if U_SHOW_CPLUSPLUS_API #if U_SHOW_CPLUSPLUS_API
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
/** /**
* \class LocalUFILEPointer * \class LocalUFILEPointer
skipping to change at line 346 skipping to change at line 347
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE UBool U_EXPORT2 U_STABLE UBool U_EXPORT2
u_feof(UFILE *f); u_feof(UFILE *f);
/** /**
* Flush output of a UFILE. Implies a flush of * Flush output of a UFILE. Implies a flush of
* converter/transliterator state. (That is, a logical break is * converter/transliterator state. (That is, a logical break is
* made in the output stream - for example if a different type of * made in the output stream - for example if a different type of
* output is desired.) The underlying OS level file is also flushed. * output is desired.) The underlying OS level file is also flushed.
* Note that for a stateful encoding, the converter may write additional
* bytes to return the stream to default state.
* @param file The UFILE to flush. * @param file The UFILE to flush.
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE void U_EXPORT2 U_STABLE void U_EXPORT2
u_fflush(UFILE *file); u_fflush(UFILE *file);
/** /**
* Rewind the file pointer to the beginning of the file. * Rewind the file pointer to the beginning of the file.
* @param file The UFILE to rewind. * @param file The UFILE to rewind.
* @stable ICU 3.0 * @stable ICU 3.0
 End of changes. 3 change blocks. 
1 lines changed or deleted 4 lines changed or added


 ustream.h   ustream.h 
/* /*
********************************************************************** **********************************************************************
* Copyright (C) 2001-2007 International Business Machines * Copyright (C) 2001-2010 International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
********************************************************************** **********************************************************************
* FILE NAME : ustream.h * FILE NAME : ustream.h
* *
* Modification History: * Modification History:
* *
* Date Name Description * Date Name Description
* 06/25/2001 grhoten Move iostream from unistr.h * 06/25/2001 grhoten Move iostream from unistr.h
*************************************************************************** *** *************************************************************************** ***
*/ */
skipping to change at line 30 skipping to change at line 30
/** /**
* \file * \file
* \brief C++ API: Unicode iostream like API * \brief C++ API: Unicode iostream like API
* *
* At this time, this API is very limited. It contains * At this time, this API is very limited. It contains
* operator<< and operator>> for UnicodeString manipulation with the * operator<< and operator>> for UnicodeString manipulation with the
* C++ I/O stream API. * C++ I/O stream API.
*/ */
#if U_IOSTREAM_SOURCE >= 199711 #if U_IOSTREAM_SOURCE >= 199711
#if (__GNUC__ == 2)
#include <iostream>
#else
#include <istream> #include <istream>
#include <ostream> #include <ostream>
#endif
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
/** /**
* Write the contents of a UnicodeString to a C++ ostream. This functions w rites * Write the contents of a UnicodeString to a C++ ostream. This functions w rites
* the characters in a UnicodeString to an ostream. The UChars in the * the characters in a UnicodeString to an ostream. The UChars in the
* UnicodeString are converted to the char based ostream with the default * UnicodeString are converted to the char based ostream with the default
* converter. * converter.
* @stable 3.0 * @stable 3.0
*/ */
 End of changes. 3 change blocks. 
1 lines changed or deleted 5 lines changed or added


 utf16.h   utf16.h 
/* /*
*************************************************************************** **** *************************************************************************** ****
* *
* Copyright (C) 1999-2008, International Business Machines * Copyright (C) 1999-2010, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
* *
*************************************************************************** **** *************************************************************************** ****
* file name: utf16.h * file name: utf16.h
* encoding: US-ASCII * encoding: US-ASCII
* tab size: 8 (not used) * tab size: 8 (not used)
* indentation:4 * indentation:4
* *
* created on: 1999sep09 * created on: 1999sep09
* created by: Markus W. Scherer * created by: Markus W. Scherer
skipping to change at line 205 skipping to change at line 205
*/ */
#define U16_GET(s, start, i, length, c) { \ #define U16_GET(s, start, i, length, c) { \
(c)=(s)[i]; \ (c)=(s)[i]; \
if(U16_IS_SURROGATE(c)) { \ if(U16_IS_SURROGATE(c)) { \
uint16_t __c2; \ uint16_t __c2; \
if(U16_IS_SURROGATE_LEAD(c)) { \ if(U16_IS_SURROGATE_LEAD(c)) { \
if((i)+1<(length) && U16_IS_TRAIL(__c2=(s)[(i)+1])) { \ if((i)+1<(length) && U16_IS_TRAIL(__c2=(s)[(i)+1])) { \
(c)=U16_GET_SUPPLEMENTARY((c), __c2); \ (c)=U16_GET_SUPPLEMENTARY((c), __c2); \
} \ } \
} else { \ } else { \
if((i)-1>=(start) && U16_IS_LEAD(__c2=(s)[(i)-1])) { \ if((i)>(start) && U16_IS_LEAD(__c2=(s)[(i)-1])) { \
(c)=U16_GET_SUPPLEMENTARY(__c2, (c)); \ (c)=U16_GET_SUPPLEMENTARY(__c2, (c)); \
} \ } \
} \ } \
} \ } \
} }
/* definitions with forward iteration ------------------------------------- -- */ /* definitions with forward iteration ------------------------------------- -- */
/** /**
* Get a code point from a string at a code point boundary offset, * Get a code point from a string at a code point boundary offset,
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added


 uvernum.h   uvernum.h 
skipping to change at line 63 skipping to change at line 63
/** The current ICU minor version as an integer. /** The current ICU minor version as an integer.
* This value will change in the subsequent releases of ICU * This value will change in the subsequent releases of ICU
* @stable ICU 2.6 * @stable ICU 2.6
*/ */
#define U_ICU_VERSION_MINOR_NUM 5 #define U_ICU_VERSION_MINOR_NUM 5
/** The current ICU patchlevel version as an integer. /** The current ICU patchlevel version as an integer.
* This value will change in the subsequent releases of ICU * This value will change in the subsequent releases of ICU
* @stable ICU 2.4 * @stable ICU 2.4
*/ */
#define U_ICU_VERSION_PATCHLEVEL_NUM 1 #define U_ICU_VERSION_PATCHLEVEL_NUM 2
/** The current ICU build level version as an integer. /** The current ICU build level version as an integer.
* This value is for use by ICU clients. It defaults to 0. * This value is for use by ICU clients. It defaults to 0.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
#ifndef U_ICU_VERSION_BUILDLEVEL_NUM #ifndef U_ICU_VERSION_BUILDLEVEL_NUM
#define U_ICU_VERSION_BUILDLEVEL_NUM 0 #define U_ICU_VERSION_BUILDLEVEL_NUM 0
#endif #endif
/** Glued version suffix for renamers /** Glued version suffix for renamers
skipping to change at line 94 skipping to change at line 94
*/ */
#ifndef U_ICU_ENTRY_POINT_RENAME #ifndef U_ICU_ENTRY_POINT_RENAME
#define U_ICU_ENTRY_POINT_RENAME(x) x ## _45 #define U_ICU_ENTRY_POINT_RENAME(x) x ## _45
#endif #endif
/** The current ICU library version as a dotted-decimal string. The patchle vel /** The current ICU library version as a dotted-decimal string. The patchle vel
* only appears in this string if it non-zero. * only appears in this string if it non-zero.
* This value will change in the subsequent releases of ICU * This value will change in the subsequent releases of ICU
* @stable ICU 2.4 * @stable ICU 2.4
*/ */
#define U_ICU_VERSION "4.5.1" #define U_ICU_VERSION "4.5.2"
/** The current ICU library major/minor version as a string without dots, f or library name suffixes. /** The current ICU library major/minor version as a string without dots, f or library name suffixes.
* This value will change in the subsequent releases of ICU * This value will change in the subsequent releases of ICU
* @stable ICU 2.6 * @stable ICU 2.6
*/ */
#define U_ICU_VERSION_SHORT "45" #define U_ICU_VERSION_SHORT "45"
/** Data version in ICU4C. /** Data version in ICU4C.
* @internal ICU 4.4 Internal Use Only * @internal ICU 4.4 Internal Use Only
**/ **/
#define U_ICU_DATA_VERSION "4.4" #define U_ICU_DATA_VERSION "4.5.2"
/*========================================================================= == /*========================================================================= ==
* ICU collation framework version information * ICU collation framework version information
* Version info that can be obtained from a collator is affected by these * Version info that can be obtained from a collator is affected by these
* numbers in a secret and magic way. Please use collator version as whole * numbers in a secret and magic way. Please use collator version as whole
*========================================================================= == *========================================================================= ==
*/ */
/** Collation runtime version (sort key generator, strcoll). /** Collation runtime version (sort key generator, strcoll).
* If the version is different, sortkeys for the same string could be diffe rent * If the version is different, sortkeys for the same string could be diffe rent
 End of changes. 3 change blocks. 
3 lines changed or deleted 3 lines changed or added


 vtzone.h   vtzone.h 
/* /*
*************************************************************************** **** *************************************************************************** ****
* Copyright (C) 2007-2009, International Business Machines Corporation and * * Copyright (C) 2007-2010, International Business Machines Corporation and *
* others. All Rights Reserved. * * others. All Rights Reserved. *
*************************************************************************** **** *************************************************************************** ****
*/ */
#ifndef VTZONE_H #ifndef VTZONE_H
#define VTZONE_H #define VTZONE_H
#include "unicode/utypes.h" #include "unicode/utypes.h"
/** /**
* \file * \file
skipping to change at line 33 skipping to change at line 33
class VTZWriter; class VTZWriter;
class VTZReader; class VTZReader;
class UVector; class UVector;
/** /**
* <code>VTimeZone</code> is a class implementing RFC2445 VTIMEZONE. You c an create a * <code>VTimeZone</code> is a class implementing RFC2445 VTIMEZONE. You c an create a
* <code>VTimeZone</code> instance from a time zone ID supported by <code>T imeZone</code>. * <code>VTimeZone</code> instance from a time zone ID supported by <code>T imeZone</code>.
* With the <code>VTimeZone</code> instance created from the ID, you can wr ite out the rule * With the <code>VTimeZone</code> instance created from the ID, you can wr ite out the rule
* in RFC2445 VTIMEZONE format. Also, you can create a <code>VTimeZone</co de> instance * in RFC2445 VTIMEZONE format. Also, you can create a <code>VTimeZone</co de> instance
* from RFC2445 VTIMEZONE data stream, which allows you to calculate time * from RFC2445 VTIMEZONE data stream, which allows you to calculate time
* zone offset by the rules defined by the data.<br><br> * zone offset by the rules defined by the data. Or, you can create a
* <code>VTimeZone</code> from any other ICU <code>BasicTimeZone</code>.
* <br><br>
* Note: The consumer of this class reading or writing VTIMEZONE data is re sponsible to * Note: The consumer of this class reading or writing VTIMEZONE data is re sponsible to
* decode or encode Non-ASCII text. Methods reading/writing VTIMEZONE data in this class * decode or encode Non-ASCII text. Methods reading/writing VTIMEZONE data in this class
* do nothing with MIME encoding. * do nothing with MIME encoding.
* @stable ICU 3.8 * @stable ICU 3.8
*/ */
class U_I18N_API VTimeZone : public BasicTimeZone { class U_I18N_API VTimeZone : public BasicTimeZone {
public: public:
/** /**
* Copy constructor. * Copy constructor.
* @param source The <code>VTimeZone</code> object to be copied. * @param source The <code>VTimeZone</code> object to be copied.
skipping to change at line 91 skipping to change at line 93
/** /**
* Create a <code>VTimeZone</code> instance by the time zone ID. * Create a <code>VTimeZone</code> instance by the time zone ID.
* @param ID The time zone ID, such as America/New_York * @param ID The time zone ID, such as America/New_York
* @return A <code>VTimeZone</code> object initialized by the time zone ID, * @return A <code>VTimeZone</code> object initialized by the time zone ID,
* or NULL when the ID is unknown. * or NULL when the ID is unknown.
* @stable ICU 3.8 * @stable ICU 3.8
*/ */
static VTimeZone* createVTimeZoneByID(const UnicodeString& ID); static VTimeZone* createVTimeZoneByID(const UnicodeString& ID);
/** /**
* Create a <code>VTimeZone</code> instance using a basic time zone.
* @param basicTZ The basic time zone instance
* @param status Output param to filled in with a success or an error.
* @return A <code>VTimeZone</code> object initialized by the basic tim
e zone.
* @draft ICU 4.6
*/
static VTimeZone* createVTimeZoneFromBasicTimeZone(const BasicTimeZone&
basicTZ,
UErrorCode &status);
/**
* Create a <code>VTimeZone</code> instance by RFC2445 VTIMEZONE data * Create a <code>VTimeZone</code> instance by RFC2445 VTIMEZONE data
* *
* @param vtzdata The string including VTIMEZONE data block * @param vtzdata The string including VTIMEZONE data block
* @param status Output param to filled in with a success or an error. * @param status Output param to filled in with a success or an error.
* @return A <code>VTimeZone</code> initialized by the VTIMEZONE data o r * @return A <code>VTimeZone</code> initialized by the VTIMEZONE data o r
* NULL if failed to load the rule from the VTIMEZONE data. * NULL if failed to load the rule from the VTIMEZONE data.
* @stable ICU 3.8 * @stable ICU 3.8
*/ */
static VTimeZone* createVTimeZone(const UnicodeString& vtzdata, UErrorC ode& status); static VTimeZone* createVTimeZone(const UnicodeString& vtzdata, UErrorC ode& status);
 End of changes. 3 change blocks. 
2 lines changed or deleted 16 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/