LEFontInstance.h   LEFontInstance.h 
/* /*
* *
* (C) Copyright IBM Corp. 1998-2012 - All Rights Reserved * (C) Copyright IBM Corp. 1998-2013 - All Rights Reserved
* *
*/ */
#ifndef __LEFONTINSTANCE_H #ifndef __LEFONTINSTANCE_H
#define __LEFONTINSTANCE_H #define __LEFONTINSTANCE_H
#include "LETypes.h" #include "LETypes.h"
/** /**
* \file * \file
* \brief C++ API: Layout Engine Font Instance object * \brief C++ API: Layout Engine Font Instance object
skipping to change at line 159 skipping to change at line 159
/** /**
* This method reads a table from the font. Note that in general, * This method reads a table from the font. Note that in general,
* it only makes sense to call this method on an <code>LEFontInstance</ code> * it only makes sense to call this method on an <code>LEFontInstance</ code>
* which represents a physical font - i.e. one which has been returned by * which represents a physical font - i.e. one which has been returned by
* <code>getSubFont()</code>. This is because each subfont in a composi te font * <code>getSubFont()</code>. This is because each subfont in a composi te font
* will have different tables, and there's no way to know which subfont to access. * will have different tables, and there's no way to know which subfont to access.
* *
* Subclasses which represent composite fonts should always return <cod e>NULL</code>. * Subclasses which represent composite fonts should always return <cod e>NULL</code>.
* *
* Note that implementing this function does not allow for range checki
ng.
* Subclasses that desire the safety of range checking must implement t
he
* variation which has a length parameter.
*
* @param tableTag - the four byte table tag. (e.g. 'cmap') * @param tableTag - the four byte table tag. (e.g. 'cmap')
* *
* @return the address of the table in memory, or <code>NULL</code> * @return the address of the table in memory, or <code>NULL</code>
* if the table doesn't exist. * if the table doesn't exist.
* *
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
virtual const void *getFontTable(LETag tableTag) const = 0; virtual const void *getFontTable(LETag tableTag) const = 0;
/** /**
* This method reads a table from the font. Note that in general, * This method reads a table from the font. Note that in general,
* it only makes sense to call this method on an <code>LEFontInstance</ code> * it only makes sense to call this method on an <code>LEFontInstance</ code>
* which represents a physical font - i.e. one which has been returned by * which represents a physical font - i.e. one which has been returned by
* <code>getSubFont()</code>. This is because each subfont in a composi te font * <code>getSubFont()</code>. This is because each subfont in a composi te font
* will have different tables, and there's no way to know which subfont to access. * will have different tables, and there's no way to know which subfont to access.
* *
* Subclasses which represent composite fonts should always return <cod e>NULL</code>. * Subclasses which represent composite fonts should always return <cod e>NULL</code>.
* *
* This version sets a length, for range checking. * This version sets a length, for range checking.
* Note that range checking can only be accomplished if this function i
s
* implemented in subclasses.
* *
* @param tableTag - the four byte table tag. (e.g. 'cmap') * @param tableTag - the four byte table tag. (e.g. 'cmap')
* @param length - ignored on entry, on exit will be the length of the table if known, or -1 if unknown. * @param length - ignored on entry, on exit will be the length of the table if known, or -1 if unknown.
* @return the address of the table in memory, or <code>NULL</code> * @return the address of the table in memory, or <code>NULL</code>
* if the table doesn't exist. * if the table doesn't exist.
* @internal * @draft ICU 52
*/ */
virtual const void* getFontTable(LETag tableTag, size_t &length) const { length=-1; return getFontTable(tableTag); } /* -1 = unknown length */ virtual const void* getFontTable(LETag tableTag, size_t &length) const { length=-1; return getFontTable(tableTag); } /* -1 = unknown length */
/** /**
* This method is used to determine if the font can * This method is used to determine if the font can
* render the given character. This can usually be done * render the given character. This can usually be done
* by looking the character up in the font's character * by looking the character up in the font's character
* to glyph mapping. * to glyph mapping.
* *
* The default implementation of this method will return * The default implementation of this method will return
 End of changes. 4 change blocks. 
2 lines changed or deleted 11 lines changed or added


 LEScripts.h   LEScripts.h 
/* /*
* *
* (C) Copyright IBM Corp. 1998-2012. All Rights Reserved. * (C) Copyright IBM Corp. 1998-2013. All Rights Reserved.
* *
* WARNING: THIS FILE IS MACHINE GENERATED. DO NOT HAND EDIT IT UNLESS * WARNING: THIS FILE IS MACHINE GENERATED. DO NOT HAND EDIT IT UNLESS
* YOU REALLY KNOW WHAT YOU'RE DOING. * YOU REALLY KNOW WHAT YOU'RE DOING.
* *
* Generated on: 11/01/2011 04:08:09 PM PDT * Generated on: 11/01/2011 04:08:09 PM PDT
*/ */
#ifndef __LESCRIPTS_H #ifndef __LESCRIPTS_H
#define __LESCRIPTS_H #define __LESCRIPTS_H
skipping to change at line 236 skipping to change at line 236
nshuScriptCode = 150, nshuScriptCode = 150,
shrdScriptCode = 151, shrdScriptCode = 151,
soraScriptCode = 152, soraScriptCode = 152,
takrScriptCode = 153, takrScriptCode = 153,
tangScriptCode = 154, tangScriptCode = 154,
woleScriptCode = 155, woleScriptCode = 155,
/** /**
* @stable ICU 49 * @stable ICU 49
*/ */
khojScriptCode = 156, hluwScriptCode = 156, /* bump to match current ICU */
tirhScriptCode = 157, khojScriptCode = 157,
tirhScriptCode = 158,
scriptCodeCount = 158 /**
* @stable ICU 52
*/
aghbScriptCode = 159,
mahjScriptCode = 160,
/**
* @stable ICU 2.2
*/
scriptCodeCount
}; };
U_NAMESPACE_END U_NAMESPACE_END
#endif #endif
 End of changes. 3 change blocks. 
4 lines changed or deleted 14 lines changed or added


 LETableReference.h   LETableReference.h 
skipping to change at line 352 skipping to change at line 352
template<class T> template<class T>
class LEReferenceTo : public LETableReference { class LEReferenceTo : public LETableReference {
public: public:
/** /**
* open a sub reference. * open a sub reference.
* @param parent parent reference * @param parent parent reference
* @param success error status * @param success error status
* @param atPtr location of reference - if NULL, will be at offset zero ( i.e. downcast of parent). Otherwise must be a pointer within parent's bound s. * @param atPtr location of reference - if NULL, will be at offset zero ( i.e. downcast of parent). Otherwise must be a pointer within parent's bound s.
*/ */
LEReferenceTo(const LETableReference &parent, LEErrorCode &success, const void* atPtr) inline LEReferenceTo(const LETableReference &parent, LEErrorCode &success, const void* atPtr)
: LETableReference(parent, parent.ptrToOffset(atPtr, success), LE_UINTP TR_MAX, success) { : LETableReference(parent, parent.ptrToOffset(atPtr, success), LE_UINTP TR_MAX, success) {
verifyLength(0, LETableVarSizer<T>::getSize(), success); verifyLength(0, LETableVarSizer<T>::getSize(), success);
if(LE_FAILURE(success)) clear(); if(LE_FAILURE(success)) clear();
} }
/** /**
* ptr plus offset * ptr plus offset
*/ */
LEReferenceTo(const LETableReference &parent, LEErrorCode &success, const void* atPtr, size_t offset) inline LEReferenceTo(const LETableReference &parent, LEErrorCode &success, const void* atPtr, size_t offset)
: LETableReference(parent, parent.ptrToOffset(atPtr, success)+offset, L E_UINTPTR_MAX, success) { : LETableReference(parent, parent.ptrToOffset(atPtr, success)+offset, L E_UINTPTR_MAX, success) {
verifyLength(0, LETableVarSizer<T>::getSize(), success); verifyLength(0, LETableVarSizer<T>::getSize(), success);
if(LE_FAILURE(success)) clear(); if(LE_FAILURE(success)) clear();
} }
LEReferenceTo(const LETableReference &parent, LEErrorCode &success, size_ t offset) inline LEReferenceTo(const LETableReference &parent, LEErrorCode &success, size_t offset)
: LETableReference(parent, offset, LE_UINTPTR_MAX, success) { : LETableReference(parent, offset, LE_UINTPTR_MAX, success) {
verifyLength(0, LETableVarSizer<T>::getSize(), success); verifyLength(0, LETableVarSizer<T>::getSize(), success);
if(LE_FAILURE(success)) clear(); if(LE_FAILURE(success)) clear();
} }
LEReferenceTo(const LETableReference &parent, LEErrorCode &success) inline LEReferenceTo(const LETableReference &parent, LEErrorCode &success)
: LETableReference(parent, 0, LE_UINTPTR_MAX, success) { : LETableReference(parent, 0, LE_UINTPTR_MAX, success) {
verifyLength(0, LETableVarSizer<T>::getSize(), success); verifyLength(0, LETableVarSizer<T>::getSize(), success);
if(LE_FAILURE(success)) clear(); if(LE_FAILURE(success)) clear();
} }
LEReferenceTo(const LEFontInstance *font, LETag tableTag, LEErrorCode &suc cess) inline LEReferenceTo(const LEFontInstance *font, LETag tableTag, LEErrorCo de &success)
: LETableReference(font, tableTag, success) { : LETableReference(font, tableTag, success) {
verifyLength(0, LETableVarSizer<T>::getSize(), success); verifyLength(0, LETableVarSizer<T>::getSize(), success);
if(LE_FAILURE(success)) clear(); if(LE_FAILURE(success)) clear();
} }
LEReferenceTo(const le_uint8 *data, size_t length = LE_UINTPTR_MAX) : LETa inline LEReferenceTo(const le_uint8 *data, size_t length = LE_UINTPTR_MAX)
bleReference(data, length) {} : LETableReference(data, length) {}
LEReferenceTo(const T *data, size_t length = LE_UINTPTR_MAX) : LETableRefe inline LEReferenceTo(const T *data, size_t length = LE_UINTPTR_MAX) : LETa
rence((const le_uint8*)data, length) {} bleReference((const le_uint8*)data, length) {}
LEReferenceTo() : LETableReference(NULL) {} inline LEReferenceTo() : LETableReference(NULL) {}
LEReferenceTo<T>& operator=(const T* other) { inline LEReferenceTo<T>& operator=(const T* other) {
setRaw(other); setRaw(other);
return *this; return *this;
} }
LEReferenceTo<T> &reparent(const LETableReference &base) { LEReferenceTo<T> &reparent(const LETableReference &base) {
fParent = &base; fParent = &base;
return *this; return *this;
} }
/** /**
 End of changes. 7 change blocks. 
11 lines changed or deleted 11 lines changed or added


 LETypes.h   LETypes.h 
skipping to change at line 268 skipping to change at line 268
/** /**
* Used to hold a pair of (x, y) values which represent a point. * Used to hold a pair of (x, y) values which represent a point.
* *
* @stable ICU 2.4 * @stable ICU 2.4
*/ */
typedef struct LEPoint LEPoint; typedef struct LEPoint LEPoint;
#endif #endif
#ifndef U_HIDE_INTERNAL_API #ifndef U_HIDE_INTERNAL_API
/**
* \def
* @internal
*/
#ifndef LE_ASSERT_BAD_FONT #ifndef LE_ASSERT_BAD_FONT
#define LE_ASSERT_BAD_FONT 0 #define LE_ASSERT_BAD_FONT 0
#endif #endif
/**
* \def LE_DEBUG_BAD_FONT
* @internal
*/
#if LE_ASSERT_BAD_FONT #if LE_ASSERT_BAD_FONT
#include <stdio.h> #include <stdio.h>
#define LE_DEBUG_BAD_FONT(x) fprintf(stderr,"%s:%d: BAD FONT: %s\n", __FILE __, __LINE__, (x)); #define LE_DEBUG_BAD_FONT(x) fprintf(stderr,"%s:%d: BAD FONT: %s\n", __FILE __, __LINE__, (x));
#else #else
#define LE_DEBUG_BAD_FONT(x) #define LE_DEBUG_BAD_FONT(x)
#endif #endif
/** /**
* \def LE_UINTPTR_MAX
* Max value representable by a uintptr * Max value representable by a uintptr
*/ */
#ifndef UINT32_MAX #ifndef UINT32_MAX
#define LE_UINT32_MAX 0xFFFFFFFFU #define LE_UINT32_MAX 0xFFFFFFFFU
#else #else
#define LE_UINT32_MAX UINT32_MAX #define LE_UINT32_MAX UINT32_MAX
#endif #endif
#ifndef UINTPTR_MAX #ifndef UINTPTR_MAX
#define LE_UINTPTR_MAX LE_UINT32_MAX #define LE_UINTPTR_MAX LE_UINT32_MAX
#else #else
#define LE_UINTPTR_MAX UINTPTR_MAX #define LE_UINTPTR_MAX UINTPTR_MAX
#endif #endif
/** /**
* Range check for overflow * Range check for overflow
*/ */
#define LE_RANGE_CHECK(type, count, ptrfn) (( (LE_UINTPTR_MAX / sizeof(type )) < count ) ? NULL : (ptrfn)) #define LE_RANGE_CHECK(type, count, ptrfn) (( (LE_UINTPTR_MAX / sizeof(type )) < (size_t)count ) ? NULL : (ptrfn))
/** /**
* A convenience macro to get the length of an array. * A convenience macro to get the length of an array.
* *
* @internal * @internal
*/ */
#define LE_ARRAY_SIZE(array) (sizeof array / sizeof array[0]) #define LE_ARRAY_SIZE(array) (sizeof array / sizeof array[0])
#ifdef LE_USE_CMEMORY #ifdef LE_USE_CMEMORY
/** /**
* A convenience macro for copying an array. * A convenience macro for copying an array.
 End of changes. 4 change blocks. 
1 lines changed or deleted 10 lines changed or added


 brkiter.h   brkiter.h 
skipping to change at line 292 skipping to change at line 292
* Set the iterator position to the nth boundary from the current bound ary * Set the iterator position to the nth boundary from the current bound ary
* @param n the number of boundaries to move by. A value of 0 * @param n the number of boundaries to move by. A value of 0
* does nothing. Negative values move to previous boundaries * does nothing. Negative values move to previous boundaries
* and positive values move to later boundaries. * and positive values move to later boundaries.
* @return The new iterator position, or * @return The new iterator position, or
* DONE if there are fewer than |n| boundaries in the specfied directio n. * DONE if there are fewer than |n| boundaries in the specfied directio n.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual int32_t next(int32_t n) = 0; virtual int32_t next(int32_t n) = 0;
/**
* For RuleBasedBreakIterators, return the status tag from the
* break rule that determined the most recently
* returned break position.
* <p>
* For break iterator types that do not support a rule status,
* a default value of 0 is returned.
* <p>
* @return the status from the break rule that determined the most rece
ntly
* returned break position.
* @see RuleBaseBreakIterator::getRuleStatus()
* @see UWordBreak
* @draft ICU 52
*/
virtual int32_t getRuleStatus() const;
/**
* For RuleBasedBreakIterators, get the status (tag) values from the bre
ak rule(s)
* that determined the most recently returned break position.
* <p>
* For break iterator types that do not support rule status,
* no values are returned.
* <p>
* The returned status value(s) are stored into an array provided by the
caller.
* The values are stored in sorted (ascending) order.
* If the capacity of the output array is insufficient to hold the data,
* the output will be truncated to the available length, and a
* U_BUFFER_OVERFLOW_ERROR will be signaled.
* <p>
* @see RuleBaseBreakIterator::getRuleStatusVec
*
* @param fillInVec an array to be filled in with the status values.
* @param capacity the length of the supplied vector. A length of zero
causes
* the function to return the number of status values,
in the
* normal way, without attemtping to store any values.
* @param status receives error codes.
* @return The number of rule status values from rules that det
ermined
* the most recent boundary returned by the break itera
tor.
* In the event of a U_BUFFER_OVERFLOW_ERROR, the retur
n value
* is the total number of status values that were avail
able,
* not the reduced number that were actually returned.
* @see getRuleStatus
* @draft ICU 52
*/
virtual int32_t getRuleStatusVec(int32_t *fillInVec, int32_t capacity,
UErrorCode &status);
/** /**
* Create BreakIterator for word-breaks using the given locale. * Create BreakIterator for word-breaks using the given locale.
* Returns an instance of a BreakIterator implementing word breaks. * Returns an instance of a BreakIterator implementing word breaks.
* WordBreak is useful for word selection (ex. double click) * WordBreak is useful for word selection (ex. double click)
* @param where the locale. * @param where the locale.
* @param status the error code * @param status the error code
* @return A BreakIterator for word-breaks. The UErrorCode& status * @return A BreakIterator for word-breaks. The UErrorCode& status
* parameter is used to return status information to the user. * parameter is used to return status information to the user.
* To check whether the construction succeeded or not, you should check * To check whether the construction succeeded or not, you should check
* the value of U_SUCCESS(err). If you wish more detailed information, you * the value of U_SUCCESS(err). If you wish more detailed information, you
skipping to change at line 442 skipping to change at line 488
* default locale. * default locale.
* @param objectLocale must be from getMatchingLocales * @param objectLocale must be from getMatchingLocales
* @param name the fill-in parameter of the return value * @param name the fill-in parameter of the return value
* @return user-displayable name * @return user-displayable name
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
static UnicodeString& U_EXPORT2 getDisplayName(const Locale& objectLoca le, static UnicodeString& U_EXPORT2 getDisplayName(const Locale& objectLoca le,
UnicodeString& name); UnicodeString& name);
/** /**
* Deprecated functionality. Use clone() instead.
*
* Thread safe client-buffer-based cloning operation * Thread safe client-buffer-based cloning operation
* Do NOT call delete on a safeclone, since 'new' is not used to cre ate it. * Do NOT call delete on a safeclone, since 'new' is not used to cre ate it.
* @param stackBuffer user allocated space for the new clone. If NULL n ew memory will be allocated. * @param stackBuffer user allocated space for the new clone. If NULL n ew memory will be allocated.
* If buffer is not large enough, new memory will be allocated. * If buffer is not large enough, new memory will be allocated.
* @param BufferSize reference to size of allocated space. * @param BufferSize reference to size of allocated space.
* If BufferSize == 0, a sufficient size for use in cloning will * If BufferSize == 0, a sufficient size for use in cloning will
* be returned ('pre-flighting') * be returned ('pre-flighting')
* If BufferSize is not enough for a stack-based safe clone, * If BufferSize is not enough for a stack-based safe clone,
* new memory will be allocated. * new memory will be allocated.
* @param status to indicate whether the operation went on smoothly or there were errors * @param status to indicate whether the operation went on smoothly or there were errors
* An informational status value, U_SAFECLONE_ALLOCATED_ERROR, is used if any allocations were * An informational status value, U_SAFECLONE_ALLOCATED_ERROR, is used if any allocations were
* necessary. * necessary.
* @return pointer to the new clone * @return pointer to the new clone
* *
* @stable ICU 2.0 * @deprecated ICU 52. Use clone() instead.
*/ */
virtual BreakIterator * createBufferClone(void *stackBuffer, virtual BreakIterator * createBufferClone(void *stackBuffer,
int32_t &BufferSize, int32_t &BufferSize,
UErrorCode &status) = 0; UErrorCode &status) = 0;
#ifndef U_HIDE_DEPRECATED_API
/** /**
* Determine whether the BreakIterator was created in user memory by * Determine whether the BreakIterator was created in user memory by
* createBufferClone(), and thus should not be deleted. Such objects * createBufferClone(), and thus should not be deleted. Such objects
* must be closed by an explicit call to the destructor (not delete). * must be closed by an explicit call to the destructor (not delete).
* @stable ICU 2.0 * @deprecated ICU 52. Always delete the BreakIterator.
*/ */
inline UBool isBufferClone(void); inline UBool isBufferClone(void);
#endif /* U_HIDE_DEPRECATED_API */
#if !UCONFIG_NO_SERVICE #if !UCONFIG_NO_SERVICE
/** /**
* Register a new break iterator of the indicated kind, to use in the g iven locale. * Register a new break iterator of the indicated kind, to use in the g iven locale.
* The break iterator will be adopted. Clones of the iterator will be returned * The break iterator will be adopted. Clones of the iterator will be returned
* if a request for a break iterator of the given kind matches or falls back to * if a request for a break iterator of the given kind matches or falls back to
* this locale. * this locale.
* @param toAdopt the BreakIterator instance to be adopted * @param toAdopt the BreakIterator instance to be adopted
* @param locale the Locale for which this instance is to be registered * @param locale the Locale for which this instance is to be registered
* @param kind the type of iterator for which this instance is to be re gistered * @param kind the type of iterator for which this instance is to be re gistered
* @param status the in/out status code, no special meanings are assign ed * @param status the in/out status code, no special meanings are assign ed
skipping to change at line 566 skipping to change at line 618
friend class ICUBreakIteratorFactory; friend class ICUBreakIteratorFactory;
friend class ICUBreakIteratorService; friend class ICUBreakIteratorService;
protected: protected:
// Do not enclose protected default/copy constructors with #ifndef U_HI DE_INTERNAL_API // Do not enclose protected default/copy constructors with #ifndef U_HI DE_INTERNAL_API
// or else the compiler will create a public ones. // or else the compiler will create a public ones.
/** @internal */ /** @internal */
BreakIterator(); BreakIterator();
/** @internal */ /** @internal */
UBool fBufferClone; BreakIterator (const BreakIterator &other) : UObject(other) {}
/** @internal */
BreakIterator (const BreakIterator &other) : UObject(other), fBufferClo
ne(FALSE) {}
private: private:
/** @internal */ /** @internal */
char actualLocale[ULOC_FULLNAME_CAPACITY]; char actualLocale[ULOC_FULLNAME_CAPACITY];
char validLocale[ULOC_FULLNAME_CAPACITY]; char validLocale[ULOC_FULLNAME_CAPACITY];
/** /**
* The assignment operator has no real implementation. * The assignment operator has no real implementation.
* It's provided to make the compiler happy. Do not call. * It's provided to make the compiler happy. Do not call.
*/ */
BreakIterator& operator=(const BreakIterator&); BreakIterator& operator=(const BreakIterator&);
}; };
#ifndef U_HIDE_DEPRECATED_API
inline UBool BreakIterator::isBufferClone() inline UBool BreakIterator::isBufferClone()
{ {
return fBufferClone; return FALSE;
} }
#endif /* U_HIDE_DEPRECATED_API */
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_BREAK_ITERATION */ #endif /* #if !UCONFIG_NO_BREAK_ITERATION */
#endif // _BRKITER #endif // _BRKITER
//eof //eof
 End of changes. 10 change blocks. 
7 lines changed or deleted 70 lines changed or added


 bytestriebuilder.h   bytestriebuilder.h 
/* /*
*************************************************************************** **** *************************************************************************** ****
* Copyright (C) 2010-2012, International Business Machines * Copyright (C) 2010-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
*************************************************************************** **** *************************************************************************** ****
* file name: bytestriebuilder.h * file name: bytestriebuilder.h
* encoding: US-ASCII * encoding: US-ASCII
* tab size: 8 (not used) * tab size: 8 (not used)
* indentation:4 * indentation:4
* *
* created on: 2010sep25 * created on: 2010sep25
* created by: Markus W. Scherer * created by: Markus W. Scherer
*/ */
skipping to change at line 74 skipping to change at line 74
* function chaining. (See User Guide for details.) * function chaining. (See User Guide for details.)
* @return *this * @return *this
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
BytesTrieBuilder &add(const StringPiece &s, int32_t value, UErrorCode & errorCode); BytesTrieBuilder &add(const StringPiece &s, int32_t value, UErrorCode & errorCode);
/** /**
* Builds a BytesTrie for the add()ed data. * Builds a BytesTrie for the add()ed data.
* Once built, no further data can be add()ed until clear() is called. * Once built, no further data can be add()ed until clear() is called.
* *
* A BytesTrie cannot be empty. At least one (byte sequence, value) pai
r
* must have been add()ed.
*
* This method passes ownership of the builder's internal result array to the new trie object. * This method passes ownership of the builder's internal result array to the new trie object.
* Another call to any build() variant will re-serialize the trie. * Another call to any build() variant will re-serialize the trie.
* After clear() has been called, a new array will be used as well. * After clear() has been called, a new array will be used as well.
* @param buildOption Build option, see UStringTrieBuildOption. * @param buildOption Build option, see UStringTrieBuildOption.
* @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
* function chaining. (See User Guide for details.) * function chaining. (See User Guide for details.)
* @return A new BytesTrie for the add()ed data. * @return A new BytesTrie for the add()ed data.
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
BytesTrie *build(UStringTrieBuildOption buildOption, UErrorCode &errorC ode); BytesTrie *build(UStringTrieBuildOption buildOption, UErrorCode &errorC ode);
/** /**
* Builds a BytesTrie for the add()ed data and byte-serializes it. * Builds a BytesTrie for the add()ed data and byte-serializes it.
* Once built, no further data can be add()ed until clear() is called. * Once built, no further data can be add()ed until clear() is called.
* *
* A BytesTrie cannot be empty. At least one (byte sequence, value) pai
r
* must have been add()ed.
*
* Multiple calls to buildStringPiece() return StringPieces referring t o the * Multiple calls to buildStringPiece() return StringPieces referring t o the
* builder's same byte array, without rebuilding. * builder's same byte array, without rebuilding.
* If buildStringPiece() is called after build(), the trie will be * If buildStringPiece() is called after build(), the trie will be
* re-serialized into a new array. * re-serialized into a new array.
* If build() is called after buildStringPiece(), the trie object will become * If build() is called after buildStringPiece(), the trie object will become
* the owner of the previously returned array. * the owner of the previously returned array.
* After clear() has been called, a new array will be used as well. * After clear() has been called, a new array will be used as well.
* @param buildOption Build option, see UStringTrieBuildOption. * @param buildOption Build option, see UStringTrieBuildOption.
* @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
 End of changes. 3 change blocks. 
1 lines changed or deleted 9 lines changed or added


 calendar.h   calendar.h 
skipping to change at line 1376 skipping to change at line 1376
* // lang now contains the LDML calendar type * // lang now contains the LDML calendar type
* } * }
* \endcode * \endcode
* *
* @return legacy calendar type name string * @return legacy calendar type name string
* @stable ICU 49 * @stable ICU 49
*/ */
virtual const char * getType() const = 0; virtual const char * getType() const = 0;
/** /**
* Returns whether the given day of the week is a weekday, a * Returns whether the given day of the week is a weekday, a weekend da
* weekend day, or a day that transitions from one to the other, y,
* in this calendar system. If a transition occurs at midnight, * or a day that transitions from one to the other, for the locale and
* calendar system associated with this Calendar (the locale's region i
s
* often the most determinant factor). If a transition occurs at midnig
ht,
* then the days before and after the transition will have the * then the days before and after the transition will have the
* type UCAL_WEEKDAY or UCAL_WEEKEND. If a transition occurs at a time * type UCAL_WEEKDAY or UCAL_WEEKEND. If a transition occurs at a time
* other than midnight, then the day of the transition will have * other than midnight, then the day of the transition will have
* the type UCAL_WEEKEND_ONSET or UCAL_WEEKEND_CEASE. In this case, the * the type UCAL_WEEKEND_ONSET or UCAL_WEEKEND_CEASE. In this case, the
* method getWeekendTransition() will return the point of * method getWeekendTransition() will return the point of
* transition. * transition.
* @param dayOfWeek The day of the week whose type is desired (UCAL_SUN DAY..UCAL_SATURDAY). * @param dayOfWeek The day of the week whose type is desired (UCAL_SUN DAY..UCAL_SATURDAY).
* @param status The error code for the operation. * @param status The error code for the operation.
* @return The UCalendarWeekdayType for the day of the week. * @return The UCalendarWeekdayType for the day of the week.
* @stable ICU 4.4 * @stable ICU 4.4
*/ */
virtual UCalendarWeekdayType getDayOfWeekType(UCalendarDaysOfWeek dayOf Week, UErrorCode &status) const; virtual UCalendarWeekdayType getDayOfWeekType(UCalendarDaysOfWeek dayOf Week, UErrorCode &status) const;
/** /**
* Returns the time during the day at which the weekend begins or ends in * Returns the time during the day at which the weekend begins or ends in
* this calendar system. If getDayOfWeekType() rerturns UCAL_WEEKEND_O NSET * this calendar system. If getDayOfWeekType() returns UCAL_WEEKEND_ON SET
* for the specified dayOfWeek, return the time at which the weekend be gins. * for the specified dayOfWeek, return the time at which the weekend be gins.
* If getDayOfWeekType() returns UCAL_WEEKEND_CEASE for the specified d ayOfWeek, * If getDayOfWeekType() returns UCAL_WEEKEND_CEASE for the specified d ayOfWeek,
* return the time at which the weekend ends. If getDayOfWeekType() ret urns * return the time at which the weekend ends. If getDayOfWeekType() ret urns
* some other UCalendarWeekdayType for the specified dayOfWeek, is it a n error condition * some other UCalendarWeekdayType for the specified dayOfWeek, is it a n error condition
* (U_ILLEGAL_ARGUMENT_ERROR). * (U_ILLEGAL_ARGUMENT_ERROR).
* @param dayOfWeek The day of the week for which the weekend transitio n time is * @param dayOfWeek The day of the week for which the weekend transitio n time is
* desired (UCAL_SUNDAY..UCAL_SATURDAY). * desired (UCAL_SUNDAY..UCAL_SATURDAY).
* @param status The error code for the operation. * @param status The error code for the operation.
* @return The milliseconds after midnight at which the weekend begins or ends. * @return The milliseconds after midnight at which the weekend begins or ends.
* @stable ICU 4.4 * @stable ICU 4.4
skipping to change at line 1707 skipping to change at line 1708
* @return julian day specified by calendar fields. * @return julian day specified by calendar fields.
* @internal * @internal
*/ */
virtual int32_t handleComputeJulianDay(UCalendarDateFields bestField); virtual int32_t handleComputeJulianDay(UCalendarDateFields bestField);
/** /**
* Subclasses must override this to convert from week fields * Subclasses must override this to convert from week fields
* (YEAR_WOY and WEEK_OF_YEAR) to an extended year in the case * (YEAR_WOY and WEEK_OF_YEAR) to an extended year in the case
* where YEAR, EXTENDED_YEAR are not set. * where YEAR, EXTENDED_YEAR are not set.
* The Calendar implementation assumes yearWoy is in extended gregorian form * The Calendar implementation assumes yearWoy is in extended gregorian form
* @internal
* @return the extended year, UCAL_EXTENDED_YEAR * @return the extended year, UCAL_EXTENDED_YEAR
* @internal
*/ */
virtual int32_t handleGetExtendedYearFromWeekFields(int32_t yearWoy, in t32_t woy); virtual int32_t handleGetExtendedYearFromWeekFields(int32_t yearWoy, in t32_t woy);
#ifndef U_HIDE_INTERNAL_API #ifndef U_HIDE_INTERNAL_API
/** /**
* Compute the Julian day from fields. Will determine whether to use * Compute the Julian day from fields. Will determine whether to use
* the JULIAN_DAY field directly, or other fields. * the JULIAN_DAY field directly, or other fields.
* @return the julian day * @return the julian day
* @internal * @internal
*/ */
skipping to change at line 2380 skipping to change at line 2381
friend class CalendarService; friend class CalendarService;
/** /**
* Multiple Calendar Implementation * Multiple Calendar Implementation
* @internal * @internal
*/ */
friend class DefaultCalendarFactory; friend class DefaultCalendarFactory;
#endif /* !UCONFIG_NO_SERVICE */ #endif /* !UCONFIG_NO_SERVICE */
/** /**
* @internal
* @return TRUE if this calendar has a default century (i.e. 03 -> 2003 ) * @return TRUE if this calendar has a default century (i.e. 03 -> 2003 )
* @internal
*/ */
virtual UBool haveDefaultCentury() const = 0; virtual UBool haveDefaultCentury() const = 0;
/** /**
* @internal
* @return the start of the default century, as a UDate * @return the start of the default century, as a UDate
* @internal
*/ */
virtual UDate defaultCenturyStart() const = 0; virtual UDate defaultCenturyStart() const = 0;
/** /**
* @internal
* @return the beginning year of the default century, as a year * @return the beginning year of the default century, as a year
* @internal
*/ */
virtual int32_t defaultCenturyStartYear() const = 0; virtual int32_t defaultCenturyStartYear() const = 0;
/** Get the locale for this calendar object. You can choose between val id and actual locale. /** Get the locale for this calendar object. You can choose between val id and actual locale.
* @param type type of the locale we're looking for (valid or actual) * @param type type of the locale we're looking for (valid or actual)
* @param status error code for the operation * @param status error code for the operation
* @return the locale * @return the locale
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
Locale getLocale(ULocDataLocaleType type, UErrorCode &status) const; Locale getLocale(ULocDataLocaleType type, UErrorCode &status) const;
 End of changes. 10 change blocks. 
8 lines changed or deleted 12 lines changed or added


 choicfmt.h   choicfmt.h 
/* /*
*************************************************************************** ***** *************************************************************************** *****
* Copyright (C) 1997-2011, International Business Machines * Copyright (C) 1997-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
*************************************************************************** ***** *************************************************************************** *****
* *
* File CHOICFMT.H * File CHOICFMT.H
* *
* Modification History: * Modification History:
* *
* Date Name Description * Date Name Description
* 02/19/97 aliu Converted from java. * 02/19/97 aliu Converted from java.
* 03/20/97 helena Finished first cut of implementation and got ri d * 03/20/97 helena Finished first cut of implementation and got ri d
skipping to change at line 421 skipping to change at line 421
* @param success Output param set to success/failure code on * @param success Output param set to success/failure code on
* exit. * exit.
* @return Reference to 'appendTo' parameter. * @return Reference to 'appendTo' parameter.
* @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments. * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/ */
virtual UnicodeString& format(const Formattable* objs, virtual UnicodeString& format(const Formattable* objs,
int32_t cnt, int32_t cnt,
UnicodeString& appendTo, UnicodeString& appendTo,
FieldPosition& pos, FieldPosition& pos,
UErrorCode& success) const; UErrorCode& success) const;
/**
* Formats an object using this object's choices.
*
*
* @param obj The object to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param pos On input: an alignment field, if desired.
* On output: the offsets of the alignment field.
* @param status Output param set to success/failure code on
* exit.
* @return Reference to 'appendTo' parameter.
* @deprecated ICU 49 Use MessageFormat instead, with plural and select
arguments.
*/
virtual UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo,
FieldPosition& pos,
UErrorCode& status) const;
/** using NumberFormat::parse;
* Redeclared NumberFormat method.
*
* @param obj The object to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param status Output param set to success/failure code on
* exit.
* @return Reference to 'appendTo' parameter.
* @deprecated ICU 49 Use MessageFormat instead, with plural and select
arguments.
*/
UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const;
/**
* Redeclared NumberFormat method.
* Formats a double number. These methods call the NumberFormat
* pure virtual format() methods with the default FieldPosition.
*
* @param number The value to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @return Reference to 'appendTo' parameter.
* @deprecated ICU 49 Use MessageFormat instead, with plural and select
arguments.
*/
UnicodeString& format( double number,
UnicodeString& appendTo) const;
/**
* Redeclared NumberFormat method.
* Formats an int32_t number. These methods call the NumberFormat
* pure virtual format() methods with the default FieldPosition.
*
* @param number The value to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @return Reference to 'appendTo' parameter.
* @deprecated ICU 49 Use MessageFormat instead, with plural and select
arguments.
*/
UnicodeString& format( int32_t number,
UnicodeString& appendTo) const;
/** /**
* Looks for the longest match of any message string on the input text a nd, * Looks for the longest match of any message string on the input text a nd,
* if there is a match, sets the result object to the corresponding rang e's number. * if there is a match, sets the result object to the corresponding rang e's number.
* *
* If no string matches, then the parsePosition is unchanged. * If no string matches, then the parsePosition is unchanged.
* *
* @param text The text to be parsed. * @param text The text to be parsed.
* @param result Formattable to be set to the parse result. * @param result Formattable to be set to the parse result.
* If parse fails, return contents are undefined. * If parse fails, return contents are undefined.
* @param parsePosition The position to start parsing at on input. * @param parsePosition The position to start parsing at on input.
* On output, moved to after the last successfully * On output, moved to after the last successfully
* parse character. On parse failure, does not cha nge. * parse character. On parse failure, does not cha nge.
* @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments. * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/ */
virtual void parse(const UnicodeString& text, virtual void parse(const UnicodeString& text,
Formattable& result, Formattable& result,
ParsePosition& parsePosition) const; ParsePosition& parsePosition) const;
/** /**
* Looks for the longest match of any message string on the input text
and,
* if there is a match, sets the result object to the corresponding ran
ge's number.
*
* If no string matches, then the UErrorCode is set to U_INVALID_FORMAT
_ERROR.
*
* @param text The text to be parsed.
* @param result Formattable to be set to the parse result.
* If parse fails, return contents are undefined.
* @param status Output param with the formatted string.
* @deprecated ICU 49 Use MessageFormat instead, with plural and select
arguments.
*/
virtual void parse(const UnicodeString& text,
Formattable& result,
UErrorCode& status) const;
/**
* Returns a unique class ID POLYMORPHICALLY. Part of ICU's "poor man's RTTI". * Returns a unique class ID POLYMORPHICALLY. Part of ICU's "poor man's RTTI".
* *
* @return The class ID for this object. All objects of a * @return The class ID for this object. All objects of a
* given class have the same class ID. Objects of * given class have the same class ID. Objects of
* other classes have different class IDs. * other classes have different class IDs.
* @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments. * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/ */
virtual UClassID getDynamicClassID(void) const; virtual UClassID getDynamicClassID(void) const;
/** /**
skipping to change at line 660 skipping to change at line 585
* *
* Because of the nature of interval 0, fClosures[0] has no * Because of the nature of interval 0, fClosures[0] has no
* effect. * effect.
*/ */
// double* fChoiceLimits; // double* fChoiceLimits;
// UBool* fClosures; // UBool* fClosures;
// UnicodeString* fChoiceFormats; // UnicodeString* fChoiceFormats;
// int32_t fCount; // int32_t fCount;
}; };
inline UnicodeString&
ChoiceFormat::format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const {
// Don't use Format:: - use immediate base class only,
// in case immediate base modifies behavior later.
return NumberFormat::format(obj, appendTo, status);
}
inline UnicodeString&
ChoiceFormat::format(double number,
UnicodeString& appendTo) const {
return NumberFormat::format(number, appendTo);
}
inline UnicodeString&
ChoiceFormat::format(int32_t number,
UnicodeString& appendTo) const {
return NumberFormat::format(number, appendTo);
}
U_NAMESPACE_END U_NAMESPACE_END
#endif // U_HIDE_DEPRECATED_API #endif // U_HIDE_DEPRECATED_API
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif // CHOICFMT_H #endif // CHOICFMT_H
//eof //eof
 End of changes. 5 change blocks. 
105 lines changed or deleted 2 lines changed or added


 coleitr.h   coleitr.h 
/* /*
************************************************************************** **** ************************************************************************** ****
* Copyright (C) 1997-2008, International Business Machines * Copyright (C) 1997-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
************************************************************************** **** ************************************************************************** ****
*/ */
/** /**
* \file * \file
* \brief C++ API: Collation Element Iterator. * \brief C++ API: Collation Element Iterator.
*/ */
/** /**
skipping to change at line 90 skipping to change at line 90
* rbc->createCollationElementIterator( str ); * rbc->createCollationElementIterator( str );
* int32_t order = c->next(success); * int32_t order = c->next(success);
* c->reset(); * c->reset();
* order = c->previous(success); * order = c->previous(success);
* delete c; * delete c;
* delete rbc; * delete rbc;
* } * }
* \endcode * \endcode
* </pre> * </pre>
* <p> * <p>
* CollationElementIterator::next returns the collation order of the next * The method next() returns the collation order of the next character based
* character based on the comparison level of the collator. on
* CollationElementIterator::previous returns the collation order of the * the comparison level of the collator. The method previous() returns the
* previous character based on the comparison level of the collator. * collation order of the previous character based on the comparison level o
* The Collation Element Iterator moves only in one direction between calls f
to * the collator. The Collation Element Iterator moves only in one direction
* CollationElementIterator::reset. That is, CollationElementIterator::next( * between calls to reset(), setOffset(), or setText(). That is, next()
) * and previous() can not be inter-used. Whenever previous() is to be called
* and CollationElementIterator::previous can not be inter-used. Whenever after
* CollationElementIterator::previous is to be called after * next() or vice versa, reset(), setOffset() or setText() has to be called
* CollationElementIterator::next() or vice versa, first
* CollationElementIterator::reset has to be called first to reset the statu * to reset the status, shifting pointers to either the end or the start of
s, * the string (reset() or setText()), or the specified position (setOffset()
* shifting pointers to either the end or the start of the string. Hence at ).
the * Hence at the next call of next() or previous(), the first or last collati
* next call of CollationElementIterator::previous or on order,
* CollationElementIterator::next(), the first or last collation order will * or collation order at the spefcifieid position will be returned. If a cha
be nge of
* returned. * direction is done without one of these calls, the result is undefined.
* If a change of direction is done without a CollationElementIterator::rese * <p>
t(), * The result of a forward iterate (next()) and reversed result of the backw
* the result is undefined. ard
* The result of a forward iterate (CollationElementIterator::next) and * iterate (previous()) on the same string are equivalent, if collation orde
* reversed result of the backward iterate (CollationElementIterator::previo rs
us) * with the value UCOL_IGNORABLE are ignored.
* on the same string are equivalent, if collation orders with the value
* UCOL_IGNORABLE are ignored.
* Character based on the comparison level of the collator. A collation ord er * Character based on the comparison level of the collator. A collation ord er
* consists of primary order, secondary order and tertiary order. The data * consists of primary order, secondary order and tertiary order. The data
* type of the collation order is <strong>t_int32</strong>. * type of the collation order is <strong>t_int32</strong>.
* *
* Note, CollationElementIterator should not be subclassed. * Note, CollationElementIterator should not be subclassed.
* @see Collator * @see Collator
* @see RuleBasedCollator * @see RuleBasedCollator
* @version 1.8 Jan 16 2001 * @version 1.8 Jan 16 2001
*/ */
class U_I18N_API CollationElementIterator : public UObject { class U_I18N_API CollationElementIterator : public UObject {
skipping to change at line 289 skipping to change at line 285
*/ */
virtual UClassID getDynamicClassID() const; virtual UClassID getDynamicClassID() const;
/** /**
* ICU "poor man's RTTI", returns a UClassID for this class. * ICU "poor man's RTTI", returns a UClassID for this class.
* *
* @stable ICU 2.2 * @stable ICU 2.2
*/ */
static UClassID U_EXPORT2 getStaticClassID(); static UClassID U_EXPORT2 getStaticClassID();
protected: private:
// CollationElementIterator protected constructors --------------------
------
/**
* @stable ICU 2.0
*/
friend class RuleBasedCollator; friend class RuleBasedCollator;
/** /**
* CollationElementIterator constructor. This takes the source string an d the * CollationElementIterator constructor. This takes the source string an d the
* collation object. The cursor will walk thru the source string based o n the * collation object. The cursor will walk thru the source string based o n the
* predefined collation rules. If the source string is empty, NULLORDER will * predefined collation rules. If the source string is empty, NULLORDER will
* be returned on the calls to next(). * be returned on the calls to next().
* @param sourceText the source string. * @param sourceText the source string.
* @param order the collation object. * @param order the collation object.
* @param status the error code status. * @param status the error code status.
* @stable ICU 2.0
*/ */
CollationElementIterator(const UnicodeString& sourceText, CollationElementIterator(const UnicodeString& sourceText,
const RuleBasedCollator* order, UErrorCode& status); const RuleBasedCollator* order, UErrorCode& status);
/** /**
* CollationElementIterator constructor. This takes the source string an d the * CollationElementIterator constructor. This takes the source string an d the
* collation object. The cursor will walk thru the source string based on the * collation object. The cursor will walk thru the source string based on the
* predefined collation rules. If the source string is empty, NULLORDER will * predefined collation rules. If the source string is empty, NULLORDER will
* be returned on the calls to next(). * be returned on the calls to next().
* @param sourceText the source string. * @param sourceText the source string.
* @param order the collation object. * @param order the collation object.
* @param status the error code status. * @param status the error code status.
* @stable ICU 2.0
*/ */
CollationElementIterator(const CharacterIterator& sourceText, CollationElementIterator(const CharacterIterator& sourceText,
const RuleBasedCollator* order, UErrorCode& status); const RuleBasedCollator* order, UErrorCode& status);
// CollationElementIterator protected methods -------------------------
------
/** /**
* Assignment operator * Assignment operator
* *
* @param other the object to be copied * @param other the object to be copied
* @stable ICU 2.0
*/ */
const CollationElementIterator& const CollationElementIterator&
operator=(const CollationElementIterator& other); operator=(const CollationElementIterator& other);
private:
CollationElementIterator(); // default constructor not implemented CollationElementIterator(); // default constructor not implemented
// CollationElementIterator private data members ---------------------- ------ // CollationElementIterator private data members ---------------------- ------
/** /**
* Data wrapper for collation elements * Data wrapper for collation elements
*/ */
UCollationElements *m_data_; UCollationElements *m_data_;
/** /**
* Indicates if m_data_ belongs to this object. * Indicates if m_data_ belongs to this object.
*/ */
UBool isDataOwned_; UBool isDataOwned_;
}; };
// CollationElementIterator inline method defination ---------------------- ---- // CollationElementIterator inline method defination ---------------------- ----
/** /**
* Get the primary order of a collation order. * Get the primary order of a collation order.
* @param order the collation order * @param order the collation order
* @return the primary order of a collation order. * @return the primary order of a collation order.
*/ */
inline int32_t CollationElementIterator::primaryOrder(int32_t order) inline int32_t CollationElementIterator::primaryOrder(int32_t order)
 End of changes. 9 change blocks. 
43 lines changed or deleted 27 lines changed or added


 datefmt.h   datefmt.h 
/* /*
************************************************************************** ****** ************************************************************************** ******
* Copyright (C) 1997-2012, International Business Machines * Copyright (C) 1997-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
************************************************************************** ****** ************************************************************************** ******
* *
* File DATEFMT.H * File DATEFMT.H
* *
* Modification History: * Modification History:
* *
* Date Name Description * Date Name Description
* 02/19/97 aliu Converted from java. * 02/19/97 aliu Converted from java.
* 04/01/97 aliu Added support for centuries. * 04/01/97 aliu Added support for centuries.
skipping to change at line 31 skipping to change at line 31
#include "unicode/utypes.h" #include "unicode/utypes.h"
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
#include "unicode/udat.h" #include "unicode/udat.h"
#include "unicode/calendar.h" #include "unicode/calendar.h"
#include "unicode/numfmt.h" #include "unicode/numfmt.h"
#include "unicode/format.h" #include "unicode/format.h"
#include "unicode/locid.h" #include "unicode/locid.h"
#include "unicode/enumset.h"
/** /**
* \file * \file
* \brief C++ API: Abstract class for converting dates. * \brief C++ API: Abstract class for converting dates.
*/ */
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
class TimeZone; class TimeZone;
class DateTimePatternGenerator; class DateTimePatternGenerator;
// explicit template instantiation. see digitlst.h
#if defined (_MSC_VER)
template class U_I18N_API EnumSet<UDateFormatBooleanAttribute,
0,
UDAT_BOOLEAN_ATTRIBUTE_COUNT>;
#endif
/** /**
* DateFormat is an abstract class for a family of classes that convert dat es and * DateFormat is an abstract class for a family of classes that convert dat es and
* times from their internal representations to textual form and back again in a * times from their internal representations to textual form and back again in a
* language-independent manner. Converting from the internal representation (milliseconds * language-independent manner. Converting from the internal representation (milliseconds
* since midnight, January 1, 1970) to text is known as "formatting," and c onverting * since midnight, January 1, 1970) to text is known as "formatting," and c onverting
* from text to millis is known as "parsing." We currently define only one concrete * from text to millis is known as "parsing." We currently define only one concrete
* subclass of DateFormat: SimpleDateFormat, which can handle pretty much a ll normal * subclass of DateFormat: SimpleDateFormat, which can handle pretty much a ll normal
* date formatting and parsing actions. * date formatting and parsing actions.
* <P> * <P>
* DateFormat helps you to format and parse dates for any locale. Your code can * DateFormat helps you to format and parse dates for any locale. Your code can
skipping to change at line 372 skipping to change at line 380
* *
* @param date The UDate value to be formatted into a string. * @param date The UDate value to be formatted into a string.
* @param appendTo Output parameter to receive result. * @param appendTo Output parameter to receive result.
* Result is appended to existing contents. * Result is appended to existing contents.
* @return Reference to 'appendTo' parameter. * @return Reference to 'appendTo' parameter.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
UnicodeString& format(UDate date, UnicodeString& appendTo) const; UnicodeString& format(UDate date, UnicodeString& appendTo) const;
/** /**
* Redeclared Format method.
*
* @param obj The object to be formatted into a string.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param status Output param filled with success/failure status.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.0
*/
UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const;
/**
* Parse a date/time string. For example, a time text "07/10/96 4:5 PM, PDT" * Parse a date/time string. For example, a time text "07/10/96 4:5 PM, PDT"
* will be parsed into a UDate that is equivalent to Date(837039928046) . * will be parsed into a UDate that is equivalent to Date(837039928046) .
* Parsing begins at the beginning of the string and proceeds as far as * Parsing begins at the beginning of the string and proceeds as far as
* possible. Assuming no parse errors were encountered, this function * possible. Assuming no parse errors were encountered, this function
* doesn't return any information about how much of the string was cons umed * doesn't return any information about how much of the string was cons umed
* by the parsing. If you need that information, use the version of * by the parsing. If you need that information, use the version of
* parse() that takes a ParsePosition. * parse() that takes a ParsePosition.
* <P> * <P>
* By default, parsing is lenient: If the input is not in the form used by * By default, parsing is lenient: If the input is not in the form used by
* this object's format method but can still be parsed as a date, then the * this object's format method but can still be parsed as a date, then the
skipping to change at line 585 skipping to change at line 579
/** /**
* Gets the set of locales for which DateFormats are installed. * Gets the set of locales for which DateFormats are installed.
* @param count Filled in with the number of locales in the list that i s returned. * @param count Filled in with the number of locales in the list that i s returned.
* @return the set of locales for which DateFormats are installed. The caller * @return the set of locales for which DateFormats are installed. The caller
* does NOT own this list and must not delete it. * does NOT own this list and must not delete it.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
static const Locale* U_EXPORT2 getAvailableLocales(int32_t& count); static const Locale* U_EXPORT2 getAvailableLocales(int32_t& count);
/** /**
* Returns true if the formatter is set for lenient parsing. * Returns true if the encapsulated Calendar object is set for lenient parsing.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual UBool isLenient(void) const; virtual UBool isLenient(void) const;
/** /**
* Specify whether or not date/time parsing is to be lenient. With leni ent * Specify whether or not date/time parsing is to be lenient. With leni ent
* parsing, the parser may use heuristics to interpret inputs that do n ot * parsing, the parser may use heuristics to interpret inputs that do n ot
* precisely match this object's format. With strict parsing, inputs mu st * precisely match this object's format. With strict parsing, inputs mu st
* match this object's format. * match this object's format.
* *
* Note: This method is specific to the encapsulated Calendar object.
DateFormat
* leniency aspects are controlled by setBooleanAttribute.
*
* @param lenient True specifies date/time interpretation to be lenien t. * @param lenient True specifies date/time interpretation to be lenien t.
* @see Calendar::setLenient * @see Calendar::setLenient
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual void setLenient(UBool lenient); virtual void setLenient(UBool lenient);
/** /**
* Gets the calendar associated with this date/time formatter. * Gets the calendar associated with this date/time formatter.
* @return the calendar associated with this date/time formatter. * @return the calendar associated with this date/time formatter.
* @stable ICU 2.0 * @stable ICU 2.0
skipping to change at line 674 skipping to change at line 671
*/ */
virtual void adoptTimeZone(TimeZone* zoneToAdopt); virtual void adoptTimeZone(TimeZone* zoneToAdopt);
/** /**
* Sets the time zone for the calendar of this DateFormat object. * Sets the time zone for the calendar of this DateFormat object.
* @param zone the new time zone. * @param zone the new time zone.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual void setTimeZone(const TimeZone& zone); virtual void setTimeZone(const TimeZone& zone);
/**
* Set an boolean attribute on this DateFormat.
* May return U_UNSUPPORTED_ERROR if this instance does not support
* the specified attribute.
* @param attr the attribute to set
* @param newvalue new value
* @param status the error type
* @return *this - for chaining (example: format.setAttribute(...).setA
ttribute(...) )
* @internal ICU technology preview
*/
virtual DateFormat& U_EXPORT2 setBooleanAttribute(UDateFormatBooleanAt
tribute attr,
UBoo
l newvalue,
UErr
orCode &status);
/**
* Get an boolean from this DateFormat
* May return U_UNSUPPORTED_ERROR if this instance does not support
* the specified attribute.
* @param attr the attribute to set
* @param status the error type
* @return the attribute value. Undefined if there is an error.
* @internal ICU technology preview
*/
virtual UBool U_EXPORT2 getBooleanAttribute(UDateFormatBooleanAttribute
attr, UErrorCode &status) const;
protected: protected:
/** /**
* Default constructor. Creates a DateFormat with no Calendar or Numbe rFormat * Default constructor. Creates a DateFormat with no Calendar or Numbe rFormat
* associated with it. This constructor depends on the subclasses to f ill in * associated with it. This constructor depends on the subclasses to f ill in
* the calendar and numberFormat fields. * the calendar and numberFormat fields.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
DateFormat(); DateFormat();
/** /**
skipping to change at line 722 skipping to change at line 745
/** /**
* Gets the date/time formatter with the given formatting styles for th e * Gets the date/time formatter with the given formatting styles for th e
* given locale. * given locale.
* @param dateStyle the given date formatting style. * @param dateStyle the given date formatting style.
* @param timeStyle the given time formatting style. * @param timeStyle the given time formatting style.
* @param inLocale the given locale. * @param inLocale the given locale.
* @return a date/time formatter, or 0 on failure. * @return a date/time formatter, or 0 on failure.
*/ */
static DateFormat* U_EXPORT2 create(EStyle timeStyle, EStyle dateStyle, const Locale& inLocale); static DateFormat* U_EXPORT2 create(EStyle timeStyle, EStyle dateStyle, const Locale& inLocale);
/**
* enum set of active boolean attributes for this instance
*/
EnumSet<UDateFormatBooleanAttribute, 0, UDAT_BOOLEAN_ATTRIBUTE_COUNT> f
BoolFlags;
public: public:
#ifndef U_HIDE_OBSOLETE_API #ifndef U_HIDE_OBSOLETE_API
/** /**
* Field selector for FieldPosition for DateFormat fields. * Field selector for FieldPosition for DateFormat fields.
* @obsolete ICU 3.4 use UDateFormatField instead, since this API will be * @obsolete ICU 3.4 use UDateFormatField instead, since this API will be
* removed in that release * removed in that release
*/ */
enum EField enum EField
{ {
// Obsolete; use UDateFormatField instead // Obsolete; use UDateFormatField instead
skipping to change at line 779 skipping to change at line 807
WEEK_OF_YEAR_FIELD = UDAT_WEEK_OF_YEAR_FIELD, WEEK_OF_YEAR_FIELD = UDAT_WEEK_OF_YEAR_FIELD,
WEEK_OF_MONTH_FIELD = UDAT_WEEK_OF_MONTH_FIELD, WEEK_OF_MONTH_FIELD = UDAT_WEEK_OF_MONTH_FIELD,
AM_PM_FIELD = UDAT_AM_PM_FIELD, AM_PM_FIELD = UDAT_AM_PM_FIELD,
HOUR1_FIELD = UDAT_HOUR1_FIELD, HOUR1_FIELD = UDAT_HOUR1_FIELD,
HOUR0_FIELD = UDAT_HOUR0_FIELD, HOUR0_FIELD = UDAT_HOUR0_FIELD,
TIMEZONE_FIELD = UDAT_TIMEZONE_FIELD TIMEZONE_FIELD = UDAT_TIMEZONE_FIELD
}; };
#endif /* U_HIDE_OBSOLETE_API */ #endif /* U_HIDE_OBSOLETE_API */
}; };
inline UnicodeString&
DateFormat::format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const {
return Format::format(obj, appendTo, status);
}
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif // _DATEFMT #endif // _DATEFMT
//eof //eof
 End of changes. 9 change blocks. 
22 lines changed or deleted 51 lines changed or added


 dbbi.h   dbbi.h 
skipping to change at line 30 skipping to change at line 30
* \brief C++ API: Dictionary Based Break Iterator * \brief C++ API: Dictionary Based Break Iterator
*/ */
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
#ifndef U_HIDE_DEPRECATED_API #ifndef U_HIDE_DEPRECATED_API
/** /**
* An obsolete subclass of RuleBasedBreakIterator. Handling of dictionary- * An obsolete subclass of RuleBasedBreakIterator. Handling of dictionary-
* based break iteration has been folded into the base class. This class * based break iteration has been folded into the base class. This class
* is deprecated as of ICU 3.6. * is deprecated as of ICU 3.6.
* @deprecated ICU 3.6
*/ */
typedef RuleBasedBreakIterator DictionaryBasedBreakIterator; typedef RuleBasedBreakIterator DictionaryBasedBreakIterator;
#endif /* U_HIDE_DEPRECATED_API */ #endif /* U_HIDE_DEPRECATED_API */
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_BREAK_ITERATION */ #endif /* #if !UCONFIG_NO_BREAK_ITERATION */
#endif #endif
 End of changes. 1 change blocks. 
0 lines changed or deleted 1 lines changed or added


 dcfmtsym.h   dcfmtsym.h 
skipping to change at line 189 skipping to change at line 189
/** /**
* Create a DecimalFormatSymbols object for the default locale. * Create a DecimalFormatSymbols object for the default locale.
* This constructor will not fail. If the resource file data is * This constructor will not fail. If the resource file data is
* not available, it will use hard-coded last-resort data and * not available, it will use hard-coded last-resort data and
* set status to U_USING_FALLBACK_ERROR. * set status to U_USING_FALLBACK_ERROR.
* *
* @param status Input/output parameter, set to success or * @param status Input/output parameter, set to success or
* failure code upon return. * failure code upon return.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
DecimalFormatSymbols( UErrorCode& status); DecimalFormatSymbols(UErrorCode& status);
#ifndef U_HIDE_DRAFT_API
/**
* Creates a DecimalFormatSymbols object with last-resort data.
* Intended for callers who cache the symbols data and
* set all symbols on the resulting object.
*
* The last-resort symbols are similar to those for the root data,
* except that the grouping separators are empty,
* the NaN symbol is U+FFFD rather than "NaN",
* and the CurrencySpacing patterns are empty.
*
* @param status Input/output parameter, set to success or
* failure code upon return.
* @return last-resort symbols
* @draft ICU 52
*/
static DecimalFormatSymbols* createWithLastResortData(UErrorCode& statu
s);
#endif /* U_HIDE_DRAFT_API */
/** /**
* Copy constructor. * Copy constructor.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
DecimalFormatSymbols(const DecimalFormatSymbols&); DecimalFormatSymbols(const DecimalFormatSymbols&);
/** /**
* Assignment operator. * Assignment operator.
* @stable ICU 2.0 * @stable ICU 2.0
skipping to change at line 313 skipping to change at line 332
virtual UClassID getDynamicClassID() const; virtual UClassID getDynamicClassID() const;
/** /**
* ICU "poor man's RTTI", returns a UClassID for this class. * ICU "poor man's RTTI", returns a UClassID for this class.
* *
* @stable ICU 2.2 * @stable ICU 2.2
*/ */
static UClassID U_EXPORT2 getStaticClassID(); static UClassID U_EXPORT2 getStaticClassID();
private: private:
DecimalFormatSymbols(); // default constructor not implemented DecimalFormatSymbols();
/** /**
* 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
skipping to change at line 403 skipping to change at line 422
DecimalFormatSymbols::getSymbol(ENumberFormatSymbol symbol) const { DecimalFormatSymbols::getSymbol(ENumberFormatSymbol symbol) const {
const UnicodeString *strPtr; const UnicodeString *strPtr;
if(symbol < kFormatSymbolCount) { if(symbol < kFormatSymbolCount) {
strPtr = &fSymbols[symbol]; strPtr = &fSymbols[symbol];
} else { } else {
strPtr = &fNoSymbol; strPtr = &fNoSymbol;
} }
return *strPtr; return *strPtr;
} }
#ifndef U_HIDE_INTERNAL_API
inline const UnicodeString & inline const UnicodeString &
DecimalFormatSymbols::getConstSymbol(ENumberFormatSymbol symbol) const { DecimalFormatSymbols::getConstSymbol(ENumberFormatSymbol symbol) const {
const UnicodeString *strPtr; const UnicodeString *strPtr;
if(symbol < kFormatSymbolCount) { if(symbol < kFormatSymbolCount) {
strPtr = &fSymbols[symbol]; strPtr = &fSymbols[symbol];
} else { } else {
strPtr = &fNoSymbol; strPtr = &fNoSymbol;
} }
return *strPtr; return *strPtr;
} }
#endif /* U_HIDE_INTERNAL_API */
// ------------------------------------- // -------------------------------------
inline void inline void
DecimalFormatSymbols::setSymbol(ENumberFormatSymbol symbol, const UnicodeSt ring &value, const UBool propogateDigits = TRUE) { 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, // 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 // then we automatically set the corresponding 1-9 digits
skipping to change at line 442 skipping to change at line 465
} }
} }
// ------------------------------------- // -------------------------------------
inline Locale inline Locale
DecimalFormatSymbols::getLocale() const { DecimalFormatSymbols::getLocale() const {
return locale; return locale;
} }
#ifndef U_HIDE_INTERNAL_API
inline const UChar* inline const UChar*
DecimalFormatSymbols::getCurrencyPattern() const { DecimalFormatSymbols::getCurrencyPattern() const {
return currPattern; return currPattern;
} }
#endif /* U_HIDE_INTERNAL_API */
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif // _DCFMTSYM #endif // _DCFMTSYM
//eof //eof
 End of changes. 6 change blocks. 
2 lines changed or deleted 28 lines changed or added


 decimfmt.h   decimfmt.h 
skipping to change at line 44 skipping to change at line 44
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
#include "unicode/dcfmtsym.h" #include "unicode/dcfmtsym.h"
#include "unicode/numfmt.h" #include "unicode/numfmt.h"
#include "unicode/locid.h" #include "unicode/locid.h"
#include "unicode/fpositer.h" #include "unicode/fpositer.h"
#include "unicode/stringpiece.h" #include "unicode/stringpiece.h"
#include "unicode/curramt.h" #include "unicode/curramt.h"
#include "unicode/enumset.h" #include "unicode/enumset.h"
#ifndef U_HIDE_INTERNAL_API
/** /**
* \def UNUM_DECIMALFORMAT_INTERNAL_SIZE * \def UNUM_DECIMALFORMAT_INTERNAL_SIZE
* @internal * @internal
*/ */
#if UCONFIG_FORMAT_FASTPATHS_49 #if UCONFIG_FORMAT_FASTPATHS_49
#define UNUM_DECIMALFORMAT_INTERNAL_SIZE 16 #define UNUM_DECIMALFORMAT_INTERNAL_SIZE 16
#endif #endif
#endif /* U_HIDE_INTERNAL_API */
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
class DigitList; class DigitList;
class ChoiceFormat; class ChoiceFormat;
class CurrencyPluralInfo; class CurrencyPluralInfo;
class Hashtable; class Hashtable;
class UnicodeSet; class UnicodeSet;
class FieldPositionHandler; class FieldPositionHandler;
class DecimalFormatStaticSets;
class FixedDecimal;
// explicit template instantiation. see digitlst.h // explicit template instantiation. see digitlst.h
#if defined (_MSC_VER) #if defined (_MSC_VER)
template class U_I18N_API EnumSet<UNumberFormatAttribute, template class U_I18N_API EnumSet<UNumberFormatAttribute,
UNUM_MAX_NONBOOLEAN_ATTRIBUTE+1, UNUM_MAX_NONBOOLEAN_ATTRIBUTE+1,
UNUM_LIMIT_BOOLEAN_ATTRIBUTE>; UNUM_LIMIT_BOOLEAN_ATTRIBUTE>;
#endif #endif
/** /**
* DecimalFormat is a concrete subclass of NumberFormat that formats decima l * DecimalFormat is a concrete subclass of NumberFormat that formats decima l
skipping to change at line 1101 skipping to change at line 1101
* On output: the offsets of the alignment field. * On output: the offsets of the alignment field.
* @param status Output param filled with success/failure status. * @param status Output param filled with success/failure status.
* @return Reference to 'appendTo' parameter. * @return Reference to 'appendTo' parameter.
* @internal * @internal
*/ */
virtual UnicodeString& format(const DigitList &number, virtual UnicodeString& format(const DigitList &number,
UnicodeString& appendTo, UnicodeString& appendTo,
FieldPosition& pos, FieldPosition& pos,
UErrorCode& status) const; UErrorCode& status) const;
/** using NumberFormat::parse;
* Format a Formattable using base-10 representation.
*
* @param obj The value to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param pos On input: an alignment field, if desired.
* On output: the offsets of the alignment field.
* @param status Error code indicating success or failure.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.0
*/
virtual UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo,
FieldPosition& pos,
UErrorCode& status) const;
/**
* Redeclared NumberFormat method.
* Formats an object to produce a string.
*
* @param obj The object to format.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param status Output parameter filled in with success or failure
status.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.0
*/
UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const;
/**
* Redeclared NumberFormat method.
* Format a double number.
*
* @param number The value to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.0
*/
UnicodeString& format(double number,
UnicodeString& appendTo) const;
/**
* Redeclared NumberFormat method.
* Format a long number. These methods call the NumberFormat
* pure virtual format() methods with the default FieldPosition.
*
* @param number The value to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.0
*/
UnicodeString& format(int32_t number,
UnicodeString& appendTo) const;
/**
* Redeclared NumberFormat method.
* Format an int64 number. These methods call the NumberFormat
* pure virtual format() methods with the default FieldPosition.
*
* @param number The value to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.8
*/
UnicodeString& format(int64_t number,
UnicodeString& appendTo) const;
/** /**
* Parse the given string using this object's choices. The method * Parse the given string using this object's choices. The method
* does string comparisons to try to find an optimal match. * does string comparisons to try to find an optimal match.
* If no object can be parsed, index is unchanged, and NULL is * If no object can be parsed, index is unchanged, and NULL is
* returned. The result is returned as the most parsimonious * returned. The result is returned as the most parsimonious
* type of Formattable that will accomodate all of the * type of Formattable that will accomodate all of the
* necessary precision. For example, if the result is exactly 12, * necessary precision. For example, if the result is exactly 12,
* it will be returned as a long. However, if it is 1.5, it will * it will be returned as a long. However, if it is 1.5, it will
* be returned as a double. * be returned as a double.
* *
skipping to change at line 1196 skipping to change at line 1126
* @param parsePosition The position to start parsing at on input. * @param parsePosition The position to start parsing at on input.
* On output, moved to after the last successfully * On output, moved to after the last successfully
* parse character. On parse failure, does not cha nge. * parse character. On parse failure, does not cha nge.
* @see Formattable * @see Formattable
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual void parse(const UnicodeString& text, virtual void parse(const UnicodeString& text,
Formattable& result, Formattable& result,
ParsePosition& parsePosition) const; ParsePosition& parsePosition) const;
// Declare here again to get rid of function hiding problems.
/**
* Parse the given string using this object's choices.
*
* @param text The text to be parsed.
* @param result Formattable to be set to the parse result.
* @param status Output parameter filled in with success or failure
status.
* @stable ICU 2.0
*/
virtual void parse(const UnicodeString& text,
Formattable& result,
UErrorCode& status) const;
/** /**
* Parses text from the given string as a currency amount. Unlike * Parses text from the given string as a currency amount. Unlike
* the parse() method, this method will attempt to parse a generic * the parse() method, this method will attempt to parse a generic
* currency name, searching for a match of this object's locale's * currency name, searching for a match of this object's locale's
* currency display names, or for a 3-letter ISO currency code. * currency display names, or for a 3-letter ISO currency code.
* This method will fail if this format is not a currency format, * This method will fail if this format is not a currency format,
* that is, if it does not contain the currency pattern symbol * that is, if it does not contain the currency pattern symbol
* (U+00A4) in its prefix or suffix. * (U+00A4) in its prefix or suffix.
* *
* @param text the string to parse * @param text the string to parse
skipping to change at line 1382 skipping to change at line 1299
* For a permill, set the suffixes to have "\\u2031" and the multiplier to be 1000. * For a permill, set the suffixes to have "\\u2031" and the multiplier to be 1000.
* *
* @param newValue the new value of the multiplier for use in percen t, permill, etc. * @param newValue the new value of the multiplier for use in percen t, permill, etc.
* Examples: with 100, 1.23 -> "123", and "123" -> 1.23 * Examples: with 100, 1.23 -> "123", and "123" -> 1.23
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual void setMultiplier(int32_t newValue); virtual void setMultiplier(int32_t newValue);
/** /**
* Get the rounding increment. * Get the rounding increment.
* @return A positive rounding increment, or 0.0 if a rounding * @return A positive rounding increment, or 0.0 if a custom rounding
* increment is not in effect. * increment is not in effect.
* @see #setRoundingIncrement * @see #setRoundingIncrement
* @see #getRoundingMode * @see #getRoundingMode
* @see #setRoundingMode * @see #setRoundingMode
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual double getRoundingIncrement(void) const; virtual double getRoundingIncrement(void) const;
/** /**
* Set the rounding increment. In the absence of a rounding increment, * Set the rounding increment. In the absence of a rounding increment,
* numbers will be rounded to the number of digits displayed. * numbers will be rounded to the number of digits displayed.
* @param newValue A positive rounding increment. * @param newValue A positive rounding increment, or 0.0 to
* use the default rounding increment.
* Negative increments are equivalent to 0.0. * Negative increments are equivalent to 0.0.
* @see #getRoundingIncrement * @see #getRoundingIncrement
* @see #getRoundingMode * @see #getRoundingMode
* @see #setRoundingMode * @see #setRoundingMode
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual void setRoundingIncrement(double newValue); virtual void setRoundingIncrement(double newValue);
/** /**
* Get the rounding mode. * Get the rounding mode.
skipping to change at line 1527 skipping to change at line 1445
/** /**
* Return whether or not scientific notation is used. * Return whether or not scientific notation is used.
* @return TRUE if this object formats and parses scientific notation * @return TRUE if this object formats and parses scientific notation
* @see #setScientificNotation * @see #setScientificNotation
* @see #getMinimumExponentDigits * @see #getMinimumExponentDigits
* @see #setMinimumExponentDigits * @see #setMinimumExponentDigits
* @see #isExponentSignAlwaysShown * @see #isExponentSignAlwaysShown
* @see #setExponentSignAlwaysShown * @see #setExponentSignAlwaysShown
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual UBool isScientificNotation(void); virtual UBool isScientificNotation(void) const;
/** /**
* Set whether or not scientific notation is used. When scientific nota tion * Set whether or not scientific notation is used. When scientific nota tion
* is used, the effective maximum number of integer digits is <= 8. If the * is used, the effective maximum number of integer digits is <= 8. If the
* maximum number of integer digits is set to more than 8, the effectiv e * maximum number of integer digits is set to more than 8, the effectiv e
* maximum will be 1. This allows this call to generate a 'default' sc ientific * maximum will be 1. This allows this call to generate a 'default' sc ientific
* number format without additional changes. * number format without additional changes.
* @param useScientific TRUE if this object formats and parses scientif ic * @param useScientific TRUE if this object formats and parses scientif ic
* notation * notation
* @see #isScientificNotation * @see #isScientificNotation
skipping to change at line 1584 skipping to change at line 1502
* @return TRUE if the exponent is always prefixed with either the * @return TRUE if the exponent is always prefixed with either the
* localized minus sign or the localized plus sign, false if only negat ive * localized minus sign or the localized plus sign, false if only negat ive
* exponents are prefixed with the localized minus sign. * exponents are prefixed with the localized minus sign.
* @see #setScientificNotation * @see #setScientificNotation
* @see #isScientificNotation * @see #isScientificNotation
* @see #setMinimumExponentDigits * @see #setMinimumExponentDigits
* @see #getMinimumExponentDigits * @see #getMinimumExponentDigits
* @see #setExponentSignAlwaysShown * @see #setExponentSignAlwaysShown
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual UBool isExponentSignAlwaysShown(void); virtual UBool isExponentSignAlwaysShown(void) const;
/** /**
* Set whether the exponent sign is always shown. This has no effect * Set whether the exponent sign is always shown. This has no effect
* unless scientific notation is in use. * unless scientific notation is in use.
* @param expSignAlways TRUE if the exponent is always prefixed with ei ther * @param expSignAlways TRUE if the exponent is always prefixed with ei ther
* the localized minus sign or the localized plus sign, false if only * the localized minus sign or the localized plus sign, false if only
* negative exponents are prefixed with the localized minus sign. * negative exponents are prefixed with the localized minus sign.
* @see #setScientificNotation * @see #setScientificNotation
* @see #isScientificNotation * @see #isScientificNotation
* @see #setMinimumExponentDigits * @see #setMinimumExponentDigits
skipping to change at line 1859 skipping to change at line 1777
* returns true. * returns true.
* @return the most significant digits that will be shown * @return the most significant digits that will be shown
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
int32_t getMaximumSignificantDigits() const; int32_t getMaximumSignificantDigits() const;
/** /**
* Sets the minimum number of significant digits that will be * Sets the minimum number of significant digits that will be
* displayed. If <code>min</code> is less than one then it is set * displayed. If <code>min</code> is less than one then it is set
* to one. If the maximum significant digits count is less than * to one. If the maximum significant digits count is less than
* <code>min</code>, then it is set to <code>min</code>. This * <code>min</code>, then it is set to <code>min</code>.
* value has no effect unless areSignificantDigits() returns true. * This function also enables the use of significant digits
* by this formatter - areSignificantDigitsUsed() will return TRUE.
* @see #areSignificantDigitsUsed
* @param min the fewest significant digits to be shown * @param min the fewest significant digits to be shown
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
void setMinimumSignificantDigits(int32_t min); void setMinimumSignificantDigits(int32_t min);
/** /**
* Sets the maximum number of significant digits that will be * Sets the maximum number of significant digits that will be
* displayed. If <code>max</code> is less than one then it is set * displayed. If <code>max</code> is less than one then it is set
* to one. If the minimum significant digits count is greater * to one. If the minimum significant digits count is greater
* than <code>max</code>, then it is set to <code>max</code>. * than <code>max</code>, then it is set to <code>max</code>.
* This value has no effect unless areSignificantDigits() returns * This function also enables the use of significant digits
* true. * by this formatter - areSignificantDigitsUsed() will return TRUE.
* @see #areSignificantDigitsUsed
* @param max the most significant digits to be shown * @param max the most significant digits to be shown
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
void setMaximumSignificantDigits(int32_t max); void setMaximumSignificantDigits(int32_t max);
/** /**
* Returns true if significant digits are in use, or false if * Returns true if significant digits are in use, or false if
* integer and fraction digit counts are in use. * integer and fraction digit counts are in use.
* @return true if significant digits are in use * @return true if significant digits are in use
* @stable ICU 3.0 * @stable ICU 3.0
skipping to change at line 1924 skipping to change at line 1845
*/ */
virtual void setCurrency(const UChar* theCurrency); virtual void setCurrency(const UChar* theCurrency);
/** /**
* The resource tags we use to retrieve decimal format data from * The resource tags we use to retrieve decimal format data from
* locale resource bundles. * locale resource bundles.
* @deprecated ICU 3.4. This string has no public purpose. Please don't use it. * @deprecated ICU 3.4. This string has no public purpose. Please don't use it.
*/ */
static const char fgNumberPatterns[]; static const char fgNumberPatterns[];
#ifndef U_HIDE_INTERNAL_API
/**
* Get a FixedDecimal corresponding to a double as it would be
* formatted by this DecimalFormat.
* Internal, not intended for public use.
* @internal
*/
FixedDecimal getFixedDecimal(double number, UErrorCode &status) const;
/**
* Get a FixedDecimal corresponding to a formattable as it would be
* formatted by this DecimalFormat.
* Internal, not intended for public use.
* @internal
*/
FixedDecimal getFixedDecimal(const Formattable &number, UErrorCode &st
atus) const;
/**
* Get a FixedDecimal corresponding to a DigitList as it would be
* formatted by this DecimalFormat. Note: the DigitList may be modifie
d.
* Internal, not intended for public use.
* @internal
*/
FixedDecimal getFixedDecimal(DigitList &number, UErrorCode &status) co
nst;
#endif /* U_HIDE_INTERNAL_API */
public: public:
/** /**
* Return the class ID for this class. This is useful only for * Return the class ID for this class. This is useful only for
* comparing to a return value from getDynamicClassID(). For example: * comparing to a return value from getDynamicClassID(). For example:
* <pre> * <pre>
* . Base* polymorphic_pointer = createPolymorphicObject(); * . Base* polymorphic_pointer = createPolymorphicObject();
* . if (polymorphic_pointer->getDynamicClassID() == * . if (polymorphic_pointer->getDynamicClassID() ==
* . Derived::getStaticClassID()) ... * . Derived::getStaticClassID()) ...
* </pre> * </pre>
skipping to change at line 1959 skipping to change at line 1906
*/ */
virtual UClassID getDynamicClassID(void) const; virtual UClassID getDynamicClassID(void) const;
private: private:
DecimalFormat(); // default constructor not implemented DecimalFormat(); // default constructor not implemented
int32_t precision() const; int32_t precision() const;
/** /**
* Initialize all fields of a new DecimalFormatter. * Initialize all fields of a new DecimalFormatter to a safe default value.
* Common code for use by constructors. * Common code for use by constructors.
*/ */
void init(UErrorCode& status); void init();
/** /**
* Do real work of constructing a new DecimalFormat. * Do real work of constructing a new DecimalFormat.
*/ */
void construct(UErrorCode& status, void construct(UErrorCode& status,
UParseError& parseErr, UParseError& parseErr,
const UnicodeString* pattern = 0, const UnicodeString* pattern = 0,
DecimalFormatSymbols* symbolsToAdopt = 0 DecimalFormatSymbols* symbolsToAdopt = 0
); );
/** /**
* Does the real work of generating a pattern. * Does the real work of generating a pattern.
* *
* @param result Output param which will receive the pattern. * @param result Output param which will receive the pattern.
* Previous contents are deleted. * Previous contents are deleted.
skipping to change at line 2051 skipping to change at line 1998
enum { enum {
fgStatusInfinite, fgStatusInfinite,
fgStatusLength // Leave last in list. fgStatusLength // Leave last in list.
} StatusFlags; } StatusFlags;
UBool subparse(const UnicodeString& text, UBool subparse(const UnicodeString& text,
const UnicodeString* negPrefix, const UnicodeString* negPrefix,
const UnicodeString* negSuffix, const UnicodeString* negSuffix,
const UnicodeString* posPrefix, const UnicodeString* posPrefix,
const UnicodeString* posSuffix, const UnicodeString* posSuffix,
UBool currencyParsing, UBool complexCurrencyParsing,
int8_t type, int8_t type,
ParsePosition& parsePosition, ParsePosition& parsePosition,
DigitList& digits, UBool* status, DigitList& digits, UBool* status,
UChar* currency) const; UChar* currency) const;
// Mixed style parsing for currency. // Mixed style parsing for currency.
// It parses against the current currency pattern // It parses against the current currency pattern
// using complex affix comparison // using complex affix comparison
// parses against the currency plural patterns using complex affix comp arison, // parses against the currency plural patterns using complex affix comp arison,
// and parses against the current pattern using simple affix comparison . // and parses against the current pattern using simple affix comparison .
skipping to change at line 2075 skipping to change at line 2022
UBool* status, UBool* status,
UChar* currency) const; UChar* currency) const;
int32_t skipPadding(const UnicodeString& text, int32_t position) const; int32_t skipPadding(const UnicodeString& text, int32_t position) const;
int32_t compareAffix(const UnicodeString& input, int32_t compareAffix(const UnicodeString& input,
int32_t pos, int32_t pos,
UBool isNegative, UBool isNegative,
UBool isPrefix, UBool isPrefix,
const UnicodeString* affixPat, const UnicodeString* affixPat,
UBool currencyParsing, UBool complexCurrencyParsing,
int8_t type, int8_t type,
UChar* currency) const; UChar* currency) const;
static int32_t compareSimpleAffix(const UnicodeString& affix, static UnicodeString& trimMarksFromAffix(const UnicodeString& affix, Un
icodeString& trimmedAffix);
UBool equalWithSignCompatibility(UChar32 lhs, UChar32 rhs) const;
int32_t compareSimpleAffix(const UnicodeString& affix,
const UnicodeString& input, const UnicodeString& input,
int32_t pos, int32_t pos,
UBool lenient); UBool lenient) const;
static int32_t skipPatternWhiteSpace(const UnicodeString& text, int32_t pos); static int32_t skipPatternWhiteSpace(const UnicodeString& text, int32_t pos);
static int32_t skipUWhiteSpace(const UnicodeString& text, int32_t pos); static int32_t skipUWhiteSpace(const UnicodeString& text, int32_t pos);
static int32_t skipUWhiteSpaceAndMarks(const UnicodeString& text, int32
_t pos);
static int32_t skipBidiMarks(const UnicodeString& text, int32_t pos);
int32_t compareComplexAffix(const UnicodeString& affixPat, int32_t compareComplexAffix(const UnicodeString& affixPat,
const UnicodeString& input, const UnicodeString& input,
int32_t pos, int32_t pos,
int8_t type, int8_t type,
UChar* currency) const; UChar* currency) const;
static int32_t match(const UnicodeString& text, int32_t pos, UChar32 ch ); static int32_t match(const UnicodeString& text, int32_t pos, UChar32 ch );
static int32_t match(const UnicodeString& text, int32_t pos, const Unic odeString& str); static int32_t match(const UnicodeString& text, int32_t pos, const Unic odeString& str);
skipping to change at line 2368 skipping to change at line 2323
Hashtable* fAffixesForCurrency; // for current pattern Hashtable* fAffixesForCurrency; // for current pattern
Hashtable* fPluralAffixesForCurrency; // for plural pattern Hashtable* fPluralAffixesForCurrency; // for plural pattern
// Information needed for DecimalFormat to format/parse currency plural . // Information needed for DecimalFormat to format/parse currency plural .
CurrencyPluralInfo* fCurrencyPluralInfo; CurrencyPluralInfo* fCurrencyPluralInfo;
#if UCONFIG_HAVE_PARSEALLINPUT #if UCONFIG_HAVE_PARSEALLINPUT
UNumberFormatAttributeValue fParseAllInput; UNumberFormatAttributeValue fParseAllInput;
#endif #endif
// Decimal Format Static Sets singleton.
const DecimalFormatStaticSets *fStaticSets;
protected: protected:
#ifndef U_HIDE_INTERNAL_API #ifndef U_HIDE_INTERNAL_API
/** /**
* Rounds a value according to the rules of this object. * Rounds a value according to the rules of this object.
* @internal * @internal
*/ */
DigitList& _round(const DigitList& number, DigitList& adjustedNum, UBoo l& isNegative, UErrorCode& status) const; DigitList& _round(const DigitList& number, DigitList& adjustedNum, UBoo l& isNegative, UErrorCode& status) const;
#endif /* U_HIDE_INTERNAL_API */ #endif /* U_HIDE_INTERNAL_API */
skipping to change at line 2424 skipping to change at line 2382
*/ */
uint8_t fReserved[UNUM_DECIMALFORMAT_INTERNAL_SIZE]; uint8_t fReserved[UNUM_DECIMALFORMAT_INTERNAL_SIZE];
/** /**
* Called whenever any state changes. Recomputes whether fastpath is OK to use. * Called whenever any state changes. Recomputes whether fastpath is OK to use.
*/ */
void handleChanged(); void handleChanged();
#endif #endif
}; };
inline UnicodeString&
DecimalFormat::format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const {
// Don't use Format:: - use immediate base class only,
// in case immediate base modifies behavior later.
return NumberFormat::format(obj, appendTo, status);
}
inline UnicodeString&
DecimalFormat::format(double number,
UnicodeString& appendTo) const {
FieldPosition pos(0);
return format(number, appendTo, pos);
}
inline UnicodeString&
DecimalFormat::format(int32_t number,
UnicodeString& appendTo) const {
FieldPosition pos(0);
return format((int64_t)number, appendTo, pos);
}
inline const UnicodeString & inline const UnicodeString &
DecimalFormat::getConstSymbol(DecimalFormatSymbols::ENumberFormatSymbol sym bol) const { DecimalFormat::getConstSymbol(DecimalFormatSymbols::ENumberFormatSymbol sym bol) const {
return fSymbols->getConstSymbol(symbol); return fSymbols->getConstSymbol(symbol);
} }
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif // _DECIMFMT #endif // _DECIMFMT
 End of changes. 23 change blocks. 
126 lines changed or deleted 64 lines changed or added


 dtfmtsym.h   dtfmtsym.h 
skipping to change at line 507 skipping to change at line 507
*/ */
void setLocalPatternChars(const UnicodeString& newLocalPatternChars); void setLocalPatternChars(const UnicodeString& newLocalPatternChars);
/** /**
* 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.
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
Locale getLocale(ULocDataLocaleType type, UErrorCode& status) const; Locale getLocale(ULocDataLocaleType type, UErrorCode& status) const;
#ifndef U_HIDE_INTERNAL_API
/** /**
* Constants for capitalization context usage types. * Constants for capitalization context usage types.
* @internal * @internal
*/ */
enum ECapitalizationContextUsageType enum ECapitalizationContextUsageType
{ {
kCapContextUsageOther, kCapContextUsageOther,
kCapContextUsageMonthFormat, /* except narrow */ kCapContextUsageMonthFormat, /* except narrow */
kCapContextUsageMonthStandalone, /* except narrow */ kCapContextUsageMonthStandalone, /* except narrow */
kCapContextUsageMonthNarrow, kCapContextUsageMonthNarrow,
skipping to change at line 530 skipping to change at line 529
kCapContextUsageDayNarrow, kCapContextUsageDayNarrow,
kCapContextUsageEraWide, kCapContextUsageEraWide,
kCapContextUsageEraAbbrev, kCapContextUsageEraAbbrev,
kCapContextUsageEraNarrow, kCapContextUsageEraNarrow,
kCapContextUsageZoneLong, kCapContextUsageZoneLong,
kCapContextUsageZoneShort, kCapContextUsageZoneShort,
kCapContextUsageMetazoneLong, kCapContextUsageMetazoneLong,
kCapContextUsageMetazoneShort, kCapContextUsageMetazoneShort,
kCapContextUsageTypeCount kCapContextUsageTypeCount
}; };
#endif /* U_HIDE_INTERNAL_API */
/** /**
* ICU "poor man's RTTI", returns a UClassID for the actual class. * ICU "poor man's RTTI", returns a UClassID for the actual class.
* *
* @stable ICU 2.2 * @stable ICU 2.2
*/ */
virtual UClassID getDynamicClassID() const; virtual UClassID getDynamicClassID() const;
/** /**
* ICU "poor man's RTTI", returns a UClassID for this class. * ICU "poor man's RTTI", returns a UClassID for this class.
 End of changes. 2 change blocks. 
2 lines changed or deleted 0 lines changed or added


 dtitvfmt.h   dtitvfmt.h 
/************************************************************************** ****** /************************************************************************** ******
* Copyright (C) 2008-2012, International Business Machines Corporation and * Copyright (C) 2008-2013, International Business Machines Corporation and
* others. All Rights Reserved. * others. All Rights Reserved.
*************************************************************************** **** *************************************************************************** ****
* *
* File DTITVFMT.H * File DTITVFMT.H
* *
*************************************************************************** **** *************************************************************************** ****
*/ */
#ifndef __DTITVFMT_H__ #ifndef __DTITVFMT_H__
#define __DTITVFMT_H__ #define __DTITVFMT_H__
skipping to change at line 262 skipping to change at line 262
* which is "yMMMEEEd", * which is "yMMMEEEd",
* the interval patterns defined in resource file to above skeleton are : * the interval patterns defined in resource file to above skeleton are :
* "EEE, d MMM, yyyy - EEE, d MMM, yyyy" for year differs, * "EEE, d MMM, yyyy - EEE, d MMM, yyyy" for year differs,
* "EEE, d MMM - EEE, d MMM, yyyy" for month differs, * "EEE, d MMM - EEE, d MMM, yyyy" for month differs,
* "EEE, d - EEE, d MMM, yyyy" for day differs, * "EEE, d - EEE, d MMM, yyyy" for day differs,
* @param skeleton the skeleton on which the interval format is based. * @param skeleton the skeleton on which the interval format is based.
* @param locale the given locale * @param locale the given locale
* @param status output param set to success/failure code on exit * @param status output param set to success/failure code on exit
* @return a date time interval formatter which the caller own s. * @return a date time interval formatter which the caller own s.
* @stable ICU 4.0 * @stable ICU 4.0
* <p>
* <h4>Sample code</h4>
* \snippet samples/dtitvfmtsample/dtitvfmtsample.cpp dtitvfmtPreDef
ined1
* \snippet samples/dtitvfmtsample/dtitvfmtsample.cpp dtitvfmtPreDef
ined
* <p>
*/ */
static DateIntervalFormat* U_EXPORT2 createInstance( static DateIntervalFormat* U_EXPORT2 createInstance(
const UnicodeString& skeleto n, const UnicodeString& skeleto n,
const Locale& locale, const Locale& locale,
UErrorCode& status); UErrorCode& status);
/** /**
* Construct a DateIntervalFormat from skeleton * Construct a DateIntervalFormat from skeleton
* DateIntervalInfo, and default locale. * DateIntervalInfo, and default locale.
skipping to change at line 323 skipping to change at line 328
* the default interval pattern. * the default interval pattern.
* If user does not provide default interval pattern, it fallback to * If user does not provide default interval pattern, it fallback to
* "{date0} - {date1}" * "{date0} - {date1}"
* *
* @param skeleton the skeleton on which interval format based. * @param skeleton the skeleton on which interval format based.
* @param locale the given locale * @param locale the given locale
* @param dtitvinf the DateIntervalInfo object. * @param dtitvinf the DateIntervalInfo object.
* @param status output param set to success/failure code on exit * @param status output param set to success/failure code on exit
* @return a date time interval formatter which the caller own s. * @return a date time interval formatter which the caller own s.
* @stable ICU 4.0 * @stable ICU 4.0
* <p>
* <h4>Sample code</h4>
* \snippet samples/dtitvfmtsample/dtitvfmtsample.cpp dtitvfmtPreDef
ined1
* \snippet samples/dtitvfmtsample/dtitvfmtsample.cpp dtitvfmtCustom
ized
* <p>
*/ */
static DateIntervalFormat* U_EXPORT2 createInstance( static DateIntervalFormat* U_EXPORT2 createInstance(
const UnicodeString& skeleton , const UnicodeString& skeleton ,
const Locale& locale, const Locale& locale,
const DateIntervalInfo& dtitv inf, const DateIntervalInfo& dtitv inf,
UErrorCode& status); UErrorCode& status);
/** /**
* Destructor. * Destructor.
* @stable ICU 4.0 * @stable ICU 4.0
skipping to change at line 558 skipping to change at line 568
* Save the interval pattern information. * Save the interval pattern information.
* Interval pattern consists of 2 single date patterns and the separato r. * Interval pattern consists of 2 single date patterns and the separato r.
* For example, interval pattern "MMM d - MMM d, yyyy" consists * For example, interval pattern "MMM d - MMM d, yyyy" consists
* a single date pattern "MMM d", another single date pattern "MMM d, y yyy", * a single date pattern "MMM d", another single date pattern "MMM d, y yyy",
* and a separator "-". * and a separator "-".
* The pattern is divided into 2 parts. For above example, * The pattern is divided into 2 parts. For above example,
* the first part is "MMM d - ", and the second part is "MMM d, yyyy". * the first part is "MMM d - ", and the second part is "MMM d, yyyy".
* Also, the first date appears in an interval pattern could be * Also, the first date appears in an interval pattern could be
* the earlier date or the later date. * the earlier date or the later date.
* And such information is saved in the interval pattern as well. * And such information is saved in the interval pattern as well.
* @internal ICU 4.0
*/ */
struct PatternInfo { struct PatternInfo {
UnicodeString firstPart; UnicodeString firstPart;
UnicodeString secondPart; UnicodeString secondPart;
/** /**
* Whether the first date in interval pattern is later date or not. * Whether the first date in interval pattern is later date or not.
* Fallback format set the default ordering. * Fallback format set the default ordering.
* And for a particular interval pattern, the order can be * And for a particular interval pattern, the order can be
* overriden by prefixing the interval pattern with "latestFirst:" or * overriden by prefixing the interval pattern with "latestFirst:" or
* "earliestFirst:" * "earliestFirst:"
skipping to change at line 602 skipping to change at line 611
* the DateIntervalInfo provides the interval patterns. * the DateIntervalInfo provides the interval patterns.
* *
* Note: the DateIntervalFormat takes ownership of both * Note: the DateIntervalFormat takes ownership of both
* DateFormat and DateIntervalInfo objects. * DateFormat and DateIntervalInfo objects.
* Caller should not delete them. * Caller should not delete them.
* *
* @param locale the locale of this date interval formatter. * @param locale the locale of this date interval formatter.
* @param dtItvInfo the DateIntervalInfo object to be adopted. * @param dtItvInfo the DateIntervalInfo object to be adopted.
* @param skeleton the skeleton of the date formatter * @param skeleton the skeleton of the date formatter
* @param status output param set to success/failure code on exit * @param status output param set to success/failure code on exit
* @internal ICU 4.0
*/ */
DateIntervalFormat(const Locale& locale, DateIntervalInfo* dtItvInfo, DateIntervalFormat(const Locale& locale, DateIntervalInfo* dtItvInfo,
const UnicodeString* skeleton, UErrorCode& status); const UnicodeString* skeleton, UErrorCode& status);
/** /**
* Construct a DateIntervalFormat from DateFormat * Construct a DateIntervalFormat from DateFormat
* and a DateIntervalInfo. * and a DateIntervalInfo.
* *
* It is a wrapper of the constructor. * It is a wrapper of the constructor.
* *
* @param locale the locale of this date interval formatter. * @param locale the locale of this date interval formatter.
* @param dtitvinf the DateIntervalInfo object to be adopted. * @param dtitvinf the DateIntervalInfo object to be adopted.
* @param skeleton the skeleton of this formatter. * @param skeleton the skeleton of this formatter.
* @param status Output param set to success/failure code. * @param status Output param set to success/failure code.
* @return a date time interval formatter which the caller own s. * @return a date time interval formatter which the caller own s.
* @internal ICU 4.0
*/ */
static DateIntervalFormat* U_EXPORT2 create(const Locale& locale, static DateIntervalFormat* U_EXPORT2 create(const Locale& locale,
DateIntervalInfo* dtitvinf, DateIntervalInfo* dtitvinf,
const UnicodeString* skelet on, const UnicodeString* skelet on,
UErrorCode& status); UErrorCode& status);
/** /**
* Create a simple date/time formatter from skeleton, given locale, * Create a simple date/time formatter from skeleton, given locale,
* and date time pattern generator. * and date time pattern generator.
* *
* @param skeleton the skeleton on which date format based. * @param skeleton the skeleton on which date format based.
* @param locale the given locale. * @param locale the given locale.
* @param dtpng the date time pattern generator. * @param dtpng the date time pattern generator.
* @param status Output param to be set to success/failure code. * @param status Output param to be set to success/failure code.
* If it is failure, the returned date formatter will * If it is failure, the returned date formatter will
* be NULL. * be NULL.
* @return a simple date formatter which the caller owns. * @return a simple date formatter which the caller owns.
* @internal ICU 4.0
*/ */
static SimpleDateFormat* U_EXPORT2 createSDFPatternInstance( static SimpleDateFormat* U_EXPORT2 createSDFPatternInstance(
const UnicodeString& skeleton, const UnicodeString& skeleton,
const Locale& locale, const Locale& locale,
DateTimePatternGenerator* dtpng, DateTimePatternGenerator* dtpng,
UErrorCode& status); UErrorCode& status);
/** /**
* Below are for generating interval patterns local to the formatter * Below are for generating interval patterns local to the formatter
*/ */
skipping to change at line 664 skipping to change at line 670
* @param fromCalendar calendar set to the from date in date inter val * @param fromCalendar calendar set to the from date in date inter val
* to be formatted into date interval string * to be formatted into date interval string
* @param toCalendar calendar set to the to date in date interva l * @param toCalendar calendar set to the to date in date interva l
* to be formatted into date interval string * to be formatted into date interval string
* @param appendTo Output parameter to receive result. * @param appendTo Output parameter to receive result.
* Result is appended to existing contents. * Result is appended to existing contents.
* @param pos On input: an alignment field, if desired. * @param pos On input: an alignment field, if desired.
* On output: the offsets of the alignment fie ld. * On output: the offsets of the alignment fie ld.
* @param status output param set to success/failure code on exit * @param status output param set to success/failure code on exit
* @return Reference to 'appendTo' parameter. * @return Reference to 'appendTo' parameter.
* @internal ICU 4.0
*/ */
UnicodeString& fallbackFormat(Calendar& fromCalendar, UnicodeString& fallbackFormat(Calendar& fromCalendar,
Calendar& toCalendar, Calendar& toCalendar,
UnicodeString& appendTo, UnicodeString& appendTo,
FieldPosition& pos, FieldPosition& pos,
UErrorCode& status) const; UErrorCode& status) const;
/** /**
* Initialize interval patterns locale to this formatter * Initialize interval patterns locale to this formatter
* *
skipping to change at line 705 skipping to change at line 710
* "Jan 10, 2007 10:10 am - 11:10am" * "Jan 10, 2007 10:10 am - 11:10am"
* *
* 2. even a pattern does not request a certain calendar field, * 2. even a pattern does not request a certain calendar field,
* the interval pattern needs to include such field if such fields a re * the interval pattern needs to include such field if such fields a re
* different between 2 dates. * different between 2 dates.
* For example, a pattern/skeleton is "hm", but the interval pattern * For example, a pattern/skeleton is "hm", but the interval pattern
* includes year, month, and date when year, month, and date differs . * includes year, month, and date when year, month, and date differs .
* *
* *
* @param status output param set to success/failure code on exit * @param status output param set to success/failure code on exit
* @internal ICU 4.0
*/ */
void initializePattern(UErrorCode& status); void initializePattern(UErrorCode& status);
/** /**
* Set fall back interval pattern given a calendar field, * Set fall back interval pattern given a calendar field,
* a skeleton, and a date time pattern generator. * a skeleton, and a date time pattern generator.
* @param field the largest different calendar field * @param field the largest different calendar field
* @param skeleton a skeleton * @param skeleton a skeleton
* @param status output param set to success/failure code on exit * @param status output param set to success/failure code on exit
* @internal ICU 4.0
*/ */
void setFallbackPattern(UCalendarDateFields field, void setFallbackPattern(UCalendarDateFields field,
const UnicodeString& skeleton, const UnicodeString& skeleton,
UErrorCode& status); UErrorCode& status);
/** /**
* get separated date and time skeleton from a combined skeleton. * get separated date and time skeleton from a combined skeleton.
* *
* The difference between date skeleton and normalizedDateSkeleton are: * The difference between date skeleton and normalizedDateSkeleton are:
* 1. both 'y' and 'd' are appeared only once in normalizeDateSkeleton * 1. both 'y' and 'd' are appeared only once in normalizeDateSkeleton
skipping to change at line 744 skipping to change at line 747
* *
* *
* @param skeleton given combined skeleton. * @param skeleton given combined skeleton.
* @param date Output parameter for date only skelet on. * @param date Output parameter for date only skelet on.
* @param normalizedDate Output parameter for normalized date only * @param normalizedDate Output parameter for normalized date only
* *
* @param time Output parameter for time only skelet on. * @param time Output parameter for time only skelet on.
* @param normalizedTime Output parameter for normalized time only * @param normalizedTime Output parameter for normalized time only
* skeleton. * skeleton.
* *
* @internal ICU 4.0
*/ */
static void U_EXPORT2 getDateTimeSkeleton(const UnicodeString& skeleto n, static void U_EXPORT2 getDateTimeSkeleton(const UnicodeString& skeleto n,
UnicodeString& date, UnicodeString& date,
UnicodeString& normalizedDate, UnicodeString& normalizedDate,
UnicodeString& time, UnicodeString& time,
UnicodeString& normalizedTime); UnicodeString& normalizedTime);
/** /**
* Generate date or time interval pattern from resource, * Generate date or time interval pattern from resource,
* and set them into the interval pattern locale to this formatter. * and set them into the interval pattern locale to this formatter.
skipping to change at line 774 skipping to change at line 776
* *
* 2. there might be no pattern for 'y' differ for skeleton "Md", * 2. there might be no pattern for 'y' differ for skeleton "Md",
* in order to get interval patterns for 'y' differ, * in order to get interval patterns for 'y' differ,
* need to look for it from skeleton 'yMd' * need to look for it from skeleton 'yMd'
* *
* @param dateSkeleton normalized date skeleton * @param dateSkeleton normalized date skeleton
* @param timeSkeleton normalized time skeleton * @param timeSkeleton normalized time skeleton
* @return whether the resource is found for the skeleton . * @return whether the resource is found for the skeleton .
* TRUE if interval pattern found for the skeleto n, * TRUE if interval pattern found for the skeleto n,
* FALSE otherwise. * FALSE otherwise.
* @internal ICU 4.0
*/ */
UBool setSeparateDateTimePtn(const UnicodeString& dateSkeleton, UBool setSeparateDateTimePtn(const UnicodeString& dateSkeleton,
const UnicodeString& timeSkeleton); const UnicodeString& timeSkeleton);
/** /**
* Generate interval pattern from existing resource * Generate interval pattern from existing resource
* *
* It not only save the interval patterns, * It not only save the interval patterns,
* but also return the extended skeleton and its best match skeleton. * but also return the extended skeleton and its best match skeleton.
* *
skipping to change at line 801 skipping to change at line 802
* 1 means the fields are the same, but field width are differe nt * 1 means the fields are the same, but field width are differe nt
* 2 means the only difference between fields are v/z, * 2 means the only difference between fields are v/z,
* -1 means there are other fields difference * -1 means there are other fields difference
* *
* @param extendedSkeleton extended skeleton * @param extendedSkeleton extended skeleton
* @param extendedBestSkeleton extended best match skeleton * @param extendedBestSkeleton extended best match skeleton
* @return whether the interval pattern is found * @return whether the interval pattern is found
* through extending skeleton or not. * through extending skeleton or not.
* TRUE if interval pattern is found by * TRUE if interval pattern is found by
* extending skeleton, FALSE otherwise. * extending skeleton, FALSE otherwise.
* @internal ICU 4.0
*/ */
UBool setIntervalPattern(UCalendarDateFields field, UBool setIntervalPattern(UCalendarDateFields field,
const UnicodeString* skeleton, const UnicodeString* skeleton,
const UnicodeString* bestSkeleton, const UnicodeString* bestSkeleton,
int8_t differenceInfo, int8_t differenceInfo,
UnicodeString* extendedSkeleton = NULL, UnicodeString* extendedSkeleton = NULL,
UnicodeString* extendedBestSkeleton = NULL); UnicodeString* extendedBestSkeleton = NULL);
/** /**
* Adjust field width in best match interval pattern to match * Adjust field width in best match interval pattern to match
skipping to change at line 837 skipping to change at line 837
* till this stage, the adjust here is only "adjust strings, such as MM M * till this stage, the adjust here is only "adjust strings, such as MM M
* and MMMM, EEE and EEEE. * and MMMM, EEE and EEEE.
* *
* @param inputSkeleton the input skeleton * @param inputSkeleton the input skeleton
* @param bestMatchSkeleton the best match skeleton * @param bestMatchSkeleton the best match skeleton
* @param bestMatchIntervalPattern the best match interval pattern * @param bestMatchIntervalPattern the best match interval pattern
* @param differenceInfo the difference between 2 skeletons * @param differenceInfo the difference between 2 skeletons
* 1 means only field width differs * 1 means only field width differs
* 2 means v/z exchange * 2 means v/z exchange
* @param adjustedIntervalPattern adjusted interval pattern * @param adjustedIntervalPattern adjusted interval pattern
* @internal ICU 4.0
*/ */
static void U_EXPORT2 adjustFieldWidth( static void U_EXPORT2 adjustFieldWidth(
const UnicodeString& inputSkeleton, const UnicodeString& inputSkeleton,
const UnicodeString& bestMatchSkeleton, const UnicodeString& bestMatchSkeleton,
const UnicodeString& bestMatchIntervalPattern, const UnicodeString& bestMatchIntervalPattern,
int8_t differenceInfo, int8_t differenceInfo,
UnicodeString& adjustedIntervalPattern); UnicodeString& adjustedIntervalPattern);
/** /**
* Concat a single date pattern with a time interval pattern, * Concat a single date pattern with a time interval pattern,
* set it into the intervalPatterns, while field is time field. * set it into the intervalPatterns, while field is time field.
* This is used to handle time interval patterns on skeleton with * This is used to handle time interval patterns on skeleton with
* both time and date. Present the date followed by * both time and date. Present the date followed by
* the range expression for the time. * the range expression for the time.
* @param format date and time format * @param format date and time format
* @param formatLen format string length * @param formatLen format string length
* @param datePattern date pattern * @param datePattern date pattern
* @param field time calendar field: AM_PM, HOUR, MINUTE * @param field time calendar field: AM_PM, HOUR, MINUTE
* @param status output param set to success/failure code on ex it * @param status output param set to success/failure code on ex it
* @internal ICU 4.0
*/ */
void concatSingleDate2TimeInterval(const UChar* format, void concatSingleDate2TimeInterval(const UChar* format,
int32_t formatLen, int32_t formatLen,
const UnicodeString& datePattern, const UnicodeString& datePattern,
UCalendarDateFields field, UCalendarDateFields field,
UErrorCode& status); UErrorCode& status);
/** /**
* check whether a calendar field present in a skeleton. * check whether a calendar field present in a skeleton.
* @param field calendar field need to check * @param field calendar field need to check
* @param skeleton given skeleton on which to check the calendar fiel d * @param skeleton given skeleton on which to check the calendar fiel d
* @return true if field present in a skeleton. * @return true if field present in a skeleton.
* @internal ICU 4.0
*/ */
static UBool U_EXPORT2 fieldExistsInSkeleton(UCalendarDateFields field, static UBool U_EXPORT2 fieldExistsInSkeleton(UCalendarDateFields field,
const UnicodeString& skele ton); const UnicodeString& skele ton);
/** /**
* Split interval patterns into 2 part. * Split interval patterns into 2 part.
* @param intervalPattern interval pattern * @param intervalPattern interval pattern
* @return the index in interval pattern which split the pattern into 2 part * @return the index in interval pattern which split the pattern into 2 part
* @internal ICU 4.0
*/ */
static int32_t U_EXPORT2 splitPatternInto2Part(const UnicodeString& in tervalPattern); static int32_t U_EXPORT2 splitPatternInto2Part(const UnicodeString& in tervalPattern);
/** /**
* Break interval patterns as 2 part and save them into pattern info. * Break interval patterns as 2 part and save them into pattern info.
* @param field calendar field * @param field calendar field
* @param intervalPattern interval pattern * @param intervalPattern interval pattern
* @internal ICU 4.0
*/ */
void setIntervalPattern(UCalendarDateFields field, void setIntervalPattern(UCalendarDateFields field,
const UnicodeString& intervalPattern); const UnicodeString& intervalPattern);
/** /**
* Break interval patterns as 2 part and save them into pattern info. * Break interval patterns as 2 part and save them into pattern info.
* @param field calendar field * @param field calendar field
* @param intervalPattern interval pattern * @param intervalPattern interval pattern
* @param laterDateFirst whether later date appear first in interval pattern * @param laterDateFirst whether later date appear first in interval pattern
* @internal ICU 4.0
*/ */
void setIntervalPattern(UCalendarDateFields field, void setIntervalPattern(UCalendarDateFields field,
const UnicodeString& intervalPattern, const UnicodeString& intervalPattern,
UBool laterDateFirst); UBool laterDateFirst);
/** /**
* Set pattern information. * Set pattern information.
* *
* @param field calendar field * @param field calendar field
* @param firstPart the first part in interval pattern * @param firstPart the first part in interval pattern
* @param secondPart the second part in interval pattern * @param secondPart the second part in interval pattern
* @param laterDateFirst whether the first date in intervalPattern * @param laterDateFirst whether the first date in intervalPattern
* is earlier date or later date * is earlier date or later date
* @internal ICU 4.0
*/ */
void setPatternInfo(UCalendarDateFields field, void setPatternInfo(UCalendarDateFields field,
const UnicodeString* firstPart, const UnicodeString* firstPart,
const UnicodeString* secondPart, const UnicodeString* secondPart,
UBool laterDateFirst); UBool laterDateFirst);
// from calendar field to pattern letter // from calendar field to pattern letter
static const UChar fgCalendarFieldToPatternLetter[]; static const UChar fgCalendarFieldToPatternLetter[];
/** /**
 End of changes. 20 change blocks. 
18 lines changed or deleted 15 lines changed or added


 dtitvinf.h   dtitvinf.h 
/* /*
************************************************************************** ***** ************************************************************************** *****
* Copyright (C) 2008-2011, International Business Machines Corporation and * Copyright (C) 2008-2011,2013, International Business Machines Corporatio n and
* others. All Rights Reserved. * others. All Rights Reserved.
************************************************************************** ***** ************************************************************************** *****
* *
* File DTITVINF.H * File DTITVINF.H
* *
************************************************************************** ***** ************************************************************************** *****
*/ */
#ifndef __DTITVINF_H__ #ifndef __DTITVINF_H__
#define __DTITVINF_H__ #define __DTITVINF_H__
skipping to change at line 365 skipping to change at line 365
enum { enum {
kMaxIntervalPatternIndex = kIPI_MAX_INDEX kMaxIntervalPatternIndex = kIPI_MAX_INDEX
}; };
#endif /* U_HIDE_INTERNAL_API */ #endif /* U_HIDE_INTERNAL_API */
private: private:
/** /**
* Initialize the DateIntervalInfo from locale * Initialize the DateIntervalInfo from locale
* @param locale the given locale. * @param locale the given locale.
* @param status output param set to success/failure code on exit * @param status output param set to success/failure code on exit
* @internal ICU 4.0
*/ */
void initializeData(const Locale& locale, UErrorCode& status); void initializeData(const Locale& locale, UErrorCode& status);
/* Set Interval pattern. /* Set Interval pattern.
* *
* It sets interval pattern into the hash map. * It sets interval pattern into the hash map.
* *
* @param skeleton skeleton on which the interval pattern based * @param skeleton skeleton on which the interval pattern based
* @param lrgDiffCalUnit the largest different calendar unit. * @param lrgDiffCalUnit the largest different calendar unit.
* @param intervalPattern the interval pattern on the largest differen t * @param intervalPattern the interval pattern on the largest differen t
* calendar unit. * calendar unit.
* @param status output param set to success/failure code on exit * @param status output param set to success/failure code on exit
* @internal ICU 4.0
*/ */
void setIntervalPatternInternally(const UnicodeString& skeleton, void setIntervalPatternInternally(const UnicodeString& skeleton,
UCalendarDateFields lrgDiffCalUnit, UCalendarDateFields lrgDiffCalUnit,
const UnicodeString& intervalPattern, const UnicodeString& intervalPattern,
UErrorCode& status); UErrorCode& status);
/**given an input skeleton, get the best match skeleton /**given an input skeleton, get the best match skeleton
* which has pre-defined interval pattern in resource file. * which has pre-defined interval pattern in resource file.
* Also return the difference between the input skeleton * Also return the difference between the input skeleton
* and the best match skeleton. * and the best match skeleton.
skipping to change at line 402 skipping to change at line 400
* @param skeleton input skeleton * @param skeleton input skeleton
* @param bestMatchDistanceInfo the difference between input skeleton * @param bestMatchDistanceInfo the difference between input skeleton
* and best match skeleton. * and best match skeleton.
* 0, if there is exact match for input skeleton * 0, if there is exact match for input skeleton
* 1, if there is only field width difference between * 1, if there is only field width difference between
* the best match and the input skeleton * the best match and the input skeleton
* 2, the only field difference is 'v' and 'z' * 2, the only field difference is 'v' and 'z'
* -1, if there is calendar field difference between * -1, if there is calendar field difference between
* the best match and the input skeleton * the best match and the input skeleton
* @return best match skeleton * @return best match skeleton
* @internal ICU 4.0
*/ */
const UnicodeString* getBestSkeleton(const UnicodeString& skeleton, const UnicodeString* getBestSkeleton(const UnicodeString& skeleton,
int8_t& bestMatchDistanceInfo) con st; int8_t& bestMatchDistanceInfo) con st;
/** /**
* Parse skeleton, save each field's width. * Parse skeleton, save each field's width.
* It is used for looking for best match skeleton, * It is used for looking for best match skeleton,
* and adjust pattern field width. * and adjust pattern field width.
* @param skeleton skeleton to be parsed * @param skeleton skeleton to be parsed
* @param skeletonFieldWidth parsed skeleton field width * @param skeletonFieldWidth parsed skeleton field width
* @internal ICU 4.0
*/ */
static void U_EXPORT2 parseSkeleton(const UnicodeString& skeleton, static void U_EXPORT2 parseSkeleton(const UnicodeString& skeleton,
int32_t* skeletonFieldWidth); int32_t* skeletonFieldWidth);
/** /**
* Check whether one field width is numeric while the other is string. * Check whether one field width is numeric while the other is string.
* *
* TODO (xji): make it general * TODO (xji): make it general
* *
* @param fieldWidth one field width * @param fieldWidth one field width
* @param anotherFieldWidth another field width * @param anotherFieldWidth another field width
* @param patternLetter pattern letter char * @param patternLetter pattern letter char
* @return true if one field width is numeric and the other is string, * @return true if one field width is numeric and the other is string,
* false otherwise. * false otherwise.
* @internal ICU 4.0
*/ */
static UBool U_EXPORT2 stringNumeric(int32_t fieldWidth, static UBool U_EXPORT2 stringNumeric(int32_t fieldWidth,
int32_t anotherFieldWidth, int32_t anotherFieldWidth,
char patternLetter); char patternLetter);
/** /**
* Convert calendar field to the interval pattern index in * Convert calendar field to the interval pattern index in
* hash table. * hash table.
* *
* Since we only support the following calendar fields: * Since we only support the following calendar fields:
* ERA, YEAR, MONTH, DATE, DAY_OF_MONTH, DAY_OF_WEEK, * ERA, YEAR, MONTH, DATE, DAY_OF_MONTH, DAY_OF_WEEK,
* AM_PM, HOUR, HOUR_OF_DAY, and MINUTE, * AM_PM, HOUR, HOUR_OF_DAY, and MINUTE,
* We reserve only 4 interval patterns for a skeleton. * We reserve only 4 interval patterns for a skeleton.
* *
* @param field calendar field * @param field calendar field
* @param status output param set to success/failure code on exit * @param status output param set to success/failure code on exit
* @return interval pattern index in hash table * @return interval pattern index in hash table
* @internal ICU 4.0
*/ */
static IntervalPatternIndex U_EXPORT2 calendarFieldToIntervalIndex( static IntervalPatternIndex U_EXPORT2 calendarFieldToIntervalIndex(
UCalendarDateFields f ield, UCalendarDateFields f ield,
UErrorCode& status); UErrorCode& status);
/** /**
* delete hash table (of type fIntervalPatterns). * delete hash table (of type fIntervalPatterns).
* *
* @param hTable hash table to be deleted * @param hTable hash table to be deleted
* @internal ICU 4.0
*/ */
void deleteHash(Hashtable* hTable); void deleteHash(Hashtable* hTable);
/** /**
* initialize hash table (of type fIntervalPatterns). * initialize hash table (of type fIntervalPatterns).
* *
* @param status output param set to success/failure code on exit * @param status output param set to success/failure code on exit
* @return hash table initialized * @return hash table initialized
* @internal ICU 4.0
*/ */
Hashtable* initHash(UErrorCode& status); Hashtable* initHash(UErrorCode& status);
/** /**
* copy hash table (of type fIntervalPatterns). * copy hash table (of type fIntervalPatterns).
* *
* @param source the source to copy from * @param source the source to copy from
* @param target the target to copy to * @param target the target to copy to
* @param status output param set to success/failure code on exit * @param status output param set to success/failure code on exit
* @internal ICU 4.0
*/ */
void copyHash(const Hashtable* source, Hashtable* target, UErrorCode& s tatus); void copyHash(const Hashtable* source, Hashtable* target, UErrorCode& s tatus);
// data members // data members
// fallback interval pattern // fallback interval pattern
UnicodeString fFallbackIntervalPattern; UnicodeString fFallbackIntervalPattern;
// default order // default order
UBool fFirstDateInPtnIsLaterDate; UBool fFirstDateInPtnIsLaterDate;
// HashMap<UnicodeString, UnicodeString[kIPI_MAX_INDEX]> // HashMap<UnicodeString, UnicodeString[kIPI_MAX_INDEX]>
 End of changes. 10 change blocks. 
10 lines changed or deleted 1 lines changed or added


 dtptngen.h   dtptngen.h 
/* /*
*************************************************************************** **** *************************************************************************** ****
* Copyright (C) 2007-2011, International Business Machines Corporation and * Copyright (C) 2007-2013, International Business Machines Corporation and
* others. All Rights Reserved. * others. All Rights Reserved.
*************************************************************************** **** *************************************************************************** ****
* *
* File DTPTNGEN.H * File DTPTNGEN.H
* *
*************************************************************************** **** *************************************************************************** ****
*/ */
#ifndef __DTPTNGEN_H__ #ifndef __DTPTNGEN_H__
#define __DTPTNGEN_H__ #define __DTPTNGEN_H__
skipping to change at line 152 skipping to change at line 152
* *
* @param pattern Input pattern, such as "dd/MMM" * @param pattern Input pattern, such as "dd/MMM"
* @param override When existing values are to be overridden use true, * @param override When existing values are to be overridden use true,
* otherwise use false. * otherwise use false.
* @param conflictingPattern Previous pattern with the same skeleton. * @param conflictingPattern Previous pattern with the same skeleton.
* @param status Output param set to success/failure code on exit, * @param status Output param set to success/failure code on exit,
* which must not indicate a failure before the function call. * which must not indicate a failure before the function call.
* @return conflicting status. The value could be UDATPG_NO_CONFLICT, * @return conflicting status. The value could be UDATPG_NO_CONFLICT,
* UDATPG_BASE_CONFLICT or UDATPG_CONFLICT. * UDATPG_BASE_CONFLICT or UDATPG_CONFLICT.
* @stable ICU 3.8 * @stable ICU 3.8
* <p>
* <h4>Sample code</h4>
* \snippet samples/dtptngsample/dtptngsample.cpp getBestPatternExam
ple1
* \snippet samples/dtptngsample/dtptngsample.cpp addPatternExample
* <p>
*/ */
UDateTimePatternConflict addPattern(const UnicodeString& pattern, UDateTimePatternConflict addPattern(const UnicodeString& pattern,
UBool override, UBool override,
UnicodeString& conflictingPattern, UnicodeString& conflictingPattern,
UErrorCode& status); UErrorCode& status);
/** /**
* An AppendItem format is a pattern used to append a field if there is no * An AppendItem format is a pattern used to append a field if there is no
* good match. For example, suppose that the input skeleton is "GyyyyMM Md", * good match. For example, suppose that the input skeleton is "GyyyyMM Md",
* and there is no matching pattern internally, but there is a pattern * and there is no matching pattern internally, but there is a pattern
skipping to change at line 251 skipping to change at line 256
* have all of the fields in the skeleton. * have all of the fields in the skeleton.
* *
* @param skeleton * @param skeleton
* The skeleton is a pattern containing only the variable fi elds. * The skeleton is a pattern containing only the variable fi elds.
* For example, "MMMdd" and "mmhh" are skeletons. * For example, "MMMdd" and "mmhh" are skeletons.
* @param status Output param set to success/failure code on exit, * @param status Output param set to success/failure code on exit,
* which must not indicate a failure before the function call. * which must not indicate a failure before the function call.
* @return bestPattern * @return bestPattern
* The best pattern found from the given skeleton. * The best pattern found from the given skeleton.
* @stable ICU 3.8 * @stable ICU 3.8
* <p>
* <h4>Sample code</h4>
* \snippet samples/dtptngsample/dtptngsample.cpp getBestPatternExam
ple1
* \snippet samples/dtptngsample/dtptngsample.cpp getBestPatternExam
ple
* <p>
*/ */
UnicodeString getBestPattern(const UnicodeString& skeleton, UErrorCode & status); UnicodeString getBestPattern(const UnicodeString& skeleton, UErrorCode & status);
/** /**
* Return the best pattern matching the input skeleton. It is guarantee d to * Return the best pattern matching the input skeleton. It is guarantee d to
* have all of the fields in the skeleton. * have all of the fields in the skeleton.
* *
* @param skeleton * @param skeleton
* The skeleton is a pattern containing only the variable fi elds. * The skeleton is a pattern containing only the variable fi elds.
* For example, "MMMdd" and "mmhh" are skeletons. * For example, "MMMdd" and "mmhh" are skeletons.
skipping to change at line 292 skipping to change at line 302
* input skeleton, but can also be used externally. * input skeleton, but can also be used externally.
* *
* @param pattern Input pattern * @param pattern Input pattern
* @param skeleton * @param skeleton
* The skeleton is a pattern containing only the variable fi elds. * The skeleton is a pattern containing only the variable fi elds.
* For example, "MMMdd" and "mmhh" are skeletons. * For example, "MMMdd" and "mmhh" are skeletons.
* @param status Output param set to success/failure code on exit, * @param status Output param set to success/failure code on exit,
* which must not indicate a failure before the function call. * which must not indicate a failure before the function call.
* @return pattern adjusted to match the skeleton fields widths and sub types. * @return pattern adjusted to match the skeleton fields widths and sub types.
* @stable ICU 3.8 * @stable ICU 3.8
* <p>
* <h4>Sample code</h4>
* \snippet samples/dtptngsample/dtptngsample.cpp getBestPatternExam
ple1
* \snippet samples/dtptngsample/dtptngsample.cpp replaceFieldTypesE
xample
* <p>
*/ */
UnicodeString replaceFieldTypes(const UnicodeString& pattern, UnicodeString replaceFieldTypes(const UnicodeString& pattern,
const UnicodeString& skeleton, const UnicodeString& skeleton,
UErrorCode& status); UErrorCode& status);
/** /**
* Adjusts the field types (width and subtype) of a pattern to match wh at is * Adjusts the field types (width and subtype) of a pattern to match wh at is
* in a skeleton. That is, if you supply a pattern like "d-M H:m", and a * in a skeleton. That is, if you supply a pattern like "d-M H:m", and a
* skeleton of "MMMMddhhmm", then the input pattern is adjusted to be * skeleton of "MMMMddhhmm", then the input pattern is adjusted to be
* "dd-MMMM hh:mm". This is used internally to get the best match for t he * "dd-MMMM hh:mm". This is used internally to get the best match for t he
skipping to change at line 448 skipping to change at line 463
UnicodeString appendItemFormats[UDATPG_FIELD_COUNT]; UnicodeString appendItemFormats[UDATPG_FIELD_COUNT];
UnicodeString appendItemNames[UDATPG_FIELD_COUNT]; UnicodeString appendItemNames[UDATPG_FIELD_COUNT];
UnicodeString dateTimeFormat; UnicodeString dateTimeFormat;
UnicodeString decimal; UnicodeString decimal;
DateTimeMatcher *skipMatcher; DateTimeMatcher *skipMatcher;
Hashtable *fAvailableFormatKeyHash; Hashtable *fAvailableFormatKeyHash;
UnicodeString hackPattern; UnicodeString hackPattern;
UnicodeString emptyString; UnicodeString emptyString;
UChar fDefaultHourFormatChar; UChar fDefaultHourFormatChar;
/* internal flags masks for adjustFieldTypes etc. */
enum {
kDTPGNoFlags = 0,
kDTPGFixFractionalSeconds = 1,
kDTPGSkeletonUsesCapJ = 2
};
void initData(const Locale &locale, UErrorCode &status); void initData(const Locale &locale, UErrorCode &status);
void addCanonicalItems(); void addCanonicalItems();
void addICUPatterns(const Locale& locale, UErrorCode& status); void addICUPatterns(const Locale& locale, UErrorCode& status);
void hackTimes(const UnicodeString& hackPattern, UErrorCode& status); void hackTimes(const UnicodeString& hackPattern, UErrorCode& status);
void addCLDRData(const Locale& locale, UErrorCode& status); void addCLDRData(const Locale& locale, UErrorCode& status);
UDateTimePatternConflict addPatternWithSkeleton(const UnicodeString& pa ttern, const UnicodeString * skeletonToUse, UBool override, UnicodeString& conflictingPattern, UErrorCode& status); UDateTimePatternConflict addPatternWithSkeleton(const UnicodeString& pa ttern, const UnicodeString * skeletonToUse, UBool override, UnicodeString& conflictingPattern, UErrorCode& status);
void initHashtable(UErrorCode& status); void initHashtable(UErrorCode& status);
void setDateTimeFromCalendar(const Locale& locale, UErrorCode& status); void setDateTimeFromCalendar(const Locale& locale, UErrorCode& status);
void setDecimalSymbols(const Locale& locale, UErrorCode& status); void setDecimalSymbols(const Locale& locale, UErrorCode& status);
UDateTimePatternField getAppendFormatNumber(const char* field) const; UDateTimePatternField getAppendFormatNumber(const char* field) const;
UDateTimePatternField getAppendNameNumber(const char* field) const; UDateTimePatternField getAppendNameNumber(const char* field) const;
void getAppendName(UDateTimePatternField field, UnicodeString& value); void getAppendName(UDateTimePatternField field, UnicodeString& value);
int32_t getCanonicalIndex(const UnicodeString& field); int32_t getCanonicalIndex(const UnicodeString& field);
const UnicodeString* getBestRaw(DateTimeMatcher& source, int32_t includ eMask, DistanceInfo* missingFields, const PtnSkeleton** specifiedSkeletonPt r = 0); const UnicodeString* getBestRaw(DateTimeMatcher& source, int32_t includ eMask, DistanceInfo* missingFields, const PtnSkeleton** specifiedSkeletonPt r = 0);
UnicodeString adjustFieldTypes(const UnicodeString& pattern, const PtnS UnicodeString adjustFieldTypes(const UnicodeString& pattern, const PtnS
keleton* specifiedSkeleton, UBool fixFractionalSeconds, UDateTimePatternMat keleton* specifiedSkeleton, int32_t flags, UDateTimePatternMatchOptions opt
chOptions options = UDATPG_MATCH_NO_OPTIONS); ions = UDATPG_MATCH_NO_OPTIONS);
UnicodeString getBestAppending(int32_t missingFields, UDateTimePatternM UnicodeString getBestAppending(int32_t missingFields, int32_t flags, UD
atchOptions options = UDATPG_MATCH_NO_OPTIONS); ateTimePatternMatchOptions options = UDATPG_MATCH_NO_OPTIONS);
int32_t getTopBitNumber(int32_t foundMask); int32_t getTopBitNumber(int32_t foundMask);
void setAvailableFormat(const UnicodeString &key, UErrorCode& status); void setAvailableFormat(const UnicodeString &key, UErrorCode& status);
UBool isAvailableFormatSet(const UnicodeString &key) const; UBool isAvailableFormatSet(const UnicodeString &key) const;
void copyHashtable(Hashtable *other, UErrorCode &status); void copyHashtable(Hashtable *other, UErrorCode &status);
UBool isCanonicalItem(const UnicodeString& item) const; UBool isCanonicalItem(const UnicodeString& item) const;
} ;// end class DateTimePatternGenerator } ;// end class DateTimePatternGenerator
U_NAMESPACE_END U_NAMESPACE_END
#endif #endif
 End of changes. 6 change blocks. 
6 lines changed or deleted 33 lines changed or added


 fmtable.h   fmtable.h 
skipping to change at line 19 skipping to change at line 19
* Modification History: * Modification History:
* *
* Date Name Description * Date Name Description
* 02/29/97 aliu Creation. * 02/29/97 aliu Creation.
*************************************************************************** ***** *************************************************************************** *****
*/ */
#ifndef FMTABLE_H #ifndef FMTABLE_H
#define FMTABLE_H #define FMTABLE_H
#include "unicode/utypes.h" #include "unicode/utypes.h"
#include "unicode/unistr.h"
#include "unicode/stringpiece.h"
/** /**
* \file * \file
* \brief C++ API: Formattable is a thin wrapper for primitive numeric type s. * \brief C++ API: Formattable is a thin wrapper for primitive types used f or formatting and parsing
*/ */
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
#include "unicode/unistr.h"
#include "unicode/stringpiece.h"
#include "unicode/uformattable.h"
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
class CharString; class CharString;
class DigitList; class DigitList;
#ifndef U_HIDE_INTERNAL_API
/** /**
* \def UNUM_INTERNAL_STACKARRAY_SIZE * \def UNUM_INTERNAL_STACKARRAY_SIZE
* @internal * @internal
*/ */
#if U_PLATFORM == U_PF_OS400 #if U_PLATFORM == U_PF_OS400
#define UNUM_INTERNAL_STACKARRAY_SIZE 144 #define UNUM_INTERNAL_STACKARRAY_SIZE 144
#else #else
#define UNUM_INTERNAL_STACKARRAY_SIZE 128 #define UNUM_INTERNAL_STACKARRAY_SIZE 128
#endif #endif
#endif /* U_HIDE_INTERNAL_API */
/** /**
* Formattable objects can be passed to the Format class or * Formattable objects can be passed to the Format class or
* its subclasses for formatting. Formattable is a thin wrapper * its subclasses for formatting. Formattable is a thin wrapper
* class which interconverts between the primitive numeric types * class which interconverts between the primitive numeric types
* (double, long, etc.) as well as UDate and UnicodeString. * (double, long, etc.) as well as UDate and UnicodeString.
* *
* <p>Internally, a Formattable object is a union of primitive types. * <p>Internally, a Formattable object is a union of primitive types.
* As such, it can only store one flavor of data at a time. To * As such, it can only store one flavor of data at a time. To
* determine what flavor of data it contains, use the getType method. * determine what flavor of data it contains, use the getType method.
* *
* <p>As of ICU 3.0, Formattable may also wrap a UObject pointer, * <p>As of ICU 3.0, Formattable may also wrap a UObject pointer,
* which it owns. This allows an instance of any ICU class to be * which it owns. This allows an instance of any ICU class to be
* encapsulated in a Formattable. For legacy reasons and for * encapsulated in a Formattable. For legacy reasons and for
* efficiency, primitive numeric types are still stored directly * efficiency, primitive numeric types are still stored directly
* within a Formattable. * within a Formattable.
* *
* <p>The Formattable class is not suitable for subclassing. * <p>The Formattable class is not suitable for subclassing.
*
* <p>See UFormattable for a C wrapper.
*/ */
class U_I18N_API Formattable : public UObject { class U_I18N_API Formattable : public UObject {
public: public:
/** /**
* This enum is only used to let callers distinguish between * This enum is only used to let callers distinguish between
* the Formattable(UDate) constructor and the Formattable(double) * the Formattable(UDate) constructor and the Formattable(double)
* constructor; the compiler cannot distinguish the signatures, * constructor; the compiler cannot distinguish the signatures,
* since UDate is currently typedefed to be either double or long. * since UDate is currently typedefed to be either double or long.
* If UDate is changed later to be a bonafide class * If UDate is changed later to be a bonafide class
* or struct, then we no longer need this enum. * or struct, then we no longer need this enum.
skipping to change at line 126 skipping to change at line 128
* @param strToCopy the char string. * @param strToCopy the char string.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
Formattable(const char* strToCopy); Formattable(const char* strToCopy);
#endif #endif
/** /**
* Creates a Formattable object of an appropriate numeric type from a * Creates a Formattable object of an appropriate numeric type from a
* a decimal number in string form. The Formattable will retain the * a decimal number in string form. The Formattable will retain the
* full precision of the input in decimal format, even when it exceeds * full precision of the input in decimal format, even when it exceeds
* what can be represented by a double of int64_t. * what can be represented by a double or int64_t.
* *
* @param number the unformatted (not localized) string representation * @param number the unformatted (not localized) string representation
* of the Decimal number. * of the Decimal number.
* @param status the error code. Possible errors include U_INVALID_FO RMAT_ERROR * @param status the error code. Possible errors include U_INVALID_FO RMAT_ERROR
* if the format of the string does not conform to that of a * if the format of the string does not conform to that of a
* decimal number. * decimal number.
* @stable ICU 4.4 * @stable ICU 4.4
*/ */
Formattable(const StringPiece &number, UErrorCode &status); Formattable(const StringPiece &number, UErrorCode &status);
skipping to change at line 281 skipping to change at line 283
/** /**
* Gets the data type of this Formattable object. * Gets the data type of this Formattable object.
* @return the data type of this Formattable object. * @return the data type of this Formattable object.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
Type getType(void) const; Type getType(void) const;
/** /**
* Returns TRUE if the data type of this Formattable object * Returns TRUE if the data type of this Formattable object
* is kDouble, kLong, kInt64 or kDecimalNumber. * is kDouble, kLong, or kInt64
* @return TRUE if this is a pure numeric object * @return TRUE if this is a pure numeric object
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
UBool isNumeric() const; UBool isNumeric() const;
/** /**
* Gets the double value of this object. If this object is not of type * Gets the double value of this object. If this object is not of type
* kDouble then the result is undefined. * kDouble then the result is undefined.
* @return the double value of this object. * @return the double value of this object.
* @stable ICU 2.0 * @stable ICU 2.0
skipping to change at line 323 skipping to change at line 325
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
int32_t getLong(void) const { return (int32_t)fValue.fInt64; } int32_t getLong(void) const { return (int32_t)fValue.fInt64; }
/** /**
* Gets the long value of this object. If the magnitude is too * Gets the long value of this object. If the magnitude is too
* large to fit in a long, then the maximum or minimum long value, * large to fit in a long, then the maximum or minimum long value,
* as appropriate, is returned and the status is set to * as appropriate, is returned and the status is set to
* U_INVALID_FORMAT_ERROR. If this object is of type kInt64 and * U_INVALID_FORMAT_ERROR. If this object is of type kInt64 and
* it fits within a long, then no precision is lost. If it is of * it fits within a long, then no precision is lost. If it is of
* type kDouble or kDecimalNumber, then a conversion is peformed, with * type kDouble, then a conversion is peformed, with
* truncation of any fractional part. If the type is kObject and * truncation of any fractional part. If the type is kObject and
* the object is a Measure, then the result of * the object is a Measure, then the result of
* getNumber().getLong(status) is returned. If this object is * getNumber().getLong(status) is returned. If this object is
* neither a numeric type nor a Measure, then 0 is returned and * neither a numeric type nor a Measure, then 0 is returned and
* the status is set to U_INVALID_FORMAT_ERROR. * the status is set to U_INVALID_FORMAT_ERROR.
* @param status the error code * @param status the error code
* @return the long value of this object. * @return the long value of this object.
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
int32_t getLong(UErrorCode& status) const; int32_t getLong(UErrorCode& status) const;
skipping to change at line 599 skipping to change at line 601
*/ */
virtual UClassID getDynamicClassID() const; virtual UClassID getDynamicClassID() const;
/** /**
* ICU "poor man's RTTI", returns a UClassID for this class. * ICU "poor man's RTTI", returns a UClassID for this class.
* *
* @stable ICU 2.2 * @stable ICU 2.2
*/ */
static UClassID U_EXPORT2 getStaticClassID(); static UClassID U_EXPORT2 getStaticClassID();
#ifndef U_HIDE_DRAFT_API
/**
* Convert the UFormattable to a Formattable. Internally, this is a re
interpret_cast.
* @param fmt a valid UFormattable
* @return the UFormattable as a Formattable object pointer. This is a
n alias to the original
* UFormattable, and so is only valid while the original argument remai
ns in scope.
* @draft ICU 52
*/
static inline Formattable *fromUFormattable(UFormattable *fmt);
/**
* Convert the const UFormattable to a const Formattable. Internally,
this is a reinterpret_cast.
* @param fmt a valid UFormattable
* @return the UFormattable as a Formattable object pointer. This is a
n alias to the original
* UFormattable, and so is only valid while the original argument remai
ns in scope.
* @draft ICU 52
*/
static inline const Formattable *fromUFormattable(const UFormattable *f
mt);
/**
* Convert this object pointer to a UFormattable.
* @return this object as a UFormattable pointer. This is an alias to
this object,
* and so is only valid while this object remains in scope.
* @draft ICU 52
*/
inline UFormattable *toUFormattable();
/**
* Convert this object pointer to a UFormattable.
* @return this object as a UFormattable pointer. This is an alias to
this object,
* and so is only valid while this object remains in scope.
* @draft ICU 52
*/
inline const UFormattable *toUFormattable() const;
#endif /* U_HIDE_DRAFT_API */
#ifndef U_HIDE_DEPRECATED_API #ifndef U_HIDE_DEPRECATED_API
/** /**
* Deprecated variant of getLong(UErrorCode&). * Deprecated variant of getLong(UErrorCode&).
* @param status the error code * @param status the error code
* @return the long value of this object. * @return the long value of this object.
* @deprecated ICU 3.0 use getLong(UErrorCode&) instead * @deprecated ICU 3.0 use getLong(UErrorCode&) instead
*/ */
inline int32_t getLong(UErrorCode* status) const; inline int32_t getLong(UErrorCode* status) const;
#endif /* U_HIDE_DEPRECATED_API */ #endif /* U_HIDE_DEPRECATED_API */
skipping to change at line 632 skipping to change at line 670
*/ */
DigitList *getInternalDigitList(); DigitList *getInternalDigitList();
/** /**
* Adopt, and set value from, a DigitList * Adopt, and set value from, a DigitList
* Internal Function, do not use. * Internal Function, do not use.
* @param dl the Digit List to be adopted * @param dl the Digit List to be adopted
* @internal * @internal
*/ */
void adoptDigitList(DigitList *dl); void adoptDigitList(DigitList *dl);
/**
* Internal function to return the CharString pointer.
* @param status error code
* @return pointer to the CharString - may become invalid if the object
is modified
* @internal
*/
CharString *internalGetCharString(UErrorCode &status);
#endif /* U_HIDE_INTERNAL_API */ #endif /* U_HIDE_INTERNAL_API */
private: private:
/** /**
* Cleans up the memory for unwanted values. For example, the adopted * Cleans up the memory for unwanted values. For example, the adopted
* string or array objects. * string or array objects.
*/ */
void dispose(void); void dispose(void);
/** /**
skipping to change at line 688 skipping to change at line 735
} }
inline const UnicodeString& Formattable::getString(void) const { inline const UnicodeString& Formattable::getString(void) const {
return *fValue.fString; return *fValue.fString;
} }
inline UnicodeString& Formattable::getString(void) { inline UnicodeString& Formattable::getString(void) {
return *fValue.fString; return *fValue.fString;
} }
#ifndef U_HIDE_DEPRECATED_API
inline int32_t Formattable::getLong(UErrorCode* status) const { inline int32_t Formattable::getLong(UErrorCode* status) const {
return getLong(*status); return getLong(*status);
} }
#endif /* U_HIDE_DEPRECATED_API */
#ifndef U_HIDE_DRAFT_API
inline UFormattable* Formattable::toUFormattable() {
return reinterpret_cast<UFormattable*>(this);
}
inline const UFormattable* Formattable::toUFormattable() const {
return reinterpret_cast<const UFormattable*>(this);
}
inline Formattable* Formattable::fromUFormattable(UFormattable *fmt) {
return reinterpret_cast<Formattable *>(fmt);
}
inline const Formattable* Formattable::fromUFormattable(const UFormattable
*fmt) {
return reinterpret_cast<const Formattable *>(fmt);
}
#endif /* U_HIDE_DRAFT_API */
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif //_FMTABLE #endif //_FMTABLE
//eof //eof
 End of changes. 13 change blocks. 
8 lines changed or deleted 86 lines changed or added


 gender.h   gender.h 
skipping to change at line 22 skipping to change at line 22
* *
*************************************************************************** ***** *************************************************************************** *****
*/ */
#ifndef _GENDER #ifndef _GENDER
#define _GENDER #define _GENDER
#include "unicode/utypes.h" #include "unicode/utypes.h"
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
#ifndef U_HIDE_DRAFT_API
#include "unicode/locid.h" #include "unicode/locid.h"
#include "unicode/ugender.h" #include "unicode/ugender.h"
#include "unicode/uobject.h" #include "unicode/uobject.h"
class GenderInfoTest; class GenderInfoTest;
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
// Forward Declaration
void GenderInfo_initCache(UErrorCode &status);
/** /**
* GenderInfo computes the gender of a list as a whole given the gender of * GenderInfo computes the gender of a list as a whole given the gender of
* each element. * each element.
* @draft ICU 50 * @stable ICU 50
*/ */
class U_I18N_API GenderInfo : public UObject { class U_I18N_API GenderInfo : public UObject {
public: public:
/** /**
* Provides access to the predefined GenderInfo object for a given * Provides access to the predefined GenderInfo object for a given
* locale. * locale.
* *
* @param locale The locale for which a <code>GenderInfo</code> object is * @param locale The locale for which a <code>GenderInfo</code> object is
* returned. * returned.
* @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.
* @return The predefined <code>GenderInfo</code> object pointer for * @return The predefined <code>GenderInfo</code> object pointer for
* this locale. The returned object is immutable, so it is * this locale. The returned object is immutable, so it is
* declared as const. Caller does not own the returned * declared as const. Caller does not own the returned
* pointer, so it must not attempt to free it. * pointer, so it must not attempt to free it.
* @draft ICU 50 * @stable ICU 50
*/ */
static const GenderInfo* U_EXPORT2 getInstance(const Locale& locale, UE rrorCode& status); static const GenderInfo* U_EXPORT2 getInstance(const Locale& locale, UE rrorCode& status);
/** /**
* Determines the gender of a list as a whole given the gender of each * Determines the gender of a list as a whole given the gender of each
* of the elements. * of the elements.
* *
* @param genders the gender of each element in the list. * @param genders the gender of each element in the list.
* @param length the length of gender array. * @param length the length of gender array.
* @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.
* @return the gender of the whole list. * @return the gender of the whole list.
* @draft ICU 50 * @stable ICU 50
*/ */
UGender getListGender(const UGender* genders, int32_t length, UErrorCod e& status) const; UGender getListGender(const UGender* genders, int32_t length, UErrorCod e& status) const;
/** /**
* Destructor. * Destructor.
* *
* @draft ICU 50 * @stable ICU 50
*/ */
virtual ~GenderInfo(); virtual ~GenderInfo();
private: private:
int32_t _style; int32_t _style;
/** /**
* Copy constructor. One object per locale invariant. Clients * Copy constructor. One object per locale invariant. Clients
* must never copy GenderInfo objects. * must never copy GenderInfo objects.
*/ */
skipping to change at line 99 skipping to change at line 101
GenderInfo(); GenderInfo();
static const GenderInfo* getNeutralInstance(); static const GenderInfo* getNeutralInstance();
static const GenderInfo* getMixedNeutralInstance(); static const GenderInfo* getMixedNeutralInstance();
static const GenderInfo* getMaleTaintsInstance(); static const GenderInfo* getMaleTaintsInstance();
static const GenderInfo* loadInstance(const Locale& locale, UErrorCode& status); static const GenderInfo* loadInstance(const Locale& locale, UErrorCode& status);
friend class ::GenderInfoTest; friend class ::GenderInfoTest;
friend void GenderInfo_initCache(UErrorCode &status);
}; };
U_NAMESPACE_END U_NAMESPACE_END
#endif /* U_HIDE_DRAFT_API */
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif // _GENDER #endif // _GENDER
//eof //eof
 End of changes. 9 change blocks. 
6 lines changed or deleted 9 lines changed or added


 gregocal.h   gregocal.h 
skipping to change at line 690 skipping to change at line 690
* @return the pseudo-time-stamp for two fields * @return the pseudo-time-stamp for two fields
*/ */
int32_t aggregateStamp(int32_t stamp_a, int32_t stamp_b); int32_t aggregateStamp(int32_t stamp_a, int32_t stamp_b);
/** /**
* The point at which the Gregorian calendar rules are used, measured i n * The point at which the Gregorian calendar rules are used, measured i n
* milliseconds from the standard epoch. Default is October 15, 1582 * milliseconds from the standard epoch. Default is October 15, 1582
* (Gregorian) 00:00:00 UTC, that is, October 4, 1582 (Julian) is follo wed * (Gregorian) 00:00:00 UTC, that is, October 4, 1582 (Julian) is follo wed
* by October 15, 1582 (Gregorian). This corresponds to Julian day num ber * by October 15, 1582 (Gregorian). This corresponds to Julian day num ber
* 2299161. This is measured from the standard epoch, not in Julian Day s. * 2299161. This is measured from the standard epoch, not in Julian Day s.
* @internal
*/ */
UDate fGregorianCutover; UDate fGregorianCutover;
/** /**
* Julian day number of the Gregorian cutover * Julian day number of the Gregorian cutover
*/ */
int32_t fCutoverJulianDay; int32_t fCutoverJulianDay;
/** /**
* Midnight, local time (using this Calendar's TimeZone) at or before t he * Midnight, local time (using this Calendar's TimeZone) at or before t he
skipping to change at line 752 skipping to change at line 751
/** /**
* Used by handleComputeJulianDay() and handleComputeMonthStart(). * Used by handleComputeJulianDay() and handleComputeMonthStart().
* Temporary field indicating that the sense of the gregorian cutover s hould be inverted * Temporary field indicating that the sense of the gregorian cutover s hould be inverted
* to handle certain calculations on and around the cutover date. * to handle certain calculations on and around the cutover date.
*/ */
UBool fInvertGregorian; UBool fInvertGregorian;
public: // internal implementation public: // internal implementation
/** /**
* @internal
* @return TRUE if this calendar has the notion of a default century * @return TRUE if this calendar has the notion of a default century
* @internal
*/ */
virtual UBool haveDefaultCentury() const; virtual UBool haveDefaultCentury() const;
/** /**
* @internal
* @return the start of the default century * @return the start of the default century
* @internal
*/ */
virtual UDate defaultCenturyStart() const; virtual UDate defaultCenturyStart() const;
/** /**
* @internal
* @return the beginning year of the default century * @return the beginning year of the default century
* @internal
*/ */
virtual int32_t defaultCenturyStartYear() const; virtual int32_t defaultCenturyStartYear() const;
private:
/**
* The system maintains a static default century start date. This is i
nitialized
* the first time it is used. Before then, it is set to SYSTEM_DEFAULT
_CENTURY to
* indicate an uninitialized state. Once the system default century da
te and year
* are set, they do not change.
*/
static UDate fgSystemDefaultCenturyStart;
/**
* See documentation for systemDefaultCenturyStart.
*/
static int32_t fgSystemDefaultCenturyStartYear;
/**
* Default value that indicates the defaultCenturyStartYear is unitiali
zed
*/
static const int32_t fgSystemDefaultCenturyYear;
/**
* Default value that indicates the UDate of the beginning of the syste
m default century
*/
static const UDate fgSystemDefaultCentury;
/**
* Returns the beginning date of the 100-year window that dates with 2-
digit years
* are considered to fall within.
* @return the beginning date of the 100-year window that dates with
2-digit years
* are considered to fall within.
*/
UDate internalGetDefaultCenturyStart(void) const;
/**
* Returns the first year of the 100-year window that dates with 2-digi
t years
* are considered to fall within.
* @return the first year of the 100-year window that dates with 2-d
igit years
* are considered to fall within.
*/
int32_t internalGetDefaultCenturyStartYear(void) const;
/**
* Initializes the 100-year window that dates with 2-digit years are co
nsidered
* to fall within so that its start date is 80 years before the current
time.
*/
static void initializeSystemDefaultCentury(void);
}; };
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif // _GREGOCAL #endif // _GREGOCAL
//eof //eof
 End of changes. 8 change blocks. 
62 lines changed or deleted 3 lines changed or added


 listformatter.h   listformatter.h 
skipping to change at line 32 skipping to change at line 32
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
#include "unicode/unistr.h" #include "unicode/unistr.h"
#include "unicode/locid.h" #include "unicode/locid.h"
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
/** @internal */ /** @internal */
class Hashtable; class Hashtable;
#ifndef U_HIDE_INTERNAL_API
/** @internal */ /** @internal */
struct ListFormatData : public UMemory { struct ListFormatData : public UMemory {
UnicodeString twoPattern; UnicodeString twoPattern;
UnicodeString startPattern; UnicodeString startPattern;
UnicodeString middlePattern; UnicodeString middlePattern;
UnicodeString endPattern; UnicodeString endPattern;
ListFormatData(const UnicodeString& two, const UnicodeString& start, cons t UnicodeString& middle, const UnicodeString& end) : ListFormatData(const UnicodeString& two, const UnicodeString& start, cons t UnicodeString& middle, const UnicodeString& end) :
twoPattern(two), startPattern(start), middlePattern(middle), endPatte rn(end) {} twoPattern(two), startPattern(start), middlePattern(middle), endPatte rn(end) {}
}; };
#endif /* U_HIDE_INTERNAL_API */
/** /**
* \file * \file
* \brief C++ API: API for formatting a list. * \brief C++ API: API for formatting a list.
*/ */
/** /**
* An immutable class for formatting a list, using data from CLDR (or suppl ied * An immutable class for formatting a list, using data from CLDR (or suppl ied
* separately). * separately).
* *
* Example: Input data ["Alice", "Bob", "Charlie", "Delta"] will be formatt ed * Example: Input data ["Alice", "Bob", "Charlie", "Delta"] will be formatt ed
* as "Alice, Bob, Charlie and Delta" in English. * as "Alice, Bob, Charlie and Delta" in English.
* *
* The ListFormatter class is not intended for public subclassing. * The ListFormatter class is not intended for public subclassing.
* @draft ICU 50 * @draft ICU 50
*/ */
class U_COMMON_API ListFormatter : public UObject{ class U_COMMON_API ListFormatter : public UObject{
public: public:
/**
* Copy constructor.
* @draft ICU 52
*/
ListFormatter(const ListFormatter&);
/**
* Assignment operator.
* @draft ICU 52
*/
ListFormatter& operator=(const ListFormatter& other);
/** /**
* Creates a ListFormatter appropriate for the default locale. * Creates a ListFormatter appropriate for the default locale.
* *
* @param errorCode ICU error code, set if no data available for defaul t locale. * @param errorCode ICU error code, set if no data available for defaul t locale.
* @return Pointer to a ListFormatter object for the default locale, * @return Pointer to a ListFormatter object for the default locale,
* created from internal data derived from CLDR data. * created from internal data derived from CLDR data.
* @draft ICU 50 * @draft ICU 50
*/ */
static ListFormatter* createInstance(UErrorCode& errorCode); static ListFormatter* createInstance(UErrorCode& errorCode);
skipping to change at line 82 skipping to change at line 97
* Creates a ListFormatter appropriate for a locale. * Creates a ListFormatter appropriate for a locale.
* *
* @param locale The locale. * @param locale The locale.
* @param errorCode ICU error code, set if no data available for the gi ven locale. * @param errorCode ICU error code, set if no data available for the gi ven locale.
* @return A ListFormatter object created from internal data derived fr om * @return A ListFormatter object created from internal data derived fr om
* CLDR data. * CLDR data.
* @draft ICU 50 * @draft ICU 50
*/ */
static ListFormatter* createInstance(const Locale& locale, UErrorCode& errorCode); static ListFormatter* createInstance(const Locale& locale, UErrorCode& errorCode);
#ifndef U_HIDE_INTERNAL_API
/**
* Creates a ListFormatter appropriate for a locale and style.
*
* @param locale The locale.
* @param style the style, either "standard", "duration", or "duration-
short"
* @param errorCode ICU error code, set if no data available for the gi
ven locale.
* @return A ListFormatter object created from internal data derived fr
om
* CLDR data.
* @internal
*/
static ListFormatter* createInstance(const Locale& locale, const char*
style, UErrorCode& errorCode);
#endif /* U_HIDE_INTERNAL_API */
/** /**
* Destructor. * Destructor.
* *
* @draft ICU 50 * @draft ICU 50
*/ */
virtual ~ListFormatter(); virtual ~ListFormatter();
/** /**
* Formats a list of strings. * Formats a list of strings.
* *
* @param items An array of strings to be combined and formatted. * @param items An array of strings to be combined and formatted.
* @param n_items Length of the array items. * @param n_items Length of the array items.
* @param appendTo The string to which the result should be appended to . * @param appendTo The string to which the result should be appended to .
* @param errorCode ICU error code, set if there is an error. * @param errorCode ICU error code, set if there is an error.
* @return Formatted string combining the elements of items, appended t o appendTo. * @return Formatted string combining the elements of items, appended t o appendTo.
* @draft ICU 50 * @draft ICU 50
*/ */
UnicodeString& format(const UnicodeString items[], int32_t n_items, UnicodeString& format(const UnicodeString items[], int32_t n_items,
UnicodeString& appendTo, UErrorCode& errorCode) const; UnicodeString& appendTo, UErrorCode& errorCode) const;
#ifndef U_HIDE_INTERNAL_API
/** /**
* @internal constructor made public for testing. * @internal constructor made public for testing.
*/ */
ListFormatter(const ListFormatData& listFormatterData); ListFormatter(const ListFormatData* listFormatterData);
#endif /* U_HIDE_INTERNAL_API */
private: private:
static void initializeHash(UErrorCode& errorCode); static void initializeHash(UErrorCode& errorCode);
static const ListFormatData* getListFormatData(const Locale& locale, UE rrorCode& errorCode); static const ListFormatData* getListFormatData(const Locale& locale, co nst char *style, UErrorCode& errorCode);
ListFormatter(); ListFormatter();
ListFormatter(const ListFormatter&);
ListFormatter& operator = (const ListFormatter&);
void addNewString(const UnicodeString& pattern, UnicodeString& original String, void addNewString(const UnicodeString& pattern, UnicodeString& original String,
const UnicodeString& newString, UErrorCode& errorCode ) const; const UnicodeString& newString, UErrorCode& errorCode ) const;
const ListFormatData& data; const ListFormatData* data;
}; };
U_NAMESPACE_END U_NAMESPACE_END
#endif /* U_HIDE_DRAFT_API */ #endif /* U_HIDE_DRAFT_API */
#endif #endif
 End of changes. 9 change blocks. 
6 lines changed or deleted 38 lines changed or added


 locid.h   locid.h 
skipping to change at line 46 skipping to change at line 46
#include "unicode/uloc.h" #include "unicode/uloc.h"
#include "unicode/strenum.h" #include "unicode/strenum.h"
/** /**
* \file * \file
* \brief C++ API: Locale ID object. * \brief C++ API: Locale ID object.
*/ */
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
// Forward Declarations
void U_CALLCONV locale_available_init(); /**< @internal */
/** /**
* A <code>Locale</code> object represents a specific geographical, politic al, * A <code>Locale</code> object represents a specific geographical, politic al,
* or cultural region. An operation that requires a <code>Locale</code> to perform * or cultural region. An operation that requires a <code>Locale</code> to perform
* its task is called <em>locale-sensitive</em> and uses the <code>Locale</ code> * its task is called <em>locale-sensitive</em> and uses the <code>Locale</ code>
* to tailor information for the user. For example, displaying a number * to tailor information for the user. For example, displaying a number
* is a locale-sensitive operation--the number should be formatted * is a locale-sensitive operation--the number should be formatted
* according to the customs/conventions of the user's native country, * according to the customs/conventions of the user's native country,
* region, or culture. * region, or culture.
* *
* The Locale class is not suitable for subclassing. * The Locale class is not suitable for subclassing.
skipping to change at line 419 skipping to change at line 422
* Returns the programmatic name of the entire locale, with the languag e, * Returns the programmatic name of the entire locale, with the languag e,
* country and variant separated by underbars. If a field is missing, u p * country and variant separated by underbars. If a field is missing, u p
* to two leading underbars will occur. Example: "en", "de_DE", "en_US_ WIN", * to two leading underbars will occur. Example: "en", "de_DE", "en_US_ WIN",
* "de__POSIX", "fr__MAC", "__MAC", "_MT", "_FR_EURO" * "de__POSIX", "fr__MAC", "__MAC", "_MT", "_FR_EURO"
* @return A pointer to "name". * @return A pointer to "name".
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
inline const char * getName() const; inline const char * getName() const;
/** /**
* Returns the programmatic name of the entire locale as getName would return, * Returns the programmatic name of the entire locale as getName() woul d return,
* but without keywords. * but without keywords.
* @return A pointer to "name". * @return A pointer to "name".
* @see getName * @see getName
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
const char * getBaseName() const; const char * getBaseName() const;
/** /**
* Gets the list of keywords for the specified locale. * Gets the list of keywords for the specified locale.
* *
skipping to change at line 451 skipping to change at line 454
* @param buffer The buffer to receive the keyword value. * @param buffer The buffer to receive the keyword value.
* @param bufferCapacity The capacity of receiving buffer * @param bufferCapacity The capacity of receiving buffer
* @param status Returns any error information while performing this op eration. * @param status Returns any error information while performing this op eration.
* @return the length of the keyword value * @return the length of the keyword value
* *
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
int32_t getKeywordValue(const char* keywordName, char *buffer, int32_t bufferCapacity, UErrorCode &status) const; int32_t getKeywordValue(const char* keywordName, char *buffer, int32_t bufferCapacity, UErrorCode &status) const;
/** /**
* Sets the value for a keyword. * Sets or removes the value for a keyword.
*
* For removing all keywords, use getBaseName(),
* and construct a new Locale if it differs from getName().
* *
* @param keywordName name of the keyword to be set. Case insensitive. * @param keywordName name of the keyword to be set. Case insensitive.
* @param keywordValue value of the keyword to be set. If 0-length or * @param keywordValue value of the keyword to be set. If 0-length or
* NULL, will result in the keyword being removed. No error is given i f * NULL, will result in the keyword being removed. No error is given i f
* that keyword does not exist. * that keyword does not exist.
* @param status Returns any error information while performing this op eration. * @param status Returns any error information while performing this op eration.
* *
* @stable ICU 49 * @stable ICU 49
*/ */
void setKeywordValue(const char* keywordName, const char* keywordValue, UErrorCode &status); void setKeywordValue(const char* keywordName, const char* keywordValue, UErrorCode &status);
skipping to change at line 738 skipping to change at line 744
UBool fIsBogus; UBool fIsBogus;
static const Locale &getLocale(int locid); static const Locale &getLocale(int locid);
/** /**
* A friend to allow the default locale to be set by either the C or C+ + API. * A friend to allow the default locale to be set by either the C or C+ + API.
* @internal * @internal
*/ */
friend Locale *locale_set_default_internal(const char *, UErrorCode& st atus); friend Locale *locale_set_default_internal(const char *, UErrorCode& st atus);
/**
* @internal
*/
friend void locale_available_init();
}; };
inline UBool inline UBool
Locale::operator!=(const Locale& other) const Locale::operator!=(const Locale& other) const
{ {
return !operator==(other); return !operator==(other);
} }
inline const char * inline const char *
Locale::getCountry() const Locale::getCountry() const
 End of changes. 4 change blocks. 
2 lines changed or deleted 13 lines changed or added


 messagepattern.h   messagepattern.h 
skipping to change at line 250 skipping to change at line 250
* that value is provided by the ARG_INT or ARG_DOUBLE part preceding t he message. * that value is provided by the ARG_INT or ARG_DOUBLE part preceding t he message.
* Otherwise the message immediately follows the ARG_SELECTOR. * Otherwise the message immediately follows the ARG_SELECTOR.
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
UMSGPAT_ARG_TYPE_PLURAL, UMSGPAT_ARG_TYPE_PLURAL,
/** /**
* The argument is a SelectFormat with one or more (ARG_SELECTOR, messa ge) pairs. * The argument is a SelectFormat with one or more (ARG_SELECTOR, messa ge) pairs.
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
UMSGPAT_ARG_TYPE_SELECT, UMSGPAT_ARG_TYPE_SELECT,
#ifndef U_HIDE_DRAFT_API
/** /**
* The argument is an ordinal-number PluralFormat * The argument is an ordinal-number PluralFormat
* with the same style parts sequence and semantics as UMSGPAT_ARG_TYPE _PLURAL. * with the same style parts sequence and semantics as UMSGPAT_ARG_TYPE _PLURAL.
* @draft ICU 50 * @stable ICU 50
*/ */
UMSGPAT_ARG_TYPE_SELECTORDINAL UMSGPAT_ARG_TYPE_SELECTORDINAL
#endif /* U_HIDE_DRAFT_API */
}; };
/** /**
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
typedef enum UMessagePatternArgType UMessagePatternArgType; typedef enum UMessagePatternArgType UMessagePatternArgType;
#ifndef U_HIDE_DRAFT_API
/** /**
* \def UMSGPAT_ARG_TYPE_HAS_PLURAL_STYLE
* Returns TRUE if the argument type has a plural style part sequence and s emantics, * Returns TRUE if the argument type has a plural style part sequence and s emantics,
* for example UMSGPAT_ARG_TYPE_PLURAL and UMSGPAT_ARG_TYPE_SELECTORDINAL. * for example UMSGPAT_ARG_TYPE_PLURAL and UMSGPAT_ARG_TYPE_SELECTORDINAL.
* @draft ICU 50 * @stable ICU 50
*/ */
#define UMSGPAT_ARG_TYPE_HAS_PLURAL_STYLE(argType) \ #define UMSGPAT_ARG_TYPE_HAS_PLURAL_STYLE(argType) \
((argType)==UMSGPAT_ARG_TYPE_PLURAL || (argType)==UMSGPAT_ARG_TYPE_SELE CTORDINAL) ((argType)==UMSGPAT_ARG_TYPE_PLURAL || (argType)==UMSGPAT_ARG_TYPE_SELE CTORDINAL)
#endif /* U_HIDE_DRAFT_API */
enum { enum {
/** /**
* Return value from MessagePattern.validateArgumentName() for when * Return value from MessagePattern.validateArgumentName() for when
* the string is a valid "pattern identifier" but not a number. * the string is a valid "pattern identifier" but not a number.
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
UMSGPAT_ARG_NAME_NOT_NUMBER=-1, UMSGPAT_ARG_NAME_NOT_NUMBER=-1,
/** /**
 End of changes. 7 change blocks. 
6 lines changed or deleted 3 lines changed or added


 msgfmt.h   msgfmt.h 
/* /*
* Copyright (C) 2007-2012, International Business Machines Corporation and * Copyright (C) 2007-2013, International Business Machines Corporation and
* others. All Rights Reserved. * others. All Rights Reserved.
*************************************************************************** ***** *************************************************************************** *****
* *
* File MSGFMT.H * File MSGFMT.H
* *
* Modification History: * Modification History:
* *
* Date Name Description * Date Name Description
* 02/19/97 aliu Converted from java. * 02/19/97 aliu Converted from java.
* 03/20/97 helena Finished first cut of implementation. * 03/20/97 helena Finished first cut of implementation.
skipping to change at line 39 skipping to change at line 39
#include "unicode/format.h" #include "unicode/format.h"
#include "unicode/locid.h" #include "unicode/locid.h"
#include "unicode/messagepattern.h" #include "unicode/messagepattern.h"
#include "unicode/parseerr.h" #include "unicode/parseerr.h"
#include "unicode/plurfmt.h" #include "unicode/plurfmt.h"
#include "unicode/plurrule.h" #include "unicode/plurrule.h"
U_CDECL_BEGIN U_CDECL_BEGIN
// Forward declaration. // Forward declaration.
struct UHashtable; struct UHashtable;
typedef struct UHashtable UHashtable; typedef struct UHashtable UHashtable; /**< @internal */
U_CDECL_END U_CDECL_END
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
class AppendableWrapper; class AppendableWrapper;
class DateFormat; class DateFormat;
class NumberFormat; class NumberFormat;
/** /**
* <p>MessageFormat prepares strings for display to users, * <p>MessageFormat prepares strings for display to users,
skipping to change at line 697 skipping to change at line 697
* pattern cannot be parsed, set to failure code. * pattern cannot be parsed, set to failure code.
* @return Reference to 'appendTo' parameter. * @return Reference to 'appendTo' parameter.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual UnicodeString& format(const Formattable& obj, virtual UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo, UnicodeString& appendTo,
FieldPosition& pos, FieldPosition& pos,
UErrorCode& status) const; UErrorCode& status) const;
/** /**
* Formats the given array of arguments into a user-readable
* string. The array must be stored within a single Formattable
* object of type kArray. If the Formattable object type is not of
* type kArray, then returns a failing UErrorCode.
*
* @param obj The object to format
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param status Input/output error code. If the
* pattern cannot be parsed, set to failure code.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.0
*/
UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const;
/**
* Formats the given array of arguments into a user-defined argument na me * Formats the given array of arguments into a user-defined argument na me
* array. This function supports both named and numbered * array. This function supports both named and numbered
* arguments-- if numbered, the formatName is the * arguments-- if numbered, the formatName is the
* corresponding UnicodeStrings (e.g. "0", "1", "2"...). * corresponding UnicodeStrings (e.g. "0", "1", "2"...).
* *
* @param argumentNames argument name array * @param argumentNames argument name array
* @param arguments An array of objects to be formatted. * @param arguments An array of objects to be formatted.
* @param count The number of elements of 'argumentNames' and * @param count The number of elements of 'argumentNames' and
* arguments. The number of argumentNames and argumen ts * arguments. The number of argumentNames and argumen ts
* must be the same. * must be the same.
skipping to change at line 891 skipping to change at line 873
MessageFormat(); // default constructor not implemented MessageFormat(); // default constructor not implemented
/** /**
* This provider helps defer instantiation of a PluralRules object * This provider helps defer instantiation of a PluralRules object
* until we actually need to select a keyword. * until we actually need to select a keyword.
* For example, if the number matches an explicit-value selector like "=1" * For example, if the number matches an explicit-value selector like "=1"
* we do not need any PluralRules. * we do not need any PluralRules.
*/ */
class U_I18N_API PluralSelectorProvider : public PluralFormat::PluralSe lector { class U_I18N_API PluralSelectorProvider : public PluralFormat::PluralSe lector {
public: public:
PluralSelectorProvider(const Locale* loc, UPluralType type); PluralSelectorProvider(const MessageFormat &mf, UPluralType type);
virtual ~PluralSelectorProvider(); virtual ~PluralSelectorProvider();
virtual UnicodeString select(double number, UErrorCode& ec) const; virtual UnicodeString select(void *ctx, double number, UErrorCode& ec) const;
void reset(const Locale* loc); void reset();
private: private:
const Locale* locale; const MessageFormat &msgFormat;
PluralRules* rules; PluralRules* rules;
UPluralType type; UPluralType type;
}; };
/** /**
* A MessageFormat formats an array of arguments. Each argument * A MessageFormat formats an array of arguments. Each argument
* has an expected type, based on the pattern. For example, if * has an expected type, based on the pattern. For example, if
* the pattern contains the subformat "{3,number,integer}", then * the pattern contains the subformat "{3,number,integer}", then
* we expect argument 3 to have type Formattable::kLong. This * we expect argument 3 to have type Formattable::kLong. This
* array needs to grow dynamically if the MessageFormat is * array needs to grow dynamically if the MessageFormat is
skipping to change at line 973 skipping to change at line 955
int32_t cnt, int32_t cnt,
UnicodeString& appendTo, UnicodeString& appendTo,
FieldPosition* pos, FieldPosition* pos,
UErrorCode& status) const; UErrorCode& status) const;
/** /**
* Formats the arguments and writes the result into the * Formats the arguments and writes the result into the
* AppendableWrapper, updates the field position. * AppendableWrapper, updates the field position.
* *
* @param msgStart Index to msgPattern part to start formatting fr om. * @param msgStart Index to msgPattern part to start formatting fr om.
* @param pluralNumber Zero except when formatting a plural argument s ub-message * @param plNumber NULL except when formatting a plural argument s ub-message
* where a '#' is replaced by the format string fo r this number. * where a '#' is replaced by the format string fo r this number.
* @param arguments The formattable objects array. (Must not be NUL L.) * @param arguments The formattable objects array. (Must not be NUL L.)
* @param argumentNames NULL if numbered values are used. Otherwise the same * @param argumentNames NULL if numbered values are used. Otherwise the same
* length as "arguments", and each entry is the na me of the * length as "arguments", and each entry is the na me of the
* corresponding argument in "arguments". * corresponding argument in "arguments".
* @param cnt The length of arguments (and of argumentNames i f that is not NULL). * @param cnt The length of arguments (and of argumentNames i f that is not NULL).
* @param appendTo Output parameter to receive the result. * @param appendTo Output parameter to receive the result.
* The result string is appended to existing conte nts. * The result string is appended to existing conte nts.
* @param pos Field position status. * @param pos Field position status.
* @param success The error code status. * @param success The error code status.
*/ */
void format(int32_t msgStart, void format(int32_t msgStart,
double pluralNumber, const void *plNumber,
const Formattable* arguments, const Formattable* arguments,
const UnicodeString *argumentNames, const UnicodeString *argumentNames,
int32_t cnt, int32_t cnt,
AppendableWrapper& appendTo, AppendableWrapper& appendTo,
FieldPosition* pos, FieldPosition* pos,
UErrorCode& success) const; UErrorCode& success) const;
UnicodeString getArgName(int32_t partIndex); UnicodeString getArgName(int32_t partIndex);
void setArgStartFormat(int32_t argStart, Format* formatter, UErrorCode& status); void setArgStartFormat(int32_t argStart, Format* formatter, UErrorCode& status);
skipping to change at line 1025 skipping to change at line 1007
Formattable* parse(int32_t msgStart, Formattable* parse(int32_t msgStart,
const UnicodeString& source, const UnicodeString& source,
ParsePosition& pos, ParsePosition& pos,
int32_t& count, int32_t& count,
UErrorCode& ec) const; UErrorCode& ec) const;
FieldPosition* updateMetaData(AppendableWrapper& dest, int32_t prevLeng th, FieldPosition* updateMetaData(AppendableWrapper& dest, int32_t prevLeng th,
FieldPosition* fp, const Formattable* arg Id) const; FieldPosition* fp, const Formattable* arg Id) const;
/**
* Finds the "other" sub-message.
* @param partIndex the index of the first PluralFormat argument style
part.
* @return the "other" sub-message start part index.
*/
int32_t findOtherSubMessage(int32_t partIndex) const;
/**
* Returns the ARG_START index of the first occurrence of the plural nu
mber in a sub-message.
* Returns -1 if it is a REPLACE_NUMBER.
* Returns 0 if there is neither.
*/
int32_t findFirstPluralNumberArg(int32_t msgStart, const UnicodeString
&argName) const;
Format* getCachedFormatter(int32_t argumentNumber) const; Format* getCachedFormatter(int32_t argumentNumber) const;
UnicodeString getLiteralStringUntilNextArgument(int32_t from) const; UnicodeString getLiteralStringUntilNextArgument(int32_t from) const;
void copyObjects(const MessageFormat& that, UErrorCode& ec); void copyObjects(const MessageFormat& that, UErrorCode& ec);
void formatComplexSubMessage(int32_t msgStart, void formatComplexSubMessage(int32_t msgStart,
double pluralNumber, const void *plNumber,
const Formattable* arguments, const Formattable* arguments,
const UnicodeString *argumentNames, const UnicodeString *argumentNames,
int32_t cnt, int32_t cnt,
AppendableWrapper& appendTo, AppendableWrapper& appendTo,
UErrorCode& success) const; UErrorCode& success) const;
/** /**
* Convenience method that ought to be in NumberFormat * Convenience method that ought to be in NumberFormat
*/ */
NumberFormat* createIntegerFormat(const Locale& locale, UErrorCode& sta tus) const; NumberFormat* createIntegerFormat(const Locale& locale, UErrorCode& sta tus) const;
/** /**
* Returns array of argument types in the parsed pattern * Returns array of argument types in the parsed pattern
* for use in C API. Only for the use of umsg_vformat(). Not * for use in C API. Only for the use of umsg_vformat(). Not
* for public consumption. * for public consumption.
* @param listCount Output parameter to receive the size of array * @param listCount Output parameter to receive the size of array
* @return The array of formattable types in the pattern * @return The array of formattable types in the pattern
* @internal
*/ */
const Formattable::Type* getArgTypeList(int32_t& listCount) const { const Formattable::Type* getArgTypeList(int32_t& listCount) const {
listCount = argTypeCount; listCount = argTypeCount;
return argTypes; return argTypes;
} }
/** /**
* Resets the internal MessagePattern, and other associated caches. * Resets the internal MessagePattern, and other associated caches.
*/ */
void resetPattern(); void resetPattern();
/** /**
* A DummyFormatter that we use solely to store a NULL value. UHash doe s * A DummyFormatter that we use solely to store a NULL value. UHash doe s
* not support storing NULL values. * not support storing NULL values.
* @internal
*/ */
class U_I18N_API DummyFormat : public Format { class U_I18N_API DummyFormat : public Format {
public: public:
virtual UBool operator==(const Format&) const; virtual UBool operator==(const Format&) const;
virtual Format* clone() const; virtual Format* clone() const;
virtual UnicodeString& format(const Formattable& obj, virtual UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo, UnicodeString& appendTo,
UErrorCode& status) const; UErrorCode& status) const;
virtual UnicodeString& format(const Formattable&, virtual UnicodeString& format(const Formattable&,
UnicodeString& appendTo, UnicodeString& appendTo,
skipping to change at line 1090 skipping to change at line 1084
FieldPositionIterator* posIter, FieldPositionIterator* posIter,
UErrorCode& status) const; UErrorCode& status) const;
virtual void parseObject(const UnicodeString&, virtual void parseObject(const UnicodeString&,
Formattable&, Formattable&,
ParsePosition&) const; ParsePosition&) const;
}; };
friend class MessageFormatAdapter; // getFormatTypeList() access friend class MessageFormatAdapter; // getFormatTypeList() access
}; };
inline UnicodeString&
MessageFormat::format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const {
return Format::format(obj, appendTo, status);
}
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif // _MSGFMT #endif // _MSGFMT
//eof //eof
 End of changes. 14 change blocks. 
36 lines changed or deleted 26 lines changed or added


 numfmt.h   numfmt.h 
skipping to change at line 570 skipping to change at line 570
* @return Reference to 'appendTo' parameter. * @return Reference to 'appendTo' parameter.
* @internal * @internal
*/ */
virtual UnicodeString& format(const DigitList &number, virtual UnicodeString& format(const DigitList &number,
UnicodeString& appendTo, UnicodeString& appendTo,
FieldPosition& pos, FieldPosition& pos,
UErrorCode& status) const; UErrorCode& status) const;
public: public:
/**
* Redeclared Format method.
* @param obj The object to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param status Output parameter set to a failure error code
* when a failure occurs.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.0
*/
UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const;
/** /**
* Return a long if possible (e.g. within range LONG_MAX, * Return a long if possible (e.g. within range LONG_MAX,
* LONG_MAX], and with no decimals), otherwise a double. If * LONG_MAX], and with no decimals), otherwise a double. If
* IntegerOnly is set, will stop at a decimal point (or equivalent; * IntegerOnly is set, will stop at a decimal point (or equivalent;
* e.g. for rational numbers "1 2/3", will stop after the 1). * e.g. for rational numbers "1 2/3", will stop after the 1).
* <P> * <P>
* If no object can be parsed, index is unchanged, and NULL is * If no object can be parsed, index is unchanged, and NULL is
* returned. * returned.
* <P> * <P>
* This is a pure virtual which concrete subclasses must implement. * This is a pure virtual which concrete subclasses must implement.
skipping to change at line 1019 skipping to change at line 1005
*/ */
static NumberFormat* makeInstance(const Locale& desiredLocale, static NumberFormat* makeInstance(const Locale& desiredLocale,
UNumberFormatStyle style, UNumberFormatStyle style,
UErrorCode& errorCode); UErrorCode& errorCode);
UBool fGroupingUsed; UBool fGroupingUsed;
int32_t fMaxIntegerDigits; int32_t fMaxIntegerDigits;
int32_t fMinIntegerDigits; int32_t fMinIntegerDigits;
int32_t fMaxFractionDigits; int32_t fMaxFractionDigits;
int32_t fMinFractionDigits; int32_t fMinFractionDigits;
protected:
static const int32_t gDefaultMaxIntegerDigits;
static const int32_t gDefaultMinIntegerDigits;
private:
UBool fParseIntegerOnly; UBool fParseIntegerOnly;
UBool fLenient; // TRUE => lenient parse is enabled UBool fLenient; // TRUE => lenient parse is enabled
// ISO currency code // ISO currency code
UChar fCurrency[4]; UChar fCurrency[4];
friend class ICUNumberFormatFactory; // access to makeInstance friend class ICUNumberFormatFactory; // access to makeInstance
friend class ICUNumberFormatService; friend class ICUNumberFormatService;
friend class ::NumberFormatTest; // access to isStyleSupported() friend class ::NumberFormatTest; // access to isStyleSupported()
}; };
skipping to change at line 1128 skipping to change at line 1120
{ {
return fParseIntegerOnly; return fParseIntegerOnly;
} }
inline UBool inline UBool
NumberFormat::isLenient() const NumberFormat::isLenient() const
{ {
return fLenient; return fLenient;
} }
inline UnicodeString&
NumberFormat::format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const {
return Format::format(obj, appendTo, status);
}
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif // _NUMFMT #endif // _NUMFMT
//eof //eof
 End of changes. 3 change blocks. 
21 lines changed or deleted 6 lines changed or added


 numsys.h   numsys.h 
skipping to change at line 21 skipping to change at line 21
* Date Name Description * Date Name Description
* *
*************************************************************************** ***** *************************************************************************** *****
*/ */
#ifndef NUMSYS #ifndef NUMSYS
#define NUMSYS #define NUMSYS
#include "unicode/utypes.h" #include "unicode/utypes.h"
#ifndef U_HIDE_INTERNAL_API
/** /**
* \def NUMSYS_NAME_CAPACITY * \def NUMSYS_NAME_CAPACITY
* Size of a numbering system name. * Size of a numbering system name.
* @internal * @internal
*/ */
#define NUMSYS_NAME_CAPACITY 8 #define NUMSYS_NAME_CAPACITY 8
#endif /* U_HIDE_INTERNAL_API */
/** /**
* \file * \file
* \brief C++ API: NumberingSystem object * \brief C++ API: NumberingSystem object
*/ */
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
#include "unicode/format.h" #include "unicode/format.h"
#include "unicode/uobject.h" #include "unicode/uobject.h"
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
/** /**
* Defines numbering systems. A numbering system describes the scheme by wh ich * Defines numbering systems. A numbering system describes the scheme by wh ich
* numbers are to be presented to the end user. In its simplest form, a nu mbering * numbers are to be presented to the end user. In its simplest form, a nu mbering
* system describes the set of digit characters that are to be used to disp lay * system describes the set of digit characters that are to be used to disp lay
* numbers, such as Western digits, Thai digits, Arabic-Indic digits, etc. * numbers, such as Western digits, Thai digits, Arabic-Indic digits, etc.,
in a
* positional numbering system with a specified radix (typically 10).
* More complicated numbering systems are algorithmic in nature, and requir e use * More complicated numbering systems are algorithmic in nature, and requir e use
* of an RBNF formatter ( rule based number formatter ), in order to calcul ate * of an RBNF formatter ( rule based number formatter ), in order to calcul ate
* the characters to be displayed for a given number. Examples of algorith mic * the characters to be displayed for a given number. Examples of algorith mic
* numbering systems include Roman numerals, Chinese numerals, and Hebrew n umerals. * numbering systems include Roman numerals, Chinese numerals, and Hebrew n umerals.
* Formatting rules for many commonly used numbering systems are included i n * Formatting rules for many commonly used numbering systems are included i n
* the ICU package, based on the numbering system rules defined in CLDR. * the ICU package, based on the numbering system rules defined in CLDR.
* Alternate numbering systems can be specified to a locale by using the * Alternate numbering systems can be specified to a locale by using the
* numbers locale keyword. * numbers locale keyword.
*/ */
skipping to change at line 112 skipping to change at line 111
static NumberingSystem* U_EXPORT2 createInstance(int32_t radix, UBool i sAlgorithmic, const UnicodeString& description, UErrorCode& status ); static NumberingSystem* U_EXPORT2 createInstance(int32_t radix, UBool i sAlgorithmic, const UnicodeString& description, UErrorCode& status );
/** /**
* Return a StringEnumeration over all the names of numbering systems k nown to ICU. * Return a StringEnumeration over all the names of numbering systems k nown to ICU.
* @stable ICU 4.2 * @stable ICU 4.2
*/ */
static StringEnumeration * U_EXPORT2 getAvailableNames(UErrorCode& sta tus); static StringEnumeration * U_EXPORT2 getAvailableNames(UErrorCode& sta tus);
/** /**
* Create a numbering system from one of the predefined numbering syste * Create a numbering system from one of the predefined numbering syste
ms known to ICU. ms specified
* by CLDR and known to ICU, such as "latn", "arabext", or "hanidec"; t
he full list
* is returned by unumsys_openAvailableNames. Note that some of the nam
es listed at
* http://unicode.org/repos/cldr/tags/latest/common/bcp47/number.xml -
e.g.
* default, native, traditional, finance - do not identify specific num
bering systems,
* but rather key values that may only be used as part of a locale, whi
ch in turn
* defines how they are mapped to a specific numbering system such as "
latn" or "hant".
* @param name The name of the numbering system. * @param name The name of the numbering system.
* @param status ICU status * @param status ICU status
* @stable ICU 4.2 * @stable ICU 4.2
*/ */
static NumberingSystem* U_EXPORT2 createInstanceByName(const char* name , UErrorCode& status); static NumberingSystem* U_EXPORT2 createInstanceByName(const char* name , UErrorCode& status);
/** /**
* Returns the radix of this numbering system. * Returns the radix of this numbering system. Simple positional number
ing systems
* typically have radix 10, but might have a radix of e.g. 16 for hexad
ecimal. The
* radix is less well-defined for non-positional algorithmic systems.
* @stable ICU 4.2 * @stable ICU 4.2
*/ */
int32_t getRadix(); int32_t getRadix() const;
/** /**
* Returns the name of this numbering system if it was created using on e of the predefined names * Returns the name of this numbering system if it was created using on e of the predefined names
* known to ICU. Otherwise, returns NULL. * known to ICU. Otherwise, returns NULL.
* @stable ICU 4.6 * @stable ICU 4.6
*/ */
const char * getName(); const char * getName() const;
/** /**
* Returns the description string of this numbering system, which is ei * Returns the description string of this numbering system. For simple
ther * positional systems this is the ordered string of digits (with length
* the string of digits in the case of simple systems, or the ruleset n matching
ame * the radix), e.g. "\u3007\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u
* in the case of algorithmic systems. 516B\u4E5D"
* for "hanidec"; it would be "0123456789ABCDEF" for hexadecimal. For
* algorithmic systems this is the name of the RBNF ruleset used for fo
rmatting,
* e.g. "zh/SpelloutRules/%spellout-cardinal" for "hans" or "%greek-upp
er" for
* "grek".
* @stable ICU 4.2 * @stable ICU 4.2
*/ */
virtual UnicodeString getDescription(); virtual UnicodeString getDescription() const;
/** /**
* Returns TRUE if the given numbering system is algorithmic * Returns TRUE if the given numbering system is algorithmic
* *
* @return TRUE if the numbering system is algorithmic. * @return TRUE if the numbering system is algorithmic.
* Otherwise, return FALSE. * Otherwise, return FALSE.
* @stable ICU 4.2 * @stable ICU 4.2
*/ */
UBool isAlgorithmic() const; UBool isAlgorithmic() const;
 End of changes. 9 change blocks. 
14 lines changed or deleted 36 lines changed or added


 platform.h   platform.h 
/* /*
*************************************************************************** *** *************************************************************************** ***
* *
* Copyright (C) 1997-2012, International Business Machines * Copyright (C) 1997-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
* *
*************************************************************************** *** *************************************************************************** ***
* *
* FILE NAME : platform.h * FILE NAME : platform.h
* *
* Date Name Description * Date Name Description
* 05/13/98 nos Creation (content moved here from ptypes.h). * 05/13/98 nos Creation (content moved here from ptypes.h).
* 03/02/99 stephen Added AS400 support. * 03/02/99 stephen Added AS400 support.
* 03/30/99 stephen Added Linux support. * 03/30/99 stephen Added Linux support.
skipping to change at line 147 skipping to change at line 147
#elif defined(__CYGWIN__) #elif defined(__CYGWIN__)
# define U_PLATFORM U_PF_CYGWIN # define U_PLATFORM U_PF_CYGWIN
#elif defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64 ) #elif defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64 )
# define U_PLATFORM U_PF_WINDOWS # define U_PLATFORM U_PF_WINDOWS
#elif defined(__ANDROID__) #elif defined(__ANDROID__)
# define U_PLATFORM U_PF_ANDROID # define U_PLATFORM U_PF_ANDROID
/* Android wchar_t support depends on the API level. */ /* Android wchar_t support depends on the API level. */
# include <android/api-level.h> # include <android/api-level.h>
#elif defined(linux) || defined(__linux__) || defined(__linux) #elif defined(linux) || defined(__linux__) || defined(__linux)
# define U_PLATFORM U_PF_LINUX # define U_PLATFORM U_PF_LINUX
#elif defined(__APPLE__) && defined(__MACH__)
# include <TargetConditionals.h>
# if defined(TARGET_OS_IPHONE) && TARGET_OS_IPHONE /* variant of TARGET_
OS_MAC */
# define U_PLATFORM U_PF_IPHONE
# else
# define U_PLATFORM U_PF_DARWIN
# endif
#elif defined(BSD) || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) | | defined(__NetBSD__) || defined(__OpenBSD__) || defined(__MirBSD__) #elif defined(BSD) || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) | | defined(__NetBSD__) || defined(__OpenBSD__) || defined(__MirBSD__)
# define U_PLATFORM U_PF_BSD # define U_PLATFORM U_PF_BSD
#elif defined(sun) || defined(__sun) #elif defined(sun) || defined(__sun)
/* Check defined(__SVR4) || defined(__svr4__) to distinguish Solaris fr om SunOS? */ /* Check defined(__SVR4) || defined(__svr4__) to distinguish Solaris fr om SunOS? */
# define U_PLATFORM U_PF_SOLARIS # define U_PLATFORM U_PF_SOLARIS
# if defined(__GNUC__) # if defined(__GNUC__)
/* Solaris/GCC needs this header file to get the proper endianness. Normally, this /* Solaris/GCC needs this header file to get the proper endianness. Normally, this
* header file is included with stddef.h but on Solairs/GCC, the GC C version of stddef.h * header file is included with stddef.h but on Solairs/GCC, the GC C version of stddef.h
* is included which does not include this header file. * is included which does not include this header file.
*/ */
# include <sys/isa_defs.h> # include <sys/isa_defs.h>
# endif # endif
#elif defined(_AIX) || defined(__TOS_AIX__) #elif defined(_AIX) || defined(__TOS_AIX__)
# define U_PLATFORM U_PF_AIX # define U_PLATFORM U_PF_AIX
#elif defined(_hpux) || defined(hpux) || defined(__hpux) #elif defined(_hpux) || defined(hpux) || defined(__hpux)
# define U_PLATFORM U_PF_HPUX # define U_PLATFORM U_PF_HPUX
#elif defined(sgi) || defined(__sgi) #elif defined(sgi) || defined(__sgi)
# define U_PLATFORM U_PF_IRIX # define U_PLATFORM U_PF_IRIX
#elif defined(__APPLE__) && defined(__MACH__)
# include <TargetConditionals.h>
# if defined(TARGET_OS_IPHONE) && TARGET_OS_IPHONE /* variant of TARGET_
OS_MAC */
# define U_PLATFORM U_PF_IPHONE
# else
# define U_PLATFORM U_PF_DARWIN
# endif
#elif defined(macintosh) #elif defined(macintosh)
# define U_PLATFORM U_PF_CLASSIC_MACOS # define U_PLATFORM U_PF_CLASSIC_MACOS
#elif defined(__QNX__) || defined(__QNXNTO__) #elif defined(__QNX__) || defined(__QNXNTO__)
# define U_PLATFORM U_PF_QNX # define U_PLATFORM U_PF_QNX
#elif defined(__TOS_MVS__) #elif defined(__TOS_MVS__)
# define U_PLATFORM U_PF_OS390 # define U_PLATFORM U_PF_OS390
#elif defined(__OS400__) || defined(__TOS_OS400__) #elif defined(__OS400__) || defined(__TOS_OS400__)
# define U_PLATFORM U_PF_OS400 # define U_PLATFORM U_PF_OS400
#else #else
# define U_PLATFORM U_PF_UNKNOWN # define U_PLATFORM U_PF_UNKNOWN
skipping to change at line 342 skipping to change at line 342
#define U_IOSTREAM_SOURCE 199711 #define U_IOSTREAM_SOURCE 199711
#endif #endif
/** /**
* \def U_HAVE_STD_STRING * \def U_HAVE_STD_STRING
* Defines whether the standard C++ (STL) &lt;string&gt; header is availabl e. * Defines whether the standard C++ (STL) &lt;string&gt; header is availabl e.
* @internal * @internal
*/ */
#ifdef U_HAVE_STD_STRING #ifdef U_HAVE_STD_STRING
/* Use the predefined value. */ /* Use the predefined value. */
#elif U_PLATFORM == U_PF_ANDROID
# define U_HAVE_STD_STRING 0
#else #else
# define U_HAVE_STD_STRING 1 # define U_HAVE_STD_STRING 1
#endif #endif
/*========================================================================= ==*/ /*========================================================================= ==*/
/** @{ Compiler and environment features */ /** @{ Compiler and environment features */
/*========================================================================= ==*/ /*========================================================================= ==*/
/** /**
* \def U_GCC_MAJOR_MINOR * \def U_GCC_MAJOR_MINOR
 End of changes. 4 change blocks. 
11 lines changed or deleted 9 lines changed or added


 plurfmt.h   plurfmt.h 
/* /*
*************************************************************************** **** *************************************************************************** ****
* Copyright (C) 2007-2013, International Business Machines Corporation and * Copyright (C) 2007-2013, International Business Machines Corporation and
* others. All Rights Reserved. * others. All Rights Reserved.
*************************************************************************** **** *************************************************************************** ****
* *
* File PLURFMT.H * File PLURFMT.H
*
* Modification History:*
* Date Name Description
*
*************************************************************************** ***** *************************************************************************** *****
*/ */
#ifndef PLURFMT #ifndef PLURFMT
#define PLURFMT #define PLURFMT
#include "unicode/utypes.h" #include "unicode/utypes.h"
/** /**
* \file * \file
skipping to change at line 192 skipping to change at line 188
/** /**
* Creates a new <code>PluralFormat</code> for a given set of rules. * Creates a new <code>PluralFormat</code> for a given set of rules.
* The standard number formatting will be done using the given locale. * The standard number formatting will be done using the given locale.
* @param locale the default number formatting will be done using this * @param locale the default number formatting will be done using this
* locale. * locale.
* @param rules defines the behavior of the <code>PluralFormat</code> * @param rules defines the behavior of the <code>PluralFormat</code>
* object. * object.
* @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
* <p>
* <h4>Sample code</h4>
* \snippet samples/plurfmtsample/plurfmtsample.cpp PluralFormatExam
ple1
* \snippet samples/plurfmtsample/plurfmtsample.cpp PluralFormatExam
ple
* <p>
*/ */
PluralFormat(const Locale& locale, const PluralRules& rules, UErrorCode & status); PluralFormat(const Locale& locale, const PluralRules& rules, UErrorCode & status);
#ifndef U_HIDE_DRAFT_API
/** /**
* Creates a new <code>PluralFormat</code> for the plural type. * Creates a new <code>PluralFormat</code> for the plural type.
* The standard number formatting will be done using the given locale. * The standard number formatting will be done using the given locale.
* @param locale the default number formatting will be done using this * @param locale the default number formatting will be done using this
* locale. * locale.
* @param type The plural type (e.g., cardinal or ordinal). * @param type The plural type (e.g., cardinal or ordinal).
* @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.
* @draft ICU 50 * @stable ICU 50
*/ */
PluralFormat(const Locale& locale, UPluralType type, UErrorCode& status ); PluralFormat(const Locale& locale, UPluralType type, UErrorCode& status );
#endif /* U_HIDE_DRAFT_API */
/** /**
* Creates a new cardinal-number <code>PluralFormat</code> for a given pattern string. * Creates a new cardinal-number <code>PluralFormat</code> for a given pattern string.
* The default locale will be used to get the set of plural rules and f or * The default locale will be used to get the set of plural rules and f or
* standard number formatting. * standard number formatting.
* @param pattern the pattern for this <code>PluralFormat</code>. * @param pattern the pattern for this <code>PluralFormat</code>.
* errors are returned to status if the pattern is inva lid. * errors are returned to status if the pattern is inva lid.
* @param status output param set to success/failure code on exit, wh ich * @param status output param set to success/failure code on exit, wh ich
* 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
skipping to change at line 271 skipping to change at line 270
* errors are returned to status if the pattern is inval id. * errors are returned to status if the pattern is inval id.
* @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
*/ */
PluralFormat(const Locale& locale, PluralFormat(const Locale& locale,
const PluralRules& rules, const PluralRules& rules,
const UnicodeString& pattern, const UnicodeString& pattern,
UErrorCode& status); UErrorCode& status);
#ifndef U_HIDE_DRAFT_API
/** /**
* Creates a new <code>PluralFormat</code> for a plural type, a * Creates a new <code>PluralFormat</code> for a plural type, a
* pattern and a locale. * pattern and a locale.
* @param locale the <code>PluralFormat</code> will be configured with * @param locale the <code>PluralFormat</code> will be configured with
* rules for this locale. This locale will also be used for * rules for this locale. This locale will also be used for
* standard number formatting. * standard number formatting.
* @param type The plural type (e.g., cardinal or ordinal). * @param type The plural type (e.g., cardinal or ordinal).
* @param pattern the pattern for this <code>PluralFormat</code>. * @param pattern the pattern for this <code>PluralFormat</code>.
* errors are returned to status if the pattern is inval id. * errors are returned to status if the pattern is inval id.
* @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.
* @draft ICU 50 * @stable ICU 50
*/ */
PluralFormat(const Locale& locale, PluralFormat(const Locale& locale,
UPluralType type, UPluralType type,
const UnicodeString& pattern, const UnicodeString& pattern,
UErrorCode& status); UErrorCode& status);
#endif /* U_HIDE_DRAFT_API */
/** /**
* copy constructor. * copy constructor.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
PluralFormat(const PluralFormat& other); PluralFormat(const PluralFormat& other);
/** /**
* Destructor. * Destructor.
* @stable ICU 4.0 * @stable ICU 4.0
skipping to change at line 452 skipping to change at line 449
*/ */
virtual UBool operator!=(const Format& other) const; virtual UBool operator!=(const Format& other) const;
/** /**
* Clones this Format object polymorphically. The caller owns the * Clones this Format object polymorphically. The caller owns the
* result and should delete it when done. * result and should delete it when done.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
virtual Format* clone(void) const; virtual Format* clone(void) const;
/** /**
* Redeclared Format method. * Formats a plural message for a number taken from a Formattable object
.
* *
* @param obj The object to be formatted into a string. * @param obj The object containing a number for which the
* plural message should be formatted.
* The object must be of a numeric type.
* @param appendTo output parameter to receive result. * @param appendTo output parameter to receive result.
* Result is appended to existing contents. * Result is appended to existing contents.
* @param pos On input: an alignment field, if desired. * @param pos On input: an alignment field, if desired.
* On output: the offsets of the alignment field. * On output: the offsets of the alignment field.
* @param status output param filled with success/failure status. * @param status output param filled with success/failure status.
* @return Reference to 'appendTo' parameter. * @return Reference to 'appendTo' parameter.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
UnicodeString& format(const Formattable& obj, UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo, UnicodeString& appendTo,
skipping to change at line 538 skipping to change at line 537
#endif #endif
/** /**
* @internal * @internal
*/ */
class U_I18N_API PluralSelector : public UMemory { class U_I18N_API PluralSelector : public UMemory {
public: public:
virtual ~PluralSelector(); virtual ~PluralSelector();
/** /**
* Given a number, returns the appropriate PluralFormat keyword. * Given a number, returns the appropriate PluralFormat keyword.
* *
* @param context worker object for the selector.
* @param number The number to be plural-formatted. * @param number The number to be plural-formatted.
* @param ec Error code. * @param ec Error code.
* @return The selected PluralFormat keyword. * @return The selected PluralFormat keyword.
* @internal
*/ */
virtual UnicodeString select(double number, UErrorCode& ec) const = 0; virtual UnicodeString select(void *context, double number, UErrorCo de& ec) const = 0;
}; };
/** /**
* @internal * @internal
*/ */
class U_I18N_API PluralSelectorAdapter : public PluralSelector { class U_I18N_API PluralSelectorAdapter : public PluralSelector {
public: public:
PluralSelectorAdapter() : pluralRules(NULL) { PluralSelectorAdapter() : pluralRules(NULL) {
} }
virtual ~PluralSelectorAdapter(); virtual ~PluralSelectorAdapter();
virtual UnicodeString select(double number, UErrorCode& /*ec*/) con st; virtual UnicodeString select(void *context, double number, UErrorCo de& /*ec*/) const; /**< @internal */
void reset(); void reset();
PluralRules* pluralRules; PluralRules* pluralRules;
}; };
#if defined(__xlC__) #if defined(__xlC__)
// End of xlC bug workaround, keep remaining definitions private. // End of xlC bug workaround, keep remaining definitions private.
private: private:
#endif #endif
skipping to change at line 580 skipping to change at line 581
PluralSelectorAdapter pluralRulesWrapper; PluralSelectorAdapter pluralRulesWrapper;
PluralFormat(); // default constructor not implemented PluralFormat(); // default constructor not implemented
void init(const PluralRules* rules, UPluralType type, UErrorCode& statu s); void init(const PluralRules* rules, UPluralType type, UErrorCode& statu s);
/** /**
* Copies dynamically allocated values (pointer fields). * Copies dynamically allocated values (pointer fields).
* Others are copied using their copy constructors and assignment opera tors. * Others are copied using their copy constructors and assignment opera tors.
*/ */
void copyObjects(const PluralFormat& other); void copyObjects(const PluralFormat& other);
UnicodeString& format(const Formattable& numberObject, double number,
UnicodeString& appendTo,
FieldPosition& pos,
UErrorCode& status) const; /**< @internal */
/** /**
* Finds the PluralFormat sub-message for the given number, or the "oth er" sub-message. * Finds the PluralFormat sub-message for the given number, or the "oth er" sub-message.
* @param pattern A MessagePattern. * @param pattern A MessagePattern.
* @param partIndex the index of the first PluralFormat argument style part. * @param partIndex the index of the first PluralFormat argument style part.
* @param selector the PluralSelector for mapping the number (minus off set) to a keyword. * @param selector the PluralSelector for mapping the number (minus off set) to a keyword.
* @param context worker object for the selector.
* @param number a number to be matched to one of the PluralFormat argu ment's explicit values, * @param number a number to be matched to one of the PluralFormat argu ment's explicit values,
* or mapped via the PluralSelector. * or mapped via the PluralSelector.
* @param ec ICU error code. * @param ec ICU error code.
* @return the sub-message start part index. * @return the sub-message start part index.
*/ */
static int32_t findSubMessage( static int32_t findSubMessage(
const MessagePattern& pattern, int32_t partIndex, const MessagePattern& pattern, int32_t partIndex,
const PluralSelector& selector, double number, UErrorCode& ec); const PluralSelector& selector, void *context, double number, UErr orCode& ec); /**< @internal */
friend class MessageFormat; friend class MessageFormat;
}; };
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif // _PLURFMT #endif // _PLURFMT
//eof //eof
 End of changes. 17 change blocks. 
16 lines changed or deleted 26 lines changed or added


 plurrule.h   plurrule.h 
skipping to change at line 41 skipping to change at line 41
/** /**
* Value returned by PluralRules::getUniqueKeywordValue() when there is no * Value returned by PluralRules::getUniqueKeywordValue() when there is no
* unique value to return. * unique value to return.
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
#define UPLRULES_NO_UNIQUE_VALUE ((double)-0.00123456777) #define UPLRULES_NO_UNIQUE_VALUE ((double)-0.00123456777)
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
class Hashtable; class Hashtable;
class FixedDecimal;
class RuleChain; class RuleChain;
class RuleParser; class PluralRuleParser;
class PluralKeywordEnumeration; class PluralKeywordEnumeration;
class AndConstraint;
/** /**
* Defines rules for mapping non-negative numeric values onto a small set o f * Defines rules for mapping non-negative numeric values onto a small set o f
* keywords. Rules are constructed from a text description, consisting * keywords. Rules are constructed from a text description, consisting
* of a series of keywords and conditions. The {@link #select} method * of a series of keywords and conditions. The {@link #select} method
* examines each condition in order and returns the keyword for the * examines each condition in order and returns the keyword for the
* first condition that matches the number. If none match, * first condition that matches the number. If none match,
* default rule(other) is returned. * default rule(other) is returned.
* *
* For more information, details, and tips for writing rules, see the * For more information, details, and tips for writing rules, see the
skipping to change at line 92 skipping to change at line 94
* \code * \code
* rules = rule (';' rule)* * rules = rule (';' rule)*
* rule = keyword ':' condition * rule = keyword ':' condition
* keyword = <identifier> * keyword = <identifier>
* condition = and_condition ('or' and_condition)* * condition = and_condition ('or' and_condition)*
* and_condition = relation ('and' relation)* * and_condition = relation ('and' relation)*
* relation = is_relation | in_relation | within_relation | 'n' <EOL> * relation = is_relation | in_relation | within_relation | 'n' <EOL>
* is_relation = expr 'is' ('not')? value * is_relation = expr 'is' ('not')? value
* in_relation = expr ('not')? 'in' range_list * in_relation = expr ('not')? 'in' range_list
* within_relation = expr ('not')? 'within' range * within_relation = expr ('not')? 'within' range
* expr = 'n' ('mod' value)? * expr = ('n' | 'i' | 'f' | 'v' | 'j') ('mod' value)?
* range_list = (range | value) (',' range_list)* * range_list = (range | value) (',' range_list)*
* value = digit+ * value = digit+ ('.' digit+)?
* digit = 0|1|2|3|4|5|6|7|8|9 * digit = 0|1|2|3|4|5|6|7|8|9
* range = value'..'value * range = value'..'value
* \endcode * \endcode
* </pre></p> * </pre></p>
* <p> * <p>
* <p>
* The i, f, and v values are defined as follows:
* </p>
* <ul>
* <li>i to be the integer digits.</li>
* <li>f to be the visible fractional digits, as an integer.</li>
* <li>v to be the number of visible fraction digits.</li>
* <li>j is defined to only match integers. That is j is 3 fails if v != 0
(eg for 3.1 or 3.0).</li>
* </ul>
* <p>
* Examples are in the following table:
* </p>
* <table border='1' style="border-collapse:collapse">
* <tbody>
* <tr>
* <th>n</th>
* <th>i</th>
* <th>f</th>
* <th>v</th>
* </tr>
* <tr>
* <td>1.0</td>
* <td>1</td>
* <td align="right">0</td>
* <td>1</td>
* </tr>
* <tr>
* <td>1.00</td>
* <td>1</td>
* <td align="right">0</td>
* <td>2</td>
* </tr>
* <tr>
* <td>1.3</td>
* <td>1</td>
* <td align="right">3</td>
* <td>1</td>
* </tr>
* <tr>
* <td>1.03</td>
* <td>1</td>
* <td align="right">3</td>
* <td>2</td>
* </tr>
* <tr>
* <td>1.23</td>
* <td>1</td>
* <td align="right">23</td>
* <td>2</td>
* </tr>
* </tbody>
* </table>
* <p>
* The difference between 'in' and 'within' is that 'in' only includes inte
gers in the specified range, while 'within'
* includes all values. Using 'within' with a range_list consisting entirel
y of values is the same as using 'in' (it's
* not an error).
* </p>
* An "identifier" is a sequence of characters that do not have the * An "identifier" is a sequence of characters that do not have the
* Unicode Pattern_Syntax or Pattern_White_Space properties. * Unicode Pattern_Syntax or Pattern_White_Space properties.
* <p> * <p>
* The difference between 'in' and 'within' is that 'in' only includes * The difference between 'in' and 'within' is that 'in' only includes
* integers in the specified range, while 'within' includes all values.</p> * integers in the specified range, while 'within' includes all values.
* Using 'within' with a range_list consisting entirely of values is the
* same as using 'in' (it's not an error).
*</p>
* <p> * <p>
* Keywords * Keywords
* could be defined by users or from ICU locale data. There are 6 * could be defined by users or from ICU locale data. There are 6
* predefined values in ICU - 'zero', 'one', 'two', 'few', 'many' and * predefined values in ICU - 'zero', 'one', 'two', 'few', 'many' and
* 'other'. Callers need to check the value of keyword returned by * 'other'. Callers need to check the value of keyword returned by
* {@link #select} method. * {@link #select} method.
* </p> * </p>
* *
* Examples:<pre> * Examples:<pre>
* UnicodeString keyword = pl->select(number); * UnicodeString keyword = pl->select(number);
skipping to change at line 204 skipping to change at line 267
* must not indicate a failure before the function call. * must not indicate a failure before the function call.
* @return The predefined <code>PluralRules</code> object pointe r for * @return The predefined <code>PluralRules</code> object pointe r for
* this locale. If there's no predefined rules for this locale, * this locale. If there's no predefined rules for this locale,
* the rules for the closest parent in the locale hierar chy * the rules for the closest parent in the locale hierar chy
* that has one will be returned. The final fallback a lways * that has one will be returned. The final fallback a lways
* returns the default 'other' rules. * returns the default 'other' rules.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
static PluralRules* U_EXPORT2 forLocale(const Locale& locale, UErrorCod e& status); static PluralRules* U_EXPORT2 forLocale(const Locale& locale, UErrorCod e& status);
#ifndef U_HIDE_DRAFT_API
/** /**
* Provides access to the predefined <code>PluralRules</code> for a giv en * Provides access to the predefined <code>PluralRules</code> for a giv en
* locale and the plural type. * locale and the plural type.
* *
* @param locale The locale for which a <code>PluralRules</code> objec t is * @param locale The locale for which a <code>PluralRules</code> objec t is
* returned. * returned.
* @param type The plural type (e.g., cardinal or ordinal). * @param type The plural type (e.g., cardinal or ordinal).
* @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.
* @return The predefined <code>PluralRules</code> object pointe r for * @return The predefined <code>PluralRules</code> object pointe r for
* this locale. If there's no predefined rules for this locale, * this locale. If there's no predefined rules for this locale,
* the rules for the closest parent in the locale hierar chy * the rules for the closest parent in the locale hierar chy
* that has one will be returned. The final fallback a lways * that has one will be returned. The final fallback a lways
* returns the default 'other' rules. * returns the default 'other' rules.
* @draft ICU 50 * @stable ICU 50
*/ */
static PluralRules* U_EXPORT2 forLocale(const Locale& locale, UPluralTy pe type, UErrorCode& status); static PluralRules* U_EXPORT2 forLocale(const Locale& locale, UPluralTy pe type, UErrorCode& status);
#endif /* U_HIDE_DRAFT_API */
#ifndef U_HIDE_INTERNAL_API
/**
* Return a StringEnumeration over the locales for which there is plura
ls data.
* @return a StringEnumeration over the locales available.
* @internal
*/
static StringEnumeration* U_EXPORT2 getAvailableLocales(UErrorCode &sta
tus);
/**
* Returns whether or not there are overrides.
* @param locale the locale to check.
* @return
* @internal
*/
static UBool hasOverride(const Locale &locale);
#endif /* U_HIDE_INTERNAL_API */
/** /**
* Given a number, returns the keyword of the first rule that applies t o * Given a number, returns the keyword of the first rule that applies t o
* the number. This function can be used with isKeyword* functions to * the number. This function can be used with isKeyword* functions to
* determine the keyword for default plural rules. * determine the keyword for default plural rules.
* *
* @param number The number for which the rule has to be determined. * @param number The number for which the rule has to be determined.
* @return The keyword of the selected rule. * @return The keyword of the selected rule.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
skipping to change at line 246 skipping to change at line 324
* Given a number, returns the keyword of the first rule that applies t o * Given a number, returns the keyword of the first rule that applies t o
* the number. This function can be used with isKeyword* functions to * the number. This function can be used with isKeyword* functions to
* determine the keyword for default plural rules. * determine the keyword for default plural rules.
* *
* @param number The number for which the rule has to be determined. * @param number The number for which the rule has to be determined.
* @return The keyword of the selected rule. * @return The keyword of the selected rule.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
UnicodeString select(double number) const; UnicodeString select(double number) const;
#ifndef U_HIDE_INTERNAL_API
/**
* @internal
*/
UnicodeString select(const FixedDecimal &number) const;
#endif /* U_HIDE_INTERNAL_API */
/** /**
* Returns a list of all rule keywords used in this <code>PluralRules</ code> * Returns a list of all rule keywords used in this <code>PluralRules</ code>
* object. The rule 'other' is always present by default. * object. The rule 'other' is always present by default.
* *
* @param status Output param set to success/failure code on exit, whic h * @param status Output param set to success/failure code on exit, whic h
* must not indicate a failure before the function call. * must not indicate a failure before the function call.
* @return StringEnumeration with the keywords. * @return StringEnumeration with the keywords.
* The caller must delete the object. * The caller must delete the object.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
skipping to change at line 333 skipping to change at line 418
UBool isKeyword(const UnicodeString& keyword) const; UBool isKeyword(const UnicodeString& keyword) const;
/** /**
* Returns keyword for default plural form. * Returns keyword for default plural form.
* *
* @return keyword for default plural form. * @return keyword for default plural form.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
UnicodeString getKeywordOther() const; UnicodeString getKeywordOther() const;
#ifndef U_HIDE_INTERNAL_API
/**
*
* @internal
*/
UnicodeString getRules() const;
#endif /* U_HIDE_INTERNAL_API */
/** /**
* Compares the equality of two PluralRules objects. * Compares the equality of two PluralRules objects.
* *
* @param other The other PluralRules object to be compared with. * @param other The other PluralRules object to be compared with.
* @return True if the given PluralRules is the same as this * @return True if the given PluralRules is the same as this
* PluralRules; false otherwise. * PluralRules; false otherwise.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
virtual UBool operator==(const PluralRules& other) const; virtual UBool operator==(const PluralRules& other) const;
skipping to change at line 370 skipping to change at line 463
/** /**
* ICU "poor man's RTTI", returns a UClassID for the actual class. * ICU "poor man's RTTI", returns a UClassID for the actual class.
* *
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
virtual UClassID getDynamicClassID() const; virtual UClassID getDynamicClassID() const;
private: private:
RuleChain *mRules; RuleChain *mRules;
RuleParser *mParser;
double *mSamples;
int32_t *mSampleInfo;
int32_t mSampleInfoCount;
PluralRules(); // default constructor not implemented PluralRules(); // default constructor not implemented
int32_t getRepeatLimit() const; void parseDescription(const UnicodeString& ruleData, UErrorC
void parseDescription(UnicodeString& ruleData, RuleChain& rules, UError ode &status);
Code &status); int32_t getNumberValue(const UnicodeString& token) const;
void getNextLocale(const UnicodeString& localeData, int32_t* curIndex, UnicodeString getRuleFromResource(const Locale& locale, UPluralType t
UnicodeString& localeName); ype, UErrorCode& status);
void addRules(RuleChain& rules); RuleChain *rulesForKeyword(const UnicodeString &keyword) const;
int32_t getNumberValue(const UnicodeString& token) const;
UnicodeString getRuleFromResource(const Locale& locale, UPluralType typ
e, UErrorCode& status);
static const int32_t MAX_SAMPLES = 3;
int32_t getSamplesInternal(const UnicodeString &keyword, double *dest,
int32_t destCapacity, UBool includeUnlimited
,
UErrorCode& status);
int32_t getKeywordIndex(const UnicodeString& keyword,
UErrorCode& status) const;
void initSamples(UErrorCode& status);
friend class PluralRuleParser;
}; };
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif // _PLURRULE #endif // _PLURRULE
//eof //eof
 End of changes. 15 change blocks. 
30 lines changed or deleted 112 lines changed or added


 rbbi.h   rbbi.h 
skipping to change at line 577 skipping to change at line 577
* *
* Base* polymorphic_pointer = createPolymorphicObject(); * Base* polymorphic_pointer = createPolymorphicObject();
* if (polymorphic_pointer->getDynamicClassID() == * if (polymorphic_pointer->getDynamicClassID() ==
* Derived::getStaticClassID()) ... * Derived::getStaticClassID()) ...
* *
* @return The class ID for all objects of this class. * @return The class ID for all objects of this class.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
static UClassID U_EXPORT2 getStaticClassID(void); static UClassID U_EXPORT2 getStaticClassID(void);
/* /**
* Deprecated functionality. Use clone() instead.
*
* Create a clone (copy) of this break iterator in memory provided * Create a clone (copy) of this break iterator in memory provided
* by the caller. The idea is to increase performance by avoiding * by the caller. The idea is to increase performance by avoiding
* a storage allocation. Use of this functoin is NOT RECOMMENDED. * a storage allocation. Use of this functoin is NOT RECOMMENDED.
* Performance gains are minimal, and correct buffer management is * Performance gains are minimal, and correct buffer management is
* tricky. Use clone() instead. * tricky. Use clone() instead.
* *
* @param stackBuffer The pointer to the memory into which the cloned object * @param stackBuffer The pointer to the memory into which the cloned object
* should be placed. If NULL, allocate heap memor y * should be placed. If NULL, allocate heap memor y
* for the cloned object. * for the cloned object.
* @param BufferSize The size of the buffer. If zero, return the req uired * @param BufferSize The size of the buffer. If zero, return the req uired
skipping to change at line 599 skipping to change at line 601
* size was too small (but not zero), allocate heap * size was too small (but not zero), allocate heap
* storage for the cloned object. * storage for the cloned object.
* *
* @param status Error status. U_SAFECLONE_ALLOCATED_WARNING wil l be * @param status Error status. U_SAFECLONE_ALLOCATED_WARNING wil l be
* returned if the the provided buffer was too smal l, and * returned if the the provided buffer was too smal l, and
* the clone was therefore put on the heap. * the clone was therefore put on the heap.
* *
* @return Pointer to the clone object. This may differ from the stac kBuffer * @return Pointer to the clone object. This may differ from the stac kBuffer
* address if the byte alignment of the stack buffer was not s uitable * address if the byte alignment of the stack buffer was not s uitable
* or if the stackBuffer was too small to hold the clone. * or if the stackBuffer was too small to hold the clone.
* @stable ICU 2.0 * @deprecated ICU 52. Use clone() instead.
*/ */
virtual BreakIterator * createBufferClone(void *stackBuffer, virtual BreakIterator * createBufferClone(void *stackBuffer,
int32_t &BufferSize, int32_t &BufferSize,
UErrorCode &status); UErrorCode &status);
/** /**
* Return the binary form of compiled break rules, * Return the binary form of compiled break rules,
* which can then be used to create a new break iterator at some * which can then be used to create a new break iterator at some
* time in the future. Creating a break iterator from pre-compiled rul es * time in the future. Creating a break iterator from pre-compiled rul es
* is much faster than building one from the source form of the * is much faster than building one from the source form of the
skipping to change at line 689 skipping to change at line 691
/** /**
* Set the type of the break iterator. * Set the type of the break iterator.
* @internal * @internal
*/ */
virtual void setBreakType(int32_t type); virtual void setBreakType(int32_t type);
#ifndef U_HIDE_INTERNAL_API #ifndef U_HIDE_INTERNAL_API
/** /**
* Common initialization function, used by constructors and bufferClon e. * Common initialization function, used by constructors and bufferClon e.
* (Also used by DictionaryBasedBreakIterator::createBufferClone().)
* @internal * @internal
*/ */
void init(); void init();
#endif /* U_HIDE_INTERNAL_API */ #endif /* U_HIDE_INTERNAL_API */
private: private:
/** /**
* This method backs the iterator back up to a "safe position" in the t ext. * This method backs the iterator back up to a "safe position" in the t ext.
* This is a position that we know, without any context, must be a brea k position. * This is a position that we know, without any context, must be a brea k position.
 End of changes. 3 change blocks. 
3 lines changed or deleted 4 lines changed or added


 rbnf.h   rbnf.h 
skipping to change at line 810 skipping to change at line 810
* @param status the status * @param status the status
* @return A textual representation of the number. * @return A textual representation of the number.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual UnicodeString& format(double number, virtual UnicodeString& format(double number,
const UnicodeString& ruleSetName, const UnicodeString& ruleSetName,
UnicodeString& toAppendTo, UnicodeString& toAppendTo,
FieldPosition& pos, FieldPosition& pos,
UErrorCode& status) const; UErrorCode& status) const;
/** using NumberFormat::parse;
* Formats the specified number using the default ruleset.
* @param obj The number to format.
* @param toAppendTo the string that will hold the (appended) result
* @param pos the fieldposition
* @param status the status
* @return A textual representation of the number.
* @stable ICU 2.0
*/
virtual UnicodeString& format(const Formattable& obj,
UnicodeString& toAppendTo,
FieldPosition& pos,
UErrorCode& status) const;
/**
* Redeclared Format method.
* @param obj the object to be formatted.
* @param result Output param which will receive the formatted string.
* @param status Output param set to success/failure code
* @return A reference to 'result'.
* @stable ICU 2.0
*/
UnicodeString& format(const Formattable& obj,
UnicodeString& result,
UErrorCode& status) const;
/**
* Redeclared NumberFormat method.
* @param number the double value to be formatted.
* @param output Output param which will receive the formatted string.
* @return A reference to 'output'.
* @stable ICU 2.0
*/
UnicodeString& format(double number,
UnicodeString& output) const;
/**
* Redeclared NumberFormat method.
* @param number the long value to be formatted.
* @param output Output param which will receive the formatted string.
* @return A reference to 'output'.
* @stable ICU 2.0
*/
UnicodeString& format(int32_t number,
UnicodeString& output) const;
/** /**
* Parses the specfied string, beginning at the specified position, accor ding * Parses the specfied string, beginning at the specified position, accor ding
* to this formatter's rules. This will match the string against all of the * to this formatter's rules. This will match the string against all of the
* formatter's public rule sets and return the value corresponding to the longest * formatter's public rule sets and return the value corresponding to the longest
* parseable substring. This function's behavior is affected by the leni ent * parseable substring. This function's behavior is affected by the leni ent
* parse mode. * parse mode.
* @param text The string to parse * @param text The string to parse
* @param result the result of the parse, either a double or a long. * @param result the result of the parse, either a double or a long.
* @param parsePosition On entry, contains the position of the first char acter * @param parsePosition On entry, contains the position of the first char acter
* in "text" to examine. On exit, has been updated to contain the positi on * in "text" to examine. On exit, has been updated to contain the positi on
* of the first character in "text" that wasn't consumed by the parse. * of the first character in "text" that wasn't consumed by the parse.
* @see #setLenient * @see #setLenient
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual void parse(const UnicodeString& text, virtual void parse(const UnicodeString& text,
Formattable& result, Formattable& result,
ParsePosition& parsePosition) const; ParsePosition& parsePosition) const;
/**
* Redeclared Format method.
* @param text The string to parse
* @param result the result of the parse, either a double or a long.
* @param status Output param set to failure code when a problem occurs.
* @stable ICU 2.0
*/
virtual inline void parse(const UnicodeString& text,
Formattable& result,
UErrorCode& status) const;
#if !UCONFIG_NO_COLLATION #if !UCONFIG_NO_COLLATION
/** /**
* Turns lenient parse mode on and off. * Turns lenient parse mode on and off.
* *
* When in lenient parse mode, the formatter uses a Collator for parsing the text. * When in lenient parse mode, the formatter uses a Collator for parsing the text.
* Only primary differences are treated as significant. This means that case * Only primary differences are treated as significant. This means that case
* differences, accent differences, alternate spellings of the same lette r * differences, accent differences, alternate spellings of the same lette r
* (e.g., ae and a-umlaut in German), ignorable characters, etc. are igno red in * (e.g., ae and a-umlaut in German), ignorable characters, etc. are igno red in
* matching the text. In many cases, numerals will be accepted in place of words * matching the text. In many cases, numerals will be accepted in place of words
skipping to change at line 1025 skipping to change at line 971
Locale locale; Locale locale;
Collator* collator; Collator* collator;
DecimalFormatSymbols* decimalFormatSymbols; DecimalFormatSymbols* decimalFormatSymbols;
UBool lenient; UBool lenient;
UnicodeString* lenientParseRules; UnicodeString* lenientParseRules;
LocalizationInfo* localizations; LocalizationInfo* localizations;
}; };
// --------------- // ---------------
inline UnicodeString&
RuleBasedNumberFormat::format(const Formattable& obj,
UnicodeString& result,
UErrorCode& status) const
{
// Don't use Format:: - use immediate base class only,
// in case immediate base modifies behavior later.
// dlf - the above comment is bogus, if there were a reason to modify
// it, it would be virtual, and there's no reason because it is
// a one-line macro in NumberFormat anyway, just like this one.
return NumberFormat::format(obj, result, status);
}
inline UnicodeString&
RuleBasedNumberFormat::format(double number, UnicodeString& output) const {
FieldPosition pos(0);
return format(number, output, pos);
}
inline UnicodeString&
RuleBasedNumberFormat::format(int32_t number, UnicodeString& output) const
{
FieldPosition pos(0);
return format(number, output, pos);
}
inline void
RuleBasedNumberFormat::parse(const UnicodeString& text, Formattable& result
, UErrorCode& status) const
{
NumberFormat::parse(text, result, status);
}
#if !UCONFIG_NO_COLLATION #if !UCONFIG_NO_COLLATION
inline UBool inline UBool
RuleBasedNumberFormat::isLenient(void) const { RuleBasedNumberFormat::isLenient(void) const {
return lenient; return lenient;
} }
#endif #endif
inline NFRuleSet* inline NFRuleSet*
 End of changes. 3 change blocks. 
88 lines changed or deleted 1 lines changed or added


 regex.h   regex.h 
skipping to change at line 370 skipping to change at line 370
* Cause a compilation error if an application accidentally attempts to * Cause a compilation error if an application accidentally attempts to
* create a matcher with a (UChar *) string as input rather than * create a matcher with a (UChar *) string as input rather than
* a UnicodeString. Avoids a dangling reference to a temporary strin g. * a UnicodeString. Avoids a dangling reference to a temporary strin g.
* <p> * <p>
* To efficiently work with UChar *strings, wrap the data in a UnicodeS tring * To efficiently work with UChar *strings, wrap the data in a UnicodeS tring
* using one of the aliasing constructors, such as * using one of the aliasing constructors, such as
* <code>UnicodeString(UBool isTerminated, const UChar *text, int32_t t extLength);</code> * <code>UnicodeString(UBool isTerminated, const UChar *text, int32_t t extLength);</code>
* or in a UText, using * or in a UText, using
* <code>utext_openUChars(UText *ut, const UChar *text, int64_t textLen gth, UErrorCode *status);</code> * <code>utext_openUChars(UText *ut, const UChar *text, int64_t textLen gth, UErrorCode *status);</code>
* *
* @internal
*/ */
RegexMatcher *matcher(const UChar *input, RegexMatcher *matcher(const UChar *input,
UErrorCode &status) const; UErrorCode &status) const;
public: public:
/** /**
* Creates a RegexMatcher that will match against this pattern. The * Creates a RegexMatcher that will match against this pattern. The
* RegexMatcher can be used to perform match, find or replace operations . * RegexMatcher can be used to perform match, find or replace operations .
* Note that a RegexPattern object must not be deleted while * Note that a RegexPattern object must not be deleted while
* RegexMatchers created from it still exist and might possibly be used again. * RegexMatchers created from it still exist and might possibly be used again.
skipping to change at line 719 skipping to change at line 718
* Cause a compilation error if an application accidentally attempts to * Cause a compilation error if an application accidentally attempts to
* create a matcher with a (UChar *) string as input rather than * create a matcher with a (UChar *) string as input rather than
* a UnicodeString. Avoids a dangling reference to a temporary str ing. * a UnicodeString. Avoids a dangling reference to a temporary str ing.
* <p> * <p>
* To efficiently work with UChar *strings, wrap the data in a UnicodeS tring * To efficiently work with UChar *strings, wrap the data in a UnicodeS tring
* using one of the aliasing constructors, such as * using one of the aliasing constructors, such as
* <code>UnicodeString(UBool isTerminated, const UChar *text, int32_t t extLength);</code> * <code>UnicodeString(UBool isTerminated, const UChar *text, int32_t t extLength);</code>
* or in a UText, using * or in a UText, using
* <code>utext_openUChars(UText *ut, const UChar *text, int64_t textLen gth, UErrorCode *status);</code> * <code>utext_openUChars(UText *ut, const UChar *text, int64_t textLen gth, UErrorCode *status);</code>
* *
* @internal
*/ */
RegexMatcher(const UnicodeString &regexp, const UChar *input, RegexMatcher(const UnicodeString &regexp, const UChar *input,
uint32_t flags, UErrorCode &status); uint32_t flags, UErrorCode &status);
public: public:
/** /**
* Destructor. * Destructor.
* *
* @stable ICU 2.4 * @stable ICU 2.4
*/ */
skipping to change at line 1104 skipping to change at line 1102
* Cause a compilation error if an application accidentally attempts to * Cause a compilation error if an application accidentally attempts to
* reset a matcher with a (UChar *) string as input rather than * reset a matcher with a (UChar *) string as input rather than
* a UnicodeString. Avoids a dangling reference to a temporary str ing. * a UnicodeString. Avoids a dangling reference to a temporary str ing.
* <p> * <p>
* To efficiently work with UChar *strings, wrap the data in a UnicodeS tring * To efficiently work with UChar *strings, wrap the data in a UnicodeS tring
* using one of the aliasing constructors, such as * using one of the aliasing constructors, such as
* <code>UnicodeString(UBool isTerminated, const UChar *text, int32_t t extLength);</code> * <code>UnicodeString(UBool isTerminated, const UChar *text, int32_t t extLength);</code>
* or in a UText, using * or in a UText, using
* <code>utext_openUChars(UText *ut, const UChar *text, int64_t textLen gth, UErrorCode *status);</code> * <code>utext_openUChars(UText *ut, const UChar *text, int64_t textLen gth, UErrorCode *status);</code>
* *
* @internal
*/ */
RegexMatcher &reset(const UChar *input); RegexMatcher &reset(const UChar *input);
public: public:
/** /**
* Returns the input string being matched. Ownership of the string be longs to * Returns the input string being matched. Ownership of the string be longs to
* the matcher; it should not be altered or deleted. This method will work even if the input * the matcher; it should not be altered or deleted. This method will work even if the input
* was originally supplied as a UText. * was originally supplied as a UText.
* @return the input string * @return the input string
* @stable ICU 2.4 * @stable ICU 2.4
 End of changes. 3 change blocks. 
3 lines changed or deleted 0 lines changed or added


 region.h   region.h 
/* /*
************************************************************************** ***** ************************************************************************** *****
* Copyright (C) 2013, International Business Machines Corporation * Copyright (C) 2013, International Business Machines Corporation and othe rs.
* All Rights Reserved. * All Rights Reserved.
************************************************************************** ***** ************************************************************************** *****
*/ */
#ifndef REGION_H #ifndef REGION_H
#define REGION_H #define REGION_H
/** /**
* \file * \file
* \brief C++ API: Region classes (territory containment) * \brief C++ API: Region classes (territory containment)
*/ */
#include "unicode/utypes.h" #include "unicode/utypes.h"
#include "unicode/uregion.h"
#ifndef U_HIDE_DRAFT_API
/**
* URegionType is an enumeration defining the different types of regions.
Current possible
* values are URGN_WORLD, URGN_CONTINENT, URGN_SUBCONTINENT, URGN_TERRITORY
, URGN_GROUPING,
* URGN_DEPRECATED, and URGN_UNKNOWN.
*
* @draft ICU 51
*/
typedef enum URegionType {
/**
* Type representing the unknown region.
* @draft ICU 51
*/
URGN_UNKNOWN,
/**
* Type representing a territory.
* @draft ICU 51
*/
URGN_TERRITORY,
/**
* Type representing the whole world.
* @draft ICU 51
*/
URGN_WORLD,
/**
* Type representing a continent.
* @draft ICU 51
*/
URGN_CONTINENT,
/**
* Type representing a sub-continent.
* @draft ICU 51
*/
URGN_SUBCONTINENT,
/**
* Type representing a grouping of territories that is not to be used i
n
* the normal WORLD/CONTINENT/SUBCONTINENT/TERRITORY containment tree.
* @draft ICU 51
*/
URGN_GROUPING,
/**
* Type representing a region whose code has been deprecated, usually
* due to a country splitting into multiple territories or changing its
name.
* @draft ICU 51
*/
URGN_DEPRECATED,
/**
* Maximum value for this unumeration.
* @draft ICU 51
*/
URGN_LIMIT
} URegionType;
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
#ifndef U_HIDE_DRAFT_API
#include "unicode/uobject.h" #include "unicode/uobject.h"
#include "unicode/uniset.h" #include "unicode/uniset.h"
#include "unicode/unistr.h" #include "unicode/unistr.h"
#include "unicode/strenum.h" #include "unicode/strenum.h"
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
/** /**
* <code>Region</code> is the class representing a Unicode Region Code, als o known as a * <code>Region</code> is the class representing a Unicode Region Code, als o known as a
skipping to change at line 260 skipping to change at line 201
char id[4]; char id[4];
UnicodeString idStr; UnicodeString idStr;
int32_t code; int32_t code;
URegionType type; URegionType type;
Region *containingRegion; Region *containingRegion;
UVector *containedRegions; UVector *containedRegions;
UVector *preferredValues; UVector *preferredValues;
/** /**
* Default Constructor. Internal - use factory methods only. * Default Constructor. Internal - use factory methods only.
*
* @internal
*/ */
Region(); Region();
/* /*
* Initializes the region data from the ICU resource bundles. The regi on data * Initializes the region data from the ICU resource bundles. The regi on data
* contains the basic relationships such as which regions are known, wh at the numeric * contains the basic relationships such as which regions are known, wh at the numeric
* codes are, any known aliases, and the territory containment data. * codes are, any known aliases, and the territory containment data.
* *
* If the region data has already loaded, then this method simply retur ns without doing * If the region data has already loaded, then this method simply retur ns without doing
* anything meaningful. * anything meaningful.
* @internal
*/ */
static void loadRegionData(); static void loadRegionData();
}; };
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */
#endif /* U_HIDE_DRAFT_API */ #endif /* U_HIDE_DRAFT_API */
#endif /* #if !UCONFIG_NO_FORMATTING */
#endif // REGION_H #endif // REGION_H
//eof //eof
 End of changes. 7 change blocks. 
70 lines changed or deleted 4 lines changed or added


 resbund.h   resbund.h 
/* /*
*************************************************************************** *** *************************************************************************** ***
* *
* Copyright (C) 1996-2011, International Business Machines Corporation * Copyright (C) 1996-2013, International Business Machines Corporation
* and others. All Rights Reserved. * and others. All Rights Reserved.
* *
*************************************************************************** *** *************************************************************************** ***
* *
* File resbund.h * File resbund.h
* *
* CREATED BY * CREATED BY
* Richard Gillam * Richard Gillam
* *
* Modification History: * Modification History:
skipping to change at line 485 skipping to change at line 485
* @stable ICU 2.2 * @stable ICU 2.2
*/ */
static UClassID U_EXPORT2 getStaticClassID(); static UClassID U_EXPORT2 getStaticClassID();
private: private:
ResourceBundle(); // default constructor not implemented ResourceBundle(); // default constructor not implemented
UResourceBundle *fResource; UResourceBundle *fResource;
void constructForLocale(const UnicodeString& path, const Locale& locale , UErrorCode& error); void constructForLocale(const UnicodeString& path, const Locale& locale , UErrorCode& error);
Locale *fLocale; Locale *fLocale;
}; };
U_NAMESPACE_END U_NAMESPACE_END
#endif #endif
 End of changes. 2 change blocks. 
2 lines changed or deleted 1 lines changed or added


 smpdtfmt.h   smpdtfmt.h 
skipping to change at line 68 skipping to change at line 68
* program is running in. However, if the client needs something more unus ual than * program is running in. However, if the client needs something more unus ual than
* the default patterns in the locales, he can construct a SimpleDateFormat directly * the default patterns in the locales, he can construct a SimpleDateFormat directly
* and give it an appropriate pattern (or use one of the factory methods on DateFormat * and give it an appropriate pattern (or use one of the factory methods on DateFormat
* and modify the pattern after the fact with toPattern() and applyPattern( ). * and modify the pattern after the fact with toPattern() and applyPattern( ).
* *
* <p><strong>Date and Time Patterns:</strong></p> * <p><strong>Date and Time Patterns:</strong></p>
* *
* <p>Date and time formats are specified by <em>date and time pattern</em> strings. * <p>Date and time formats are specified by <em>date and time pattern</em> strings.
* Within date and time pattern strings, all unquoted ASCII letters [A-Za-z ] are reserved * Within date and time pattern strings, all unquoted ASCII letters [A-Za-z ] are reserved
* as pattern letters representing calendar fields. <code>SimpleDateFormat< /code> supports * as pattern letters representing calendar fields. <code>SimpleDateFormat< /code> supports
* the date and time formatting algorithm and pattern letters defined by <a * the date and time formatting algorithm and pattern letters defined by
href="http://www.unicode.org/reports/tr35/">UTS#35 * <a href="http://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_
* Unicode Locale Data Markup Language (LDML)</a>. The following pattern le Symbol_Table">UTS#35
tters are * Unicode Locale Data Markup Language (LDML)</a> and further documented fo
* currently available:</p> r ICU in the
* <a href="https://sites.google.com/site/icuprojectuserguide/formatparse/d
atetime?pli=1#TOC-Date-Field-Symbol-Table">ICU
* User Guide</a>. The following pattern letters are currently available:</
p>
* *
* <table border="1"> * <table border="1">
* <tr> * <tr>
* <th>Field</th> * <th>Field</th>
* <th style="text-align: center">Sym.</th> * <th style="text-align: center">Sym.</th>
* <th style="text-align: center">No.</th> * <th style="text-align: center">No.</th>
* <th>Example</th> * <th>Example</th>
* <th>Description</th> * <th>Description</th>
* </tr> * </tr>
* <tr> * <tr>
skipping to change at line 903 skipping to change at line 905
* are defined in UDateFormatField. * are defined in UDateFormatField.
* @param status Input/output param set to success/failure code. * @param status Input/output param set to success/failure code.
* @return Reference to 'appendTo' parameter. * @return Reference to 'appendTo' parameter.
* @stable ICU 4.4 * @stable ICU 4.4
*/ */
virtual UnicodeString& format( Calendar& cal, virtual UnicodeString& format( Calendar& cal,
UnicodeString& appendTo, UnicodeString& appendTo,
FieldPositionIterator* posIter, FieldPositionIterator* posIter,
UErrorCode& status) const; UErrorCode& status) const;
/** using DateFormat::parse;
* Format a date or time, which is the standard millis since 24:00 GMT,
Jan
* 1, 1970. Overrides DateFormat pure virtual method.
* <P>
* Example: using the US locale: "yyyy.MM.dd e 'at' HH:mm:ss zzz" ->>
* 1996.07.10 AD at 15:08:56 PDT
*
* @param obj A Formattable containing the date-time value to be
formatted
* into a date-time string. If the type of the Format
table
* is a numeric type, it is treated as if it were an
* instance of Date.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param pos The formatting position. On input: an alignment fie
ld,
* if desired. On output: the offsets of the alignment
field.
* @param status Input/output param set to success/failure code.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.0
*/
virtual UnicodeString& format( const Formattable& obj,
UnicodeString& appendTo,
FieldPosition& pos,
UErrorCode& status) const;
/**
* Format a date or time, which is the standard millis since 24:00 GMT,
Jan
* 1, 1970. Overrides DateFormat pure virtual method.
* <P>
* Example: using the US locale: "yyyy.MM.dd e 'at' HH:mm:ss zzz" ->>
* 1996.07.10 AD at 15:08:56 PDT
*
* @param obj A Formattable containing the date-time value to be
formatted
* into a date-time string. If the type of the Format
table
* is a numeric type, it is treated as if it were an
* instance of Date.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param posIter On return, can be used to iterate over positions
* of fields generated by this format call. Field val
ues
* are defined in UDateFormatField.
* @param status Input/output param set to success/failure code.
* @return Reference to 'appendTo' parameter.
* @stable ICU 4.4
*/
virtual UnicodeString& format( const Formattable& obj,
UnicodeString& appendTo,
FieldPositionIterator* posIter,
UErrorCode& status) const;
/**
* Redeclared DateFormat method.
* @param date the Date value to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param fieldPosition The formatting position. On input: an alignment
field,
* if desired. On output: the offsets of the align
ment field.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.1
*/
UnicodeString& format(UDate date,
UnicodeString& appendTo,
FieldPosition& fieldPosition) const;
/**
* Redeclared DateFormat method.
* @param date the Date value to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param posIter On return, can be used to iterate over position
s
* of fields generated by this format call. Field
values
* are defined in UDateFormatField.
* @param status Input/output param set to success/failure code.
* @return Reference to 'appendTo' parameter.
* @stable ICU 4.4
*/
UnicodeString& format(UDate date,
UnicodeString& appendTo,
FieldPositionIterator* posIter,
UErrorCode& status) const;
/**
* Redeclared DateFormat method.
* @param obj Object to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @param status Input/output success/failure code.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.0
*/
UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const;
/**
* Redeclared DateFormat method.
* @param date Date value to be formatted.
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @return Reference to 'appendTo' parameter.
* @stable ICU 2.0
*/
UnicodeString& format(UDate date, UnicodeString& appendTo) const;
/** /**
* Parse a date/time string beginning at the given parse position. For * Parse a date/time string beginning at the given parse position. For
* example, a time text "07/10/96 4:5 PM, PDT" will be parsed into a Da te * example, a time text "07/10/96 4:5 PM, PDT" will be parsed into a Da te
* that is equivalent to Date(837039928046). * that is equivalent to Date(837039928046).
* <P> * <P>
* By default, parsing is lenient: If the input is not in the form used by * By default, parsing is lenient: If the input is not in the form used by
* this object's format method but can still be parsed as a date, then the * this object's format method but can still be parsed as a date, then the
* parse succeeds. Clients may insist on strict adherence to the format by * parse succeeds. Clients may insist on strict adherence to the format by
* calling setLenient(false). * calling setLenient(false).
skipping to change at line 1037 skipping to change at line 938
* @param pos On input, the position at which to start parsing; on * @param pos On input, the position at which to start parsing; on
* output, the position at which parsing terminated, or th e * output, the position at which parsing terminated, or th e
* start position if the parse failed. * start position if the parse failed.
* @stable ICU 2.1 * @stable ICU 2.1
*/ */
virtual void parse( const UnicodeString& text, virtual void parse( const UnicodeString& text,
Calendar& cal, Calendar& cal,
ParsePosition& pos) const; ParsePosition& pos) const;
/** /**
* Parse a date/time string starting at the given parse position. For
* example, a time text "07/10/96 4:5 PM, PDT" will be parsed into a Da
te
* that is equivalent to Date(837039928046).
* <P>
* By default, parsing is lenient: If the input is not in the form used
by
* this object's format method but can still be parsed as a date, then
the
* parse succeeds. Clients may insist on strict adherence to the format
by
* calling setLenient(false).
* @see DateFormat::setLenient(boolean)
* <P>
* Note that the normal date formats associated with some calendars - s
uch
* as the Chinese lunar calendar - do not specify enough fields to enab
le
* dates to be parsed unambiguously. In the case of the Chinese lunar
* calendar, while the year within the current 60-year cycle is specifi
ed,
* the number of such cycles since the start date of the calendar (in t
he
* ERA field of the Calendar object) is not normally part of the format
,
* and parsing may assume the wrong era. For cases such as this it is
* recommended that clients parse using the method
* parse(const UnicodeString&, Calendar& cal, ParsePosition&)
* with the Calendar passed in set to the current date, or to a date
* within the era/cycle that should be assumed if absent in the format.
*
* @param text The date/time string to be parsed
* @param pos On input, the position at which to start parsing; on
* output, the position at which parsing terminated, or th
e
* start position if the parse failed.
* @return A valid UDate if the input could be parsed.
* @stable ICU 2.0
*/
UDate parse( const UnicodeString& text,
ParsePosition& pos) const;
/**
* Parse a date/time string. For example, a time text "07/10/96 4:5 PM,
PDT"
* will be parsed into a UDate that is equivalent to Date(837039928046)
.
* Parsing begins at the beginning of the string and proceeds as far as
* possible. Assuming no parse errors were encountered, this function
* doesn't return any information about how much of the string was cons
umed
* by the parsing. If you need that information, use the version of
* parse() that takes a ParsePosition.
* <P>
* By default, parsing is lenient: If the input is not in the form used
by
* this object's format method but can still be parsed as a date, then
the
* parse succeeds. Clients may insist on strict adherence to the format
by
* calling setLenient(false).
* @see DateFormat::setLenient(boolean)
* <P>
* Note that the normal date formats associated with some calendars - s
uch
* as the Chinese lunar calendar - do not specify enough fields to enab
le
* dates to be parsed unambiguously. In the case of the Chinese lunar
* calendar, while the year within the current 60-year cycle is specifi
ed,
* the number of such cycles since the start date of the calendar (in t
he
* ERA field of the Calendar object) is not normally part of the format
,
* and parsing may assume the wrong era. For cases such as this it is
* recommended that clients parse using the method
* parse(const UnicodeString&, Calendar& cal, ParsePosition&)
* with the Calendar passed in set to the current date, or to a date
* within the era/cycle that should be assumed if absent in the format.
*
* @param text The date/time string to be parsed into a UDate value.
* @param status Filled in with U_ZERO_ERROR if the parse was successfu
l, and with
* an error value if there was a parse error.
* @return A valid UDate if the input could be parsed.
* @stable ICU 2.0
*/
virtual UDate parse( const UnicodeString& text,
UErrorCode& status) const;
/**
* Set the start UDate used to interpret two-digit year strings. * Set the start UDate used to interpret two-digit year strings.
* When dates are parsed having 2-digit year strings, they are placed w ithin * When dates are parsed having 2-digit year strings, they are placed w ithin
* a assumed range of 100 years starting on the two digit start date. For * a assumed range of 100 years starting on the two digit start date. For
* example, the string "24-Jan-17" may be in the year 1817, 1917, 2017, or * example, the string "24-Jan-17" may be in the year 1817, 1917, 2017, or
* some other year. SimpleDateFormat chooses a year so that the result ant * some other year. SimpleDateFormat chooses a year so that the result ant
* date is on or after the two digit start date and within 100 years of the * date is on or after the two digit start date and within 100 years of the
* two digit start date. * two digit start date.
* <P> * <P>
* By default, the two digit start date is set to 80 years before the c urrent * By default, the two digit start date is set to 80 years before the c urrent
* time at which a SimpleDateFormat object is created. * time at which a SimpleDateFormat object is created.
skipping to change at line 1713 skipping to change at line 1545
UDisplayContext fCapitalizationContext; UDisplayContext fCapitalizationContext;
}; };
inline UDate inline UDate
SimpleDateFormat::get2DigitYearStart(UErrorCode& /*status*/) const SimpleDateFormat::get2DigitYearStart(UErrorCode& /*status*/) const
{ {
return fDefaultCenturyStart; return fDefaultCenturyStart;
} }
inline UnicodeString&
SimpleDateFormat::format(const Formattable& obj,
UnicodeString& appendTo,
UErrorCode& status) const {
// Don't use Format:: - use immediate base class only,
// in case immediate base modifies behavior later.
return DateFormat::format(obj, appendTo, status);
}
inline UnicodeString&
SimpleDateFormat::format(const Formattable& obj,
UnicodeString& appendTo,
FieldPosition& pos,
UErrorCode& status) const
{
// Don't use Format:: - use immediate base class only,
// in case immediate base modifies behavior later.
return DateFormat::format(obj, appendTo, pos, status);
}
inline UnicodeString&
SimpleDateFormat::format(const Formattable& obj,
UnicodeString& appendTo,
FieldPositionIterator* posIter,
UErrorCode& status) const
{
// Don't use Format:: - use immediate base class only,
// in case immediate base modifies behavior later.
return DateFormat::format(obj, appendTo, posIter, status);
}
inline UnicodeString&
SimpleDateFormat::format(UDate date,
UnicodeString& appendTo,
FieldPosition& fieldPosition) const {
// Don't use Format:: - use immediate base class only,
// in case immediate base modifies behavior later.
return DateFormat::format(date, appendTo, fieldPosition);
}
inline UnicodeString&
SimpleDateFormat::format(UDate date,
UnicodeString& appendTo,
FieldPositionIterator* posIter,
UErrorCode& status) const {
// Don't use Format:: - use immediate base class only,
// in case immediate base modifies behavior later.
return DateFormat::format(date, appendTo, posIter, status);
}
inline UnicodeString&
SimpleDateFormat::format(UDate date, UnicodeString& appendTo) const {
return DateFormat::format(date, appendTo);
}
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif // _SMPDTFMT #endif // _SMPDTFMT
//eof //eof
 End of changes. 4 change blocks. 
266 lines changed or deleted 10 lines changed or added


 stringpiece.h   stringpiece.h 
// Copyright (C) 2009-2012, International Business Machines // Copyright (C) 2009-2013, International Business Machines
// Corporation and others. All Rights Reserved. // Corporation and others. All Rights Reserved.
// //
// Copyright 2001 and onwards Google Inc. // Copyright 2001 and onwards Google Inc.
// Author: Sanjay Ghemawat // Author: Sanjay Ghemawat
// This code is a contribution of Google code, and the style used here is // This code is a contribution of Google code, and the style used here is
// a compromise between the original Google code and the ICU coding guideli nes. // a compromise between the original Google code and the ICU coding guideli nes.
// For example, data types are ICU-ified (size_t,int->int32_t), // For example, data types are ICU-ified (size_t,int->int32_t),
// and API comments doxygen-ified, but function names and behavior are // and API comments doxygen-ified, but function names and behavior are
// as in the original, if possible. // as in the original, if possible.
skipping to change at line 186 skipping to change at line 186
} else { } else {
length_ = 0; length_ = 0;
} }
} }
} }
/** /**
* Maximum integer, used as a default value for substring methods. * Maximum integer, used as a default value for substring methods.
* @stable ICU 4.2 * @stable ICU 4.2
*/ */
static const int32_t npos = 0x7fffffff; static const int32_t npos; // = 0x7fffffff;
/** /**
* Returns a substring of this StringPiece. * Returns a substring of this StringPiece.
* @param pos start position; must be non-negative and <= length(). * @param pos start position; must be non-negative and <= length().
* @param len length of the substring; * @param len length of the substring;
* must be non-negative and will be pinned to at most length() - pos. * must be non-negative and will be pinned to at most length() - pos.
* @return the substring StringPiece * @return the substring StringPiece
* @stable ICU 4.2 * @stable ICU 4.2
*/ */
StringPiece substr(int32_t pos, int32_t len = npos) const { StringPiece substr(int32_t pos, int32_t len = npos) const {
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added


 tblcoll.h   tblcoll.h 
skipping to change at line 440 skipping to change at line 440
* <pre> * <pre>
* Base* polymorphic_pointer = createPolymorphicObject(); * Base* polymorphic_pointer = createPolymorphicObject();
* if (polymorphic_pointer->getDynamicClassID() == * if (polymorphic_pointer->getDynamicClassID() ==
* Derived::getStaticClassID() ) ... * Derived::getStaticClassID() ) ...
* </pre> * </pre>
* @return The class ID for all objects of this class. * @return The class ID for all objects of this class.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
static UClassID U_EXPORT2 getStaticClassID(void); static UClassID U_EXPORT2 getStaticClassID(void);
#ifndef U_HIDE_DEPRECATED_API
/** /**
* Returns the binary format of the class's rules. The format is that o * Do not use this method: The caller and the ICU library might use dif
f ferent heaps.
* .col files. * Use cloneBinary() instead which writes to caller-provided memory.
*
* Returns a binary format of this collator.
* @param length Returns the length of the data, in bytes * @param length Returns the length of the data, in bytes
* @param status the error code status. * @param status the error code status.
* @return memory, owned by the caller, of size 'length' bytes. * @return memory, owned by the caller, of size 'length' bytes.
* @stable ICU 2.2 * @deprecated ICU 52. Use cloneBinary() instead.
*/ */
uint8_t *cloneRuleData(int32_t &length, UErrorCode &status); uint8_t *cloneRuleData(int32_t &length, UErrorCode &status);
#endif /* U_HIDE_DEPRECATED_API */
/** Creates a binary image of a collator. This binary image can be stor ed and /** Creates a binary image of a collator. This binary image can be stor ed and
* later used to instantiate a collator using ucol_openBinary. * later used to instantiate a collator using ucol_openBinary.
* This API supports preflighting. * This API supports preflighting.
* @param buffer a fill-in buffer to receive the binary image * @param buffer a fill-in buffer to receive the binary image
* @param capacity capacity of the destination buffer * @param capacity capacity of the destination buffer
* @param status for catching errors * @param status for catching errors
* @return size of the image * @return size of the image
* @see ucol_openBinary * @see ucol_openBinary
* @stable ICU 3.4 * @stable ICU 3.4
skipping to change at line 842 skipping to change at line 846
if (ucollator && dataIsOwned) { if (ucollator && dataIsOwned) {
ucol_close(ucollator); ucol_close(ucollator);
} }
ucollator = collator; ucollator = collator;
dataIsOwned = FALSE; dataIsOwned = FALSE;
isWriteThroughAlias = TRUE; isWriteThroughAlias = TRUE;
setRuleStringFromCollator(); setRuleStringFromCollator();
} }
#ifndef U_HIDE_INTERNAL_API
inline const UCollator * RuleBasedCollator::getUCollator() inline const UCollator * RuleBasedCollator::getUCollator()
{ {
return ucollator; return ucollator;
} }
#endif /* U_HIDE_INTERNAL_API */
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_COLLATION */ #endif /* #if !UCONFIG_NO_COLLATION */
#endif #endif
 End of changes. 6 change blocks. 
4 lines changed or deleted 10 lines changed or added


 timezone.h   timezone.h 
skipping to change at line 294 skipping to change at line 294
* @return A default TimeZone. Clients are responsible for deleting t he time zone * @return A default TimeZone. Clients are responsible for deleting t he time zone
* object returned. * object returned.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
static TimeZone* U_EXPORT2 createDefault(void); static TimeZone* U_EXPORT2 createDefault(void);
/** /**
* Sets the default time zone (i.e., what's returned by createDefault() ) to be the * Sets the default time zone (i.e., what's returned by createDefault() ) to be the
* specified time zone. If NULL is specified for the time zone, the de fault time * specified time zone. If NULL is specified for the time zone, the de fault time
* zone is set to the default host time zone. This call adopts the Tim eZone object * zone is set to the default host time zone. This call adopts the Tim eZone object
* passed in; the clent is no longer responsible for deleting it. * passed in; the client is no longer responsible for deleting it.
*
* <p>This function is not thread safe. It is an error for multiple thr
eads
* to concurrently attempt to set the default time zone, or for any thr
ead
* to attempt to reference the default zone while another thread is set
ting it.
* *
* @param zone A pointer to the new TimeZone object to use as the defa ult. * @param zone A pointer to the new TimeZone object to use as the defa ult.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
static void U_EXPORT2 adoptDefault(TimeZone* zone); static void U_EXPORT2 adoptDefault(TimeZone* zone);
#ifndef U_HIDE_SYSTEM_API #ifndef U_HIDE_SYSTEM_API
/** /**
* Same as adoptDefault(), except that the TimeZone object passed in is NOT adopted; * Same as adoptDefault(), except that the TimeZone object passed in is NOT adopted;
* the caller remains responsible for deleting it. * the caller remains responsible for deleting it.
* *
* <p>See the thread safety note under adoptDefault().
*
* @param zone The given timezone. * @param zone The given timezone.
* @system * @system
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
static void U_EXPORT2 setDefault(const TimeZone& zone); static void U_EXPORT2 setDefault(const TimeZone& zone);
#endif /* U_HIDE_SYSTEM_API */ #endif /* U_HIDE_SYSTEM_API */
/** /**
* Returns the timezone data version currently used by ICU. * Returns the timezone data version currently used by ICU.
* @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.
skipping to change at line 355 skipping to change at line 361
* @param status Recevies the status. When the given time zone ID * @param status Recevies the status. When the given time zone ID
* is neither a known system time zone ID nor a * is neither a known system time zone ID nor a
* valid custom time zone ID, U_ILLEGAL_ARGUMENT_E RROR * valid custom time zone ID, U_ILLEGAL_ARGUMENT_E RROR
* is set. * is set.
* @return A reference to the result. * @return A reference to the result.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
static UnicodeString& U_EXPORT2 getCanonicalID(const UnicodeString& id, static UnicodeString& U_EXPORT2 getCanonicalID(const UnicodeString& id,
UnicodeString& canonicalID, UBool& isSystemID, UErrorCode& status); UnicodeString& canonicalID, UBool& isSystemID, UErrorCode& status);
#ifndef U_HIDE_DRAFT_API
/**
* Converts a system time zone ID to an equivalent Windows time zone ID.
For example,
* Windows time zone ID "Pacific Standard Time" is returned for input "A
merica/Los_Angeles".
*
* <p>There are system time zones that cannot be mapped to Windows zones
. When the input
* system time zone ID is unknown or unmappable to a Windows time zone,
then the result will be
* empty, but the operation itself remains successful (no error status s
et on return).
*
* <p>This implementation utilizes <a href="http://unicode.org/cldr/char
ts/supplemental/zone_tzid.html">
* Zone-Tzid mapping data</a>. The mapping data is updated time to time.
To get the latest changes,
* please read the ICU user guide section <a href="http://userguide.icu-
project.org/datetime/timezone#TOC-Updating-the-Time-Zone-Data">
* Updating the Time Zone Data</a>.
*
* @param id A system time zone ID.
* @param winid Receives a Windows time zone ID. When the input syst
em time zone ID is unknown
* or unmappable to a Windows time zone ID, then an emp
ty string is set on return.
* @param status Receives the status.
* @return A reference to the result (<code>winid</code>).
* @see getIDForWindowsID
*
* @draft ICU 52
*/
static UnicodeString& U_EXPORT2 getWindowsID(const UnicodeString& id,
UnicodeString& winid, UErrorCode& status);
/**
* Converts a Windows time zone ID to an equivalent system time zone ID
* for a region. For example, system time zone ID "America/Los_Angeles"
is returned
* for input Windows ID "Pacific Standard Time" and region "US" (or <cod
e>null</code>),
* "America/Vancouver" is returned for the same Windows ID "Pacific Stan
dard Time" and
* region "CA".
*
* <p>Not all Windows time zones can be mapped to system time zones. Whe
n the input
* Windows time zone ID is unknown or unmappable to a system time zone,
then the result
* will be empty, but the operation itself remains successful (no error
status set on return).
*
* <p>This implementation utilizes <a href="http://unicode.org/cldr/char
ts/supplemental/zone_tzid.html">
* Zone-Tzid mapping data</a>. The mapping data is updated time to time.
To get the latest changes,
* please read the ICU user guide section <a href="http://userguide.icu-
project.org/datetime/timezone#TOC-Updating-the-Time-Zone-Data">
* Updating the Time Zone Data</a>.
*
* @param winid A Windows time zone ID.
* @param region A null-terminated region code, or <code>NULL</code>
if no regional preference.
* @param id Receives a system time zone ID. When the input Windo
ws time zone ID is unknown
* or unmappable to a system time zone ID, then an empt
y string is set on return.
* @param status Receives the status.
* @return A reference to the result (<code>id</code>).
* @see getWindowsID
*
* @draft ICU 52
*/
static UnicodeString& U_EXPORT2 getIDForWindowsID(const UnicodeString&
winid, const char* region,
UnicodeString& id, UErrorCode& status);
#endif /* U_HIDE_DRAFT_API */
/** /**
* Returns true if the two TimeZones are equal. (The TimeZone version only compares * Returns true if the two TimeZones are equal. (The TimeZone version only compares
* IDs, but subclasses are expected to also compare the fields they add .) * IDs, but subclasses are expected to also compare the fields they add .)
* *
* @param that The TimeZone object to be compared with. * @param that The TimeZone object to be compared with.
* @return True if the given TimeZone is equal to this TimeZone; f alse * @return True if the given TimeZone is equal to this TimeZone; f alse
* otherwise. * otherwise.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
virtual UBool operator==(const TimeZone& that) const; virtual UBool operator==(const TimeZone& that) const;
skipping to change at line 808 skipping to change at line 871
static const UChar* dereferOlsonLink(const UnicodeString& id); static const UChar* dereferOlsonLink(const UnicodeString& id);
/** /**
* Returns the region code associated with the given zone, * Returns the region code associated with the given zone,
* or NULL if the zone is not known. * or NULL if the zone is not known.
* @param id zone id string * @param id zone id string
* @return the region associated with the given zone * @return the region associated with the given zone
*/ */
static const UChar* getRegion(const UnicodeString& id); static const UChar* getRegion(const UnicodeString& id);
public:
#ifndef U_HIDE_INTERNAL_API
/** /**
* Returns the region code associated with the given zone, * Returns the region code associated with the given zone,
* or NULL if the zone is not known. * or NULL if the zone is not known.
* @param id zone id string * @param id zone id string
* @param status Status parameter * @param status Status parameter
* @return the region associated with the given zone * @return the region associated with the given zone
* @internal
*/ */
static const UChar* getRegion(const UnicodeString& id, UErrorCode& stat us); static const UChar* getRegion(const UnicodeString& id, UErrorCode& stat us);
#endif /* U_HIDE_INTERNAL_API */
private:
/** /**
* Parses the given custom time zone identifier * Parses the given custom time zone identifier
* @param id id A string of the form GMT[+-]hh:mm, GMT[+-]hhmm, or * @param id id A string of the form GMT[+-]hh:mm, GMT[+-]hhmm, or
* GMT[+-]hh. * GMT[+-]hh.
* @param sign Receves parsed sign, 1 for positive, -1 for negative. * @param sign Receves parsed sign, 1 for positive, -1 for negative.
* @param hour Receives parsed hour field * @param hour Receives parsed hour field
* @param minute Receives parsed minute field * @param minute Receives parsed minute field
* @param second Receives parsed second field * @param second Receives parsed second field
* @return Returns TRUE when the given custom id is valid. * @return Returns TRUE when the given custom id is valid.
*/ */
skipping to change at line 855 skipping to change at line 923
* @param hour offset hours * @param hour offset hours
* @param min offset minutes * @param min offset minutes
* @param sec offset seconds * @param sec offset seconds
* @param negative sign of the offset, TRUE for negative offset. * @param negative sign of the offset, TRUE for negative offset.
* @param id Receves the format result (normalized custom ID) * @param id Receves the format result (normalized custom ID)
* @return The reference to id * @return The reference to id
*/ */
static UnicodeString& formatCustomID(int32_t hour, int32_t min, int32_t sec, static UnicodeString& formatCustomID(int32_t hour, int32_t min, int32_t sec,
UBool negative, UnicodeString& id); UBool negative, UnicodeString& id);
/**
* Responsible for setting up DEFAULT_ZONE. Uses routines in TPlatform
Utilities
* (i.e., platform-specific calls) to get the current system time zone.
Failing
* that, uses the platform-specific default time zone. Failing that, u
ses GMT.
*/
static void initDefault(void);
// See source file for documentation
/**
* Lookup the given name in our system zone table. If found,
* instantiate a new zone of that name and return it. If not
* found, return 0.
* @param name tthe given name of a system time zone.
* @return the TimeZone indicated by the 'name'.
*/
static TimeZone* createSystemTimeZone(const UnicodeString& name)
;
static TimeZone* createSystemTimeZone(const UnicodeString& name,
UErrorCode& ec);
UnicodeString fID; // this time zone's ID UnicodeString fID; // this time zone's ID
friend class TZEnumeration; friend class TZEnumeration;
}; };
// ------------------------------------- // -------------------------------------
inline UnicodeString& inline UnicodeString&
TimeZone::getID(UnicodeString& ID) const TimeZone::getID(UnicodeString& ID) const
{ {
 End of changes. 8 change blocks. 
24 lines changed or deleted 95 lines changed or added


 tmutfmt.h   tmutfmt.h 
/* /*
************************************************************************** ***** ************************************************************************** *****
* Copyright (C) 2008-2012, Google, International Business Machines Corpora tion * Copyright (C) 2008-2013, Google, International Business Machines Corpora tion
* and others. All Rights Reserved. * and others. All Rights Reserved.
************************************************************************** ***** ************************************************************************** *****
*/ */
#ifndef __TMUTFMT_H__ #ifndef __TMUTFMT_H__
#define __TMUTFMT_H__ #define __TMUTFMT_H__
#include "unicode/utypes.h" #include "unicode/utypes.h"
/** /**
skipping to change at line 251 skipping to change at line 251
Hashtable* initHash(UErrorCode& status); Hashtable* initHash(UErrorCode& status);
// delete hash table // delete hash table
void deleteHash(Hashtable* htable); void deleteHash(Hashtable* htable);
// copy hash table // copy hash table
void copyHash(const Hashtable* source, Hashtable* target, UErrorCode& s tatus); void copyHash(const Hashtable* source, Hashtable* target, UErrorCode& s tatus);
// get time unit name, such as "year", from time unit field enum, such as // get time unit name, such as "year", from time unit field enum, such as
// UTIMEUNIT_YEAR. // UTIMEUNIT_YEAR.
static const char* getTimeUnitName(TimeUnit::UTimeUnitFields field, UEr rorCode& status); static const char* getTimeUnitName(TimeUnit::UTimeUnitFields field, UEr rorCode& status);
}; };
inline UBool inline UBool
TimeUnitFormat::operator!=(const Format& other) const { TimeUnitFormat::operator!=(const Format& other) const {
return !operator==(other); return !operator==(other);
} }
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
 End of changes. 2 change blocks. 
1 lines changed or deleted 2 lines changed or added


 translit.h   translit.h 
skipping to change at line 1311 skipping to change at line 1311
return maximumContextLength; return maximumContextLength;
} }
inline void Transliterator::setID(const UnicodeString& id) { inline void Transliterator::setID(const UnicodeString& id) {
ID = id; ID = id;
// NUL-terminate the ID string, which is a non-aliased copy. // NUL-terminate the ID string, which is a non-aliased copy.
ID.append((UChar)0); ID.append((UChar)0);
ID.truncate(ID.length()-1); ID.truncate(ID.length()-1);
} }
#ifndef U_HIDE_INTERNAL_API
inline Transliterator::Token Transliterator::integerToken(int32_t i) { inline Transliterator::Token Transliterator::integerToken(int32_t i) {
Token t; Token t;
t.integer = i; t.integer = i;
return t; return t;
} }
inline Transliterator::Token Transliterator::pointerToken(void* p) { inline Transliterator::Token Transliterator::pointerToken(void* p) {
Token t; Token t;
t.pointer = p; t.pointer = p;
return t; return t;
} }
#endif /* U_HIDE_INTERNAL_API */
U_NAMESPACE_END U_NAMESPACE_END
#endif /* #if !UCONFIG_NO_TRANSLITERATION */ #endif /* #if !UCONFIG_NO_TRANSLITERATION */
#endif #endif
 End of changes. 2 change blocks. 
0 lines changed or deleted 2 lines changed or added


 tzfmt.h   tzfmt.h 
skipping to change at line 18 skipping to change at line 18
#define __TZFMT_H #define __TZFMT_H
/** /**
* \file * \file
* \brief C++ API: TimeZoneFormat * \brief C++ API: TimeZoneFormat
*/ */
#include "unicode/utypes.h" #include "unicode/utypes.h"
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
#ifndef U_HIDE_DRAFT_API
#include "unicode/format.h" #include "unicode/format.h"
#include "unicode/timezone.h" #include "unicode/timezone.h"
#include "unicode/tznames.h" #include "unicode/tznames.h"
U_CDECL_BEGIN U_CDECL_BEGIN
/** /**
* Constants for time zone display format style used by format/parse APIs * Constants for time zone display format style used by format/parse APIs
* in TimeZoneFormat. * in TimeZoneFormat.
* @draft ICU 50 * @stable ICU 50
*/ */
typedef enum UTimeZoneFormatStyle { typedef enum UTimeZoneFormatStyle {
/** /**
* Generic location format, such as "United States Time (New York)", "I taly Time" * Generic location format, such as "United States Time (New York)", "I taly Time"
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_STYLE_GENERIC_LOCATION, UTZFMT_STYLE_GENERIC_LOCATION,
/** /**
* Generic long non-location format, such as "Eastern Time". * Generic long non-location format, such as "Eastern Time".
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_STYLE_GENERIC_LONG, UTZFMT_STYLE_GENERIC_LONG,
/** /**
* Generic short non-location format, such as "ET". * Generic short non-location format, such as "ET".
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_STYLE_GENERIC_SHORT, UTZFMT_STYLE_GENERIC_SHORT,
/** /**
* Specific long format, such as "Eastern Standard Time". * Specific long format, such as "Eastern Standard Time".
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_STYLE_SPECIFIC_LONG, UTZFMT_STYLE_SPECIFIC_LONG,
/** /**
* Specific short format, such as "EST", "PDT". * Specific short format, such as "EST", "PDT".
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_STYLE_SPECIFIC_SHORT, UTZFMT_STYLE_SPECIFIC_SHORT,
/** /**
* Localized GMT offset format, such as "GMT-05:00", "UTC+0100" * Localized GMT offset format, such as "GMT-05:00", "UTC+0100"
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_STYLE_LOCALIZED_GMT, UTZFMT_STYLE_LOCALIZED_GMT,
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
/** /**
* Short localized GMT offset format, such as "GMT-5", "UTC+1:30" * Short localized GMT offset format, such as "GMT-5", "UTC+1:30"
* This style is equivalent to the LDML date format pattern "O". * This style is equivalent to the LDML date format pattern "O".
* @draft ICU 51 * @draft ICU 51
*/ */
UTZFMT_STYLE_LOCALIZED_GMT_SHORT, UTZFMT_STYLE_LOCALIZED_GMT_SHORT,
/** /**
skipping to change at line 158 skipping to change at line 157
/** /**
* Exemplar location, such as "Los Angeles" and "Paris". * Exemplar location, such as "Los Angeles" and "Paris".
* @draft ICU 51 * @draft ICU 51
*/ */
UTZFMT_STYLE_EXEMPLAR_LOCATION UTZFMT_STYLE_EXEMPLAR_LOCATION
#endif /* U_HIDE_DRAFT_API */ #endif /* U_HIDE_DRAFT_API */
} UTimeZoneFormatStyle; } UTimeZoneFormatStyle;
/** /**
* Constants for GMT offset pattern types. * Constants for GMT offset pattern types.
* @draft ICU 50 * @stable ICU 50
*/ */
typedef enum UTimeZoneFormatGMTOffsetPatternType { typedef enum UTimeZoneFormatGMTOffsetPatternType {
/** /**
* Positive offset with hours and minutes fields * Positive offset with hours and minutes fields
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_PAT_POSITIVE_HM, UTZFMT_PAT_POSITIVE_HM,
/** /**
* Positive offset with hours, minutes and seconds fields * Positive offset with hours, minutes and seconds fields
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_PAT_POSITIVE_HMS, UTZFMT_PAT_POSITIVE_HMS,
/** /**
* Negative offset with hours and minutes fields * Negative offset with hours and minutes fields
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_PAT_NEGATIVE_HM, UTZFMT_PAT_NEGATIVE_HM,
/** /**
* Negative offset with hours, minutes and seconds fields * Negative offset with hours, minutes and seconds fields
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_PAT_NEGATIVE_HMS, UTZFMT_PAT_NEGATIVE_HMS,
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
/** /**
* Positive offset with hours field * Positive offset with hours field
* @draft ICU 51 * @draft ICU 51
*/ */
UTZFMT_PAT_POSITIVE_H, UTZFMT_PAT_POSITIVE_H,
/** /**
* Negative offset with hours field * Negative offset with hours field
* @draft ICU 51 * @draft ICU 51
*/ */
UTZFMT_PAT_NEGATIVE_H, UTZFMT_PAT_NEGATIVE_H,
#endif /* U_HIDE_DRAFT_API */ #endif /* U_HIDE_DRAFT_API */
#ifndef U_HIDE_INTERNAL_API
/** /**
* Number of UTimeZoneFormatGMTOffsetPatternType types. * Number of UTimeZoneFormatGMTOffsetPatternType types.
* @internal * @internal
*/ */
UTZFMT_PAT_COUNT UTZFMT_PAT_COUNT = 6
#endif /* U_HIDE_INTERNAL_API */
} UTimeZoneFormatGMTOffsetPatternType; } UTimeZoneFormatGMTOffsetPatternType;
/** /**
* Constants for time types used by TimeZoneFormat APIs for * Constants for time types used by TimeZoneFormat APIs for
* receiving time type (standard time, daylight time or unknown). * receiving time type (standard time, daylight time or unknown).
* @draft ICU 50 * @stable ICU 50
*/ */
typedef enum UTimeZoneFormatTimeType { typedef enum UTimeZoneFormatTimeType {
/** /**
* Unknown * Unknown
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_TIME_TYPE_UNKNOWN, UTZFMT_TIME_TYPE_UNKNOWN,
/** /**
* Standard time * Standard time
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_TIME_TYPE_STANDARD, UTZFMT_TIME_TYPE_STANDARD,
/** /**
* Daylight saving time * Daylight saving time
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_TIME_TYPE_DAYLIGHT UTZFMT_TIME_TYPE_DAYLIGHT
} UTimeZoneFormatTimeType; } UTimeZoneFormatTimeType;
/** /**
* Constants for parse option flags, used for specifying optional parse beh avior. * Constants for parse option flags, used for specifying optional parse beh avior.
* @draft ICU 50 * @stable ICU 50
*/ */
typedef enum UTimeZoneFormatParseOption { typedef enum UTimeZoneFormatParseOption {
/** /**
* No option. * No option.
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_PARSE_OPTION_NONE = 0x00, UTZFMT_PARSE_OPTION_NONE = 0x00,
/** /**
* When a time zone display name is not found within a set of display n ames * When a time zone display name is not found within a set of display n ames
* used for the specified style, look for the name from display names u sed * used for the specified style, look for the name from display names u sed
* by other styles. * by other styles.
* @draft ICU 50 * @stable ICU 50
*/ */
UTZFMT_PARSE_OPTION_ALL_STYLES = 0x01 UTZFMT_PARSE_OPTION_ALL_STYLES = 0x01
} UTimeZoneFormatParseOption; } UTimeZoneFormatParseOption;
U_CDECL_END U_CDECL_END
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
class TimeZoneGenericNames; class TimeZoneGenericNames;
class UVector; class UVector;
skipping to change at line 265 skipping to change at line 262
* but you can also directly get a new instance of <code>TimeZoneFormat</co de> and * but you can also directly get a new instance of <code>TimeZoneFormat</co de> and
* formatting/parsing time zone display names. * formatting/parsing time zone display names.
* <p> * <p>
* ICU implements the time zone display names defined by <a href="http://ww w.unicode.org/reports/tr35/">UTS#35 * ICU implements the time zone display names defined by <a href="http://ww w.unicode.org/reports/tr35/">UTS#35
* Unicode Locale Data Markup Language (LDML)</a>. {@link TimeZoneNames} re presents the * Unicode Locale Data Markup Language (LDML)</a>. {@link TimeZoneNames} re presents the
* time zone display name data model and this class implements the algorith m for actual * time zone display name data model and this class implements the algorith m for actual
* formatting and parsing. * formatting and parsing.
* *
* @see SimpleDateFormat * @see SimpleDateFormat
* @see TimeZoneNames * @see TimeZoneNames
* @draft ICU 50 * @stable ICU 50
*/ */
class U_I18N_API TimeZoneFormat : public Format { class U_I18N_API TimeZoneFormat : public Format {
public: public:
/** /**
* Copy constructor. * Copy constructor.
* @draft ICU 50 * @stable ICU 50
*/ */
TimeZoneFormat(const TimeZoneFormat& other); TimeZoneFormat(const TimeZoneFormat& other);
/** /**
* Destructor. * Destructor.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual ~TimeZoneFormat(); virtual ~TimeZoneFormat();
/** /**
* Assignment operator. * Assignment operator.
* @draft ICU 50 * @stable ICU 50
*/ */
TimeZoneFormat& operator=(const TimeZoneFormat& other); TimeZoneFormat& operator=(const TimeZoneFormat& other);
/** /**
* Return true if the given Format objects are semantically equal. * Return true if the given Format objects are semantically equal.
* Objects of different subclasses are considered unequal. * Objects of different subclasses are considered unequal.
* @param other The object to be compared with. * @param other The object to be compared with.
* @return Return TRUE if the given Format objects are semantically equ al. * @return Return TRUE if the given Format objects are semantically equ al.
* Objects of different subclasses are considered unequa l. * Objects of different subclasses are considered unequa l.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual UBool operator==(const Format& other) const; virtual UBool operator==(const Format& other) const;
/** /**
* Clone this object polymorphically. The caller is responsible * Clone this object polymorphically. The caller is responsible
* for deleting the result when done. * for deleting the result when done.
* @return A copy of the object * @return A copy of the object
* @draft ICU 50 * @stable ICU 50
*/ */
virtual Format* clone() const; virtual Format* clone() const;
/** /**
* Creates an instance of <code>TimeZoneFormat</code> for the given loc ale. * Creates an instance of <code>TimeZoneFormat</code> for the given loc ale.
* @param locale The locale. * @param locale The locale.
* @param status Recevies the status. * @param status Recevies the status.
* @return An instance of <code>TimeZoneFormat</code> for the given loc ale, * @return An instance of <code>TimeZoneFormat</code> for the given loc ale,
* owned by the caller. * owned by the caller.
* @draft ICU 50 * @stable ICU 50
*/ */
static TimeZoneFormat* U_EXPORT2 createInstance(const Locale& locale, U ErrorCode& status); static TimeZoneFormat* U_EXPORT2 createInstance(const Locale& locale, U ErrorCode& status);
/** /**
* Returns the time zone display name data used by this instance. * Returns the time zone display name data used by this instance.
* @return The time zone display name data. * @return The time zone display name data.
* @draft ICU 50 * @stable ICU 50
*/ */
const TimeZoneNames* getTimeZoneNames() const; const TimeZoneNames* getTimeZoneNames() const;
/** /**
* Sets the time zone display name data to this format instnace. * Sets the time zone display name data to this format instnace.
* The caller should not delete the TimeZoenNames object after it is ad opted * The caller should not delete the TimeZoenNames object after it is ad opted
* by this call. * by this call.
* @param tznames TimeZoneNames object to be adopted. * @param tznames TimeZoneNames object to be adopted.
* @draft ICU 50 * @stable ICU 50
*/ */
void adoptTimeZoneNames(TimeZoneNames *tznames); void adoptTimeZoneNames(TimeZoneNames *tznames);
/** /**
* Sets the time zone display name data to this format instnace. * Sets the time zone display name data to this format instnace.
* @param tznames TimeZoneNames object to be set. * @param tznames TimeZoneNames object to be set.
* @draft ICU 50 * @stable ICU 50
*/ */
void setTimeZoneNames(const TimeZoneNames &tznames); void setTimeZoneNames(const TimeZoneNames &tznames);
/** /**
* Returns the localized GMT format pattern. * Returns the localized GMT format pattern.
* @param pattern Receives the localized GMT format pattern. * @param pattern Receives the localized GMT format pattern.
* @return A reference to the result pattern. * @return A reference to the result pattern.
* @see #setGMTPattern * @see #setGMTPattern
* @draft ICU 50 * @stable ICU 50
*/ */
UnicodeString& getGMTPattern(UnicodeString& pattern) const; UnicodeString& getGMTPattern(UnicodeString& pattern) const;
/** /**
* Sets the localized GMT format pattern. The pattern must contain * Sets the localized GMT format pattern. The pattern must contain
* a single argument {0}, for example "GMT {0}". * a single argument {0}, for example "GMT {0}".
* @param pattern The localized GMT format pattern to be used by this o bject. * @param pattern The localized GMT format pattern to be used by this o bject.
* @param status Recieves the status. * @param status Recieves the status.
* @see #getGMTPattern * @see #getGMTPattern
* @draft ICU 50 * @stable ICU 50
*/ */
void setGMTPattern(const UnicodeString& pattern, UErrorCode& status); void setGMTPattern(const UnicodeString& pattern, UErrorCode& status);
/** /**
* Returns the offset pattern used for localized GMT format. * Returns the offset pattern used for localized GMT format.
* @param type The offset pattern type enum. * @param type The offset pattern type enum.
* @param pattern Receives the offset pattern. * @param pattern Receives the offset pattern.
* @return A reference to the result pattern. * @return A reference to the result pattern.
* @see #setGMTOffsetPattern * @see #setGMTOffsetPattern
* @draft ICU 50 * @stable ICU 50
*/ */
UnicodeString& getGMTOffsetPattern(UTimeZoneFormatGMTOffsetPatternType type, UnicodeString& pattern) const; UnicodeString& getGMTOffsetPattern(UTimeZoneFormatGMTOffsetPatternType type, UnicodeString& pattern) const;
/** /**
* Sets the offset pattern for the given offset type. * Sets the offset pattern for the given offset type.
* @param type The offset pattern type enum. * @param type The offset pattern type enum.
* @param pattern The offset pattern used for localized GMT format for the type. * @param pattern The offset pattern used for localized GMT format for the type.
* @param status Receives the status. * @param status Receives the status.
* @see #getGMTOffsetPattern * @see #getGMTOffsetPattern
* @draft ICU 50 * @stable ICU 50
*/ */
void setGMTOffsetPattern(UTimeZoneFormatGMTOffsetPatternType type, cons t UnicodeString& pattern, UErrorCode& status); void setGMTOffsetPattern(UTimeZoneFormatGMTOffsetPatternType type, cons t UnicodeString& pattern, UErrorCode& status);
/** /**
* Returns the decimal digit characters used for localized GMT format. * Returns the decimal digit characters used for localized GMT format.
* The return string contains exactly 10 code points (may include Unico de * The return string contains exactly 10 code points (may include Unico de
* supplementary character) representing digit 0 to digit 9 in the asce nding * supplementary character) representing digit 0 to digit 9 in the asce nding
* order. * order.
* @param digits Receives the decimal digits used for localized GMT for mat. * @param digits Receives the decimal digits used for localized GMT for mat.
* @see #setGMTOffsetDigits * @see #setGMTOffsetDigits
* @draft ICU 50 * @stable ICU 50
*/ */
UnicodeString& getGMTOffsetDigits(UnicodeString& digits) const; UnicodeString& getGMTOffsetDigits(UnicodeString& digits) const;
/** /**
* Sets the decimal digit characters used for localized GMT format. * Sets the decimal digit characters used for localized GMT format.
* The input <code>digits</code> must contain exactly 10 code points * The input <code>digits</code> must contain exactly 10 code points
* (Unicode supplementary characters are also allowed) representing * (Unicode supplementary characters are also allowed) representing
* digit 0 to digit 9 in the ascending order. When the input <code>digi ts</code> * digit 0 to digit 9 in the ascending order. When the input <code>digi ts</code>
* does not satisfy the condition, <code>U_ILLEGAL_ARGUMENT_ERROR</code > * does not satisfy the condition, <code>U_ILLEGAL_ARGUMENT_ERROR</code >
* will be set to the return status. * will be set to the return status.
* @param digits The decimal digits used for localized GMT format. * @param digits The decimal digits used for localized GMT format.
* @param status Receives the status. * @param status Receives the status.
* @see #getGMTOffsetDigits * @see #getGMTOffsetDigits
* @draft ICU 50 * @stable ICU 50
*/ */
void setGMTOffsetDigits(const UnicodeString& digits, UErrorCode& status ); void setGMTOffsetDigits(const UnicodeString& digits, UErrorCode& status );
/** /**
* Returns the localized GMT format string for GMT(UTC) itself (GMT off set is 0). * Returns the localized GMT format string for GMT(UTC) itself (GMT off set is 0).
* @param gmtZeroFormat Receives the localized GMT string string for GM T(UTC) itself. * @param gmtZeroFormat Receives the localized GMT string string for GM T(UTC) itself.
* @return A reference to the result GMT string. * @return A reference to the result GMT string.
* @see #setGMTZeroFormat * @see #setGMTZeroFormat
* @draft ICU 50 * @stable ICU 50
*/ */
UnicodeString& getGMTZeroFormat(UnicodeString& gmtZeroFormat) const; UnicodeString& getGMTZeroFormat(UnicodeString& gmtZeroFormat) const;
/** /**
* Sets the localized GMT format string for GMT(UTC) itself (GMT offset is 0). * Sets the localized GMT format string for GMT(UTC) itself (GMT offset is 0).
* @param gmtZeroFormat The localized GMT format string for GMT(UTC). * @param gmtZeroFormat The localized GMT format string for GMT(UTC).
* @param status Receives the status. * @param status Receives the status.
* @see #getGMTZeroFormat * @see #getGMTZeroFormat
* @draft ICU 50 * @stable ICU 50
*/ */
void setGMTZeroFormat(const UnicodeString& gmtZeroFormat, UErrorCode& s tatus); void setGMTZeroFormat(const UnicodeString& gmtZeroFormat, UErrorCode& s tatus);
/** /**
* Returns the bitwise flags of UTimeZoneFormatParseOption representing the default parse * Returns the bitwise flags of UTimeZoneFormatParseOption representing the default parse
* options used by this object. * options used by this object.
* @return the default parse options. * @return the default parse options.
* @see ParseOption * @see ParseOption
* @draft ICU 50 * @stable ICU 50
*/ */
uint32_t getDefaultParseOptions(void) const; uint32_t getDefaultParseOptions(void) const;
/** /**
* Sets the default parse options. * Sets the default parse options.
* <p><b>Note</b>: By default, an instance of <code>TimeZoneFormat</cod e> * <p><b>Note</b>: By default, an instance of <code>TimeZoneFormat</cod e>
* created by {@link #createInstance} has no parse options set (UTZFMT_ PARSE_OPTION_NONE). * created by {@link #createInstance} has no parse options set (UTZFMT_ PARSE_OPTION_NONE).
* To specify multipe options, use bitwise flags of UTimeZoneFormatPars eOption. * To specify multipe options, use bitwise flags of UTimeZoneFormatPars eOption.
* @see #UTimeZoneFormatParseOption * @see #UTimeZoneFormatParseOption
* @draft ICU 50 * @stable ICU 50
*/ */
void setDefaultParseOptions(uint32_t flags); void setDefaultParseOptions(uint32_t flags);
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
/** /**
* Returns the ISO 8601 basic time zone string for the given offset. * Returns the ISO 8601 basic time zone string for the given offset.
* For example, "-08", "-0830" and "Z" * For example, "-08", "-0830" and "Z"
* *
* @param offset the offset from GMT(UTC) in milliseconds. * @param offset the offset from GMT(UTC) in milliseconds.
* @param useUtcIndicator true if ISO 8601 UTC indicator "Z" is used wh en the offset is 0. * @param useUtcIndicator true if ISO 8601 UTC indicator "Z" is used wh en the offset is 0.
skipping to change at line 494 skipping to change at line 491
* <li>GMT zero format (e.g. "GMT" - see {@link #getGMTZeroFormat}) * <li>GMT zero format (e.g. "GMT" - see {@link #getGMTZeroFormat})
* </ul> * </ul>
* This format always uses 2 digit hours and minutes. When the given of fset has non-zero * This format always uses 2 digit hours and minutes. When the given of fset has non-zero
* seconds, 2 digit seconds field will be appended. For example, * seconds, 2 digit seconds field will be appended. For example,
* GMT+05:00 and GMT+05:28:06. * GMT+05:00 and GMT+05:28:06.
* @param offset the offset from GMT(UTC) in milliseconds. * @param offset the offset from GMT(UTC) in milliseconds.
* @param status Receives the status * @param status Receives the status
* @param result Receives the localized GMT format string. * @param result Receives the localized GMT format string.
* @return A reference to the result. * @return A reference to the result.
* @see #parseOffsetLocalizedGMT * @see #parseOffsetLocalizedGMT
* @draft ICU 50 * @stable ICU 50
*/ */
UnicodeString& formatOffsetLocalizedGMT(int32_t offset, UnicodeString& result, UErrorCode& status) const; UnicodeString& formatOffsetLocalizedGMT(int32_t offset, UnicodeString& result, UErrorCode& status) const;
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
/** /**
* Returns the short localized GMT(UTC) offset format for the given off set. * Returns the short localized GMT(UTC) offset format for the given off set.
* The short localized GMT offset is defined by; * The short localized GMT offset is defined by;
* <ul> * <ul>
* <li>GMT format pattern (e.g. "GMT {0}" - see {@link #getGMTPattern}) * <li>GMT format pattern (e.g. "GMT {0}" - see {@link #getGMTPattern})
* <li>Offset time pattern (e.g. "+HH:mm" - see {@link #getGMTOffsetPat tern}) * <li>Offset time pattern (e.g. "+HH:mm" - see {@link #getGMTOffsetPat tern})
skipping to change at line 534 skipping to change at line 531
* Returns the display name of the time zone at the given date for the style. * Returns the display name of the time zone at the given date for the style.
* @param style The style (e.g. <code>UTZFMT_STYLE_GENERIC_LONG</code>, <code>UTZFMT_STYLE_LOCALIZED_GMT</code>...) * @param style The style (e.g. <code>UTZFMT_STYLE_GENERIC_LONG</code>, <code>UTZFMT_STYLE_LOCALIZED_GMT</code>...)
* @param tz The time zone. * @param tz The time zone.
* @param date The date. * @param date The date.
* @param name Receives the display name. * @param name Receives the display name.
* @param timeType the output argument for receiving the time type (sta ndard/daylight/unknown) * @param timeType the output argument for receiving the time type (sta ndard/daylight/unknown)
* used for the display name, or NULL if the information is not necessa ry. * used for the display name, or NULL if the information is not necessa ry.
* @return A reference to the result * @return A reference to the result
* @see #UTimeZoneFormatStyle * @see #UTimeZoneFormatStyle
* @see #UTimeZoneFormatTimeType * @see #UTimeZoneFormatTimeType
* @draft ICU 50 * @stable ICU 50
*/ */
virtual UnicodeString& format(UTimeZoneFormatStyle style, const TimeZon e& tz, UDate date, virtual UnicodeString& format(UTimeZoneFormatStyle style, const TimeZon e& tz, UDate date,
UnicodeString& name, UTimeZoneFormatTimeType* timeType = NULL) cons t; UnicodeString& name, UTimeZoneFormatTimeType* timeType = NULL) cons t;
/** /**
* Returns offset from GMT(UTC) in milliseconds for the given ISO 8601 * Returns offset from GMT(UTC) in milliseconds for the given ISO 8601
* style time zone string. When the given string is not an ISO 8601 tim e zone * style time zone string. When the given string is not an ISO 8601 tim e zone
* string, this method sets the current position as the error index * string, this method sets the current position as the error index
* to <code>ParsePosition pos</code> and returns 0. * to <code>ParsePosition pos</code> and returns 0.
* @param text The text contains ISO8601 style time zone string (e.g. " -08:00", "Z") * @param text The text contains ISO8601 style time zone string (e.g. " -08:00", "Z")
* at the position. * at the position.
* @param pos The ParsePosition object. * @param pos The ParsePosition object.
* @return The offset from GMT(UTC) in milliseconds for the given ISO 8 601 style * @return The offset from GMT(UTC) in milliseconds for the given ISO 8 601 style
* time zone string. * time zone string.
* @see #formatOffsetISO8601Basic * @see #formatOffsetISO8601Basic
* @see #formatOffsetISO8601Extended * @see #formatOffsetISO8601Extended
* @draft ICU 50 * @stable ICU 50
*/ */
int32_t parseOffsetISO8601(const UnicodeString& text, ParsePosition& po s) const; int32_t parseOffsetISO8601(const UnicodeString& text, ParsePosition& po s) const;
/** /**
* Returns offset from GMT(UTC) in milliseconds for the given localized GMT * Returns offset from GMT(UTC) in milliseconds for the given localized GMT
* offset format string. When the given string cannot be parsed, this m ethod * offset format string. When the given string cannot be parsed, this m ethod
* sets the current position as the error index to <code>ParsePosition pos</code> * sets the current position as the error index to <code>ParsePosition pos</code>
* and returns 0. * and returns 0.
* @param text The text contains a localized GMT offset string at the p osition. * @param text The text contains a localized GMT offset string at the p osition.
* @param pos The ParsePosition object. * @param pos The ParsePosition object.
* @return The offset from GMT(UTC) in milliseconds for the given local ized GMT * @return The offset from GMT(UTC) in milliseconds for the given local ized GMT
* offset format string. * offset format string.
* @see #formatOffsetLocalizedGMT * @see #formatOffsetLocalizedGMT
* @draft ICU 50 * @stable ICU 50
*/ */
int32_t parseOffsetLocalizedGMT(const UnicodeString& text, ParsePositio n& pos) const; int32_t parseOffsetLocalizedGMT(const UnicodeString& text, ParsePositio n& pos) const;
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
/** /**
* Returns offset from GMT(UTC) in milliseconds for the given short loc alized GMT * Returns offset from GMT(UTC) in milliseconds for the given short loc alized GMT
* offset format string. When the given string cannot be parsed, this m ethod * offset format string. When the given string cannot be parsed, this m ethod
* sets the current position as the error index to <code>ParsePosition pos</code> * sets the current position as the error index to <code>ParsePosition pos</code>
* and returns 0. * and returns 0.
* @param text The text contains a short localized GMT offset string at the position. * @param text The text contains a short localized GMT offset string at the position.
skipping to change at line 599 skipping to change at line 596
* @param text The text contains a time zone string at the position. * @param text The text contains a time zone string at the position.
* @param style The format style * @param style The format style
* @param pos The position. * @param pos The position.
* @param parseOptions The parse options repesented by bitwise flags of UTimeZoneFormatParseOption. * @param parseOptions The parse options repesented by bitwise flags of UTimeZoneFormatParseOption.
* @param timeType The output argument for receiving the time type (sta ndard/daylight/unknown), * @param timeType The output argument for receiving the time type (sta ndard/daylight/unknown),
* or NULL if the information is not necessary. * or NULL if the information is not necessary.
* @return A <code>TimeZone</code>, or null if the input could not be p arsed. * @return A <code>TimeZone</code>, or null if the input could not be p arsed.
* @see UTimeZoneFormatStyle * @see UTimeZoneFormatStyle
* @see UTimeZoneFormatParseOption * @see UTimeZoneFormatParseOption
* @see UTimeZoneFormatTimeType * @see UTimeZoneFormatTimeType
* @draft ICU 50 * @stable ICU 50
*/ */
virtual TimeZone* parse(UTimeZoneFormatStyle style, const UnicodeString & text, ParsePosition& pos, virtual TimeZone* parse(UTimeZoneFormatStyle style, const UnicodeString & text, ParsePosition& pos,
int32_t parseOptions, UTimeZoneFormatTimeType* timeType = NULL) con st; int32_t parseOptions, UTimeZoneFormatTimeType* timeType = NULL) con st;
/** /**
* Returns a <code>TimeZone</code> by parsing the time zone string acco rding to * Returns a <code>TimeZone</code> by parsing the time zone string acco rding to
* the given parse position, the specified format style and the default parse options. * the given parse position, the specified format style and the default parse options.
* *
* @param text The text contains a time zone string at the position. * @param text The text contains a time zone string at the position.
* @param style The format style * @param style The format style
* @param pos The position. * @param pos The position.
* @param timeType The output argument for receiving the time type (sta ndard/daylight/unknown), * @param timeType The output argument for receiving the time type (sta ndard/daylight/unknown),
* or NULL if the information is not necessary. * or NULL if the information is not necessary.
* @return A <code>TimeZone</code>, or null if the input could not be p arsed. * @return A <code>TimeZone</code>, or null if the input could not be p arsed.
* @see UTimeZoneFormatStyle * @see UTimeZoneFormatStyle
* @see UTimeZoneFormatParseOption * @see UTimeZoneFormatParseOption
* @see UTimeZoneFormatTimeType * @see UTimeZoneFormatTimeType
* @draft ICU 50 * @stable ICU 50
*/ */
TimeZone* parse(UTimeZoneFormatStyle style, const UnicodeString& text, ParsePosition& pos, TimeZone* parse(UTimeZoneFormatStyle style, const UnicodeString& text, ParsePosition& pos,
UTimeZoneFormatTimeType* timeType = NULL) const; UTimeZoneFormatTimeType* timeType = NULL) const;
/* ---------------------------------------------- /* ----------------------------------------------
* Format APIs * Format APIs
* ---------------------------------------------- */ * ---------------------------------------------- */
/** /**
* Format an object to produce a time zone display string using localiz ed GMT offset format. * Format an object to produce a time zone display string using localiz ed GMT offset format.
* This method handles Formattable objects with a <code>TimeZone</code> . If a the Formattable * This method handles Formattable objects with a <code>TimeZone</code> . If a the Formattable
* object type is not a <code>TimeZone</code>, then it returns a failin g UErrorCode. * object type is not a <code>TimeZone</code>, then it returns a failin g UErrorCode.
* @param obj The object to format. Must be a <code>TimeZone</code>. * @param obj The object to format. Must be a <code>TimeZone</code>.
* @param appendTo Output parameter to receive result. Result is append ed to existing contents. * @param appendTo Output parameter to receive result. Result is append ed to existing contents.
* @param pos On input: an alignment field, if desired. On output: the offsets of the alignment field. * @param pos On input: an alignment field, if desired. On output: the offsets of the alignment field.
* @param status Output param filled with success/failure status. * @param status Output param filled with success/failure status.
* @return Reference to 'appendTo' parameter. * @return Reference to 'appendTo' parameter.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual UnicodeString& format(const Formattable& obj, UnicodeString& ap pendTo, virtual UnicodeString& format(const Formattable& obj, UnicodeString& ap pendTo,
FieldPosition& pos, UErrorCode& status) const; FieldPosition& pos, UErrorCode& status) const;
/** /**
* Parse a string to produce an object. This methods handles parsing of * Parse a string to produce an object. This methods handles parsing of
* time zone display strings into Formattable objects with <code>TimeZo ne</code>. * time zone display strings into Formattable objects with <code>TimeZo ne</code>.
* @param source The string to be parsed into an object. * @param source The string to be parsed into an object.
* @param result Formattable to be set to the parse result. If parse fa ils, return contents are undefined. * @param result Formattable to be set to the parse result. If parse fa ils, return contents are undefined.
* @param parse_pos The position to start parsing at. Upon return this param is set to the position after the * @param parse_pos The position to start parsing at. Upon return this param is set to the position after the
* last character successfully parsed. If the source i s not parsed successfully, this param * last character successfully parsed. If the source i s not parsed successfully, this param
* will remain unchanged. * will remain unchanged.
* @return A newly created Formattable* object, or NULL on failure. Th e caller owns this and should * @return A newly created Formattable* object, or NULL on failure. Th e caller owns this and should
* delete it when done. * delete it when done.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual void parseObject(const UnicodeString& source, Formattable& resu lt, ParsePosition& parse_pos) const; virtual void parseObject(const UnicodeString& source, Formattable& resu lt, ParsePosition& parse_pos) const;
/** /**
* ICU "poor man's RTTI", returns a UClassID for this class. * ICU "poor man's RTTI", returns a UClassID for this class.
* @draft ICU 50 * @stable ICU 50
*/ */
static UClassID U_EXPORT2 getStaticClassID(void); static UClassID U_EXPORT2 getStaticClassID(void);
/** /**
* ICU "poor man's RTTI", returns a UClassID for the actual class. * ICU "poor man's RTTI", returns a UClassID for the actual class.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual UClassID getDynamicClassID() const; virtual UClassID getDynamicClassID() const;
protected: protected:
/** /**
* Constructs a TimeZoneFormat object for the specified locale. * Constructs a TimeZoneFormat object for the specified locale.
* @param locale the locale * @param locale the locale
* @param status receives the status. * @param status receives the status.
* @draft ICU 50 * @stable ICU 50
*/ */
TimeZoneFormat(const Locale& locale, UErrorCode& status); TimeZoneFormat(const Locale& locale, UErrorCode& status);
private: private:
/* Locale of this object */ /* Locale of this object */
Locale fLocale; Locale fLocale;
/* Stores the region (could be implicit default) */ /* Stores the region (could be implicit default) */
char fTargetRegion[ULOC_COUNTRY_CAPACITY]; char fTargetRegion[ULOC_COUNTRY_CAPACITY];
skipping to change at line 1086 skipping to change at line 1083
* @param text the text contains an exemplar location string at the pos ition. * @param text the text contains an exemplar location string at the pos ition.
* @param pos the position. * @param pos the position.
* @param tzID receives the time zone ID * @param tzID receives the time zone ID
* @return a reference to tzID * @return a reference to tzID
*/ */
UnicodeString& parseExemplarLocation(const UnicodeString& text, ParsePo sition& pos, UnicodeString& tzID) const; UnicodeString& parseExemplarLocation(const UnicodeString& text, ParsePo sition& pos, UnicodeString& tzID) const;
}; };
U_NAMESPACE_END U_NAMESPACE_END
#endif /* ndef U_HIDE_DRAFT_API */
#endif /* !UCONFIG_NO_FORMATTING */ #endif /* !UCONFIG_NO_FORMATTING */
#endif #endif
 End of changes. 54 change blocks. 
55 lines changed or deleted 51 lines changed or added


 tznames.h   tznames.h 
skipping to change at line 17 skipping to change at line 17
#ifndef __TZNAMES_H #ifndef __TZNAMES_H
#define __TZNAMES_H #define __TZNAMES_H
/** /**
* \file * \file
* \brief C++ API: TimeZoneNames * \brief C++ API: TimeZoneNames
*/ */
#include "unicode/utypes.h" #include "unicode/utypes.h"
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
#ifndef U_HIDE_DRAFT_API
#include "unicode/uloc.h" #include "unicode/uloc.h"
#include "unicode/unistr.h" #include "unicode/unistr.h"
U_CDECL_BEGIN U_CDECL_BEGIN
/** /**
* Constants for time zone display name types. * Constants for time zone display name types.
* @draft ICU 50 * @stable ICU 50
*/ */
typedef enum UTimeZoneNameType { typedef enum UTimeZoneNameType {
/** /**
* Unknown display name type. * Unknown display name type.
* @draft ICU 50 * @stable ICU 50
*/ */
UTZNM_UNKNOWN = 0x00, UTZNM_UNKNOWN = 0x00,
/** /**
* Long display name, such as "Eastern Time". * Long display name, such as "Eastern Time".
* @draft ICU 50 * @stable ICU 50
*/ */
UTZNM_LONG_GENERIC = 0x01, UTZNM_LONG_GENERIC = 0x01,
/** /**
* Long display name for standard time, such as "Eastern Standard Time" . * Long display name for standard time, such as "Eastern Standard Time" .
* @draft ICU 50 * @stable ICU 50
*/ */
UTZNM_LONG_STANDARD = 0x02, UTZNM_LONG_STANDARD = 0x02,
/** /**
* Long display name for daylight saving time, such as "Eastern Dayligh t Time". * Long display name for daylight saving time, such as "Eastern Dayligh t Time".
* @draft ICU 50 * @stable ICU 50
*/ */
UTZNM_LONG_DAYLIGHT = 0x04, UTZNM_LONG_DAYLIGHT = 0x04,
/** /**
* Short display name, such as "ET". * Short display name, such as "ET".
* @draft ICU 50 * @stable ICU 50
*/ */
UTZNM_SHORT_GENERIC = 0x08, UTZNM_SHORT_GENERIC = 0x08,
/** /**
* Short display name for standard time, such as "EST". * Short display name for standard time, such as "EST".
* @draft ICU 50 * @stable ICU 50
*/ */
UTZNM_SHORT_STANDARD = 0x10, UTZNM_SHORT_STANDARD = 0x10,
/** /**
* Short display name for daylight saving time, such as "EDT". * Short display name for daylight saving time, such as "EDT".
* @draft ICU 50 * @stable ICU 50
*/ */
UTZNM_SHORT_DAYLIGHT = 0x20, UTZNM_SHORT_DAYLIGHT = 0x20,
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
/** /**
* Exemplar location name, such as "Los Angeles". * Exemplar location name, such as "Los Angeles".
* @draft ICU 51 * @draft ICU 51
*/ */
UTZNM_EXEMPLAR_LOCATION = 0x40 UTZNM_EXEMPLAR_LOCATION = 0x40
#endif /* U_HIDE_DRAFT_API */ #endif /* U_HIDE_DRAFT_API */
} UTimeZoneNameType; } UTimeZoneNameType;
skipping to change at line 128 skipping to change at line 127
* may provide time zone names only through {@link #getTimeZoneDisplayName} , or only through {@link #getMetaZoneDisplayName}, * may provide time zone names only through {@link #getTimeZoneDisplayName} , or only through {@link #getMetaZoneDisplayName},
* or both. * or both.
* *
* <p> * <p>
* The default <code>TimeZoneNames</code> implementation returned by {@link #createInstance} * The default <code>TimeZoneNames</code> implementation returned by {@link #createInstance}
* uses the locale data imported from CLDR. In CLDR, set of meta zone IDs a nd mappings between zone IDs and meta zone * uses the locale data imported from CLDR. In CLDR, set of meta zone IDs a nd mappings between zone IDs and meta zone
* IDs are shared by all locales. Therefore, the behavior of {@link #getAva ilableMetaZoneIDs}, * IDs are shared by all locales. Therefore, the behavior of {@link #getAva ilableMetaZoneIDs},
* {@link #getMetaZoneID}, and {@link #getReferenceZoneID} won't be changed no matter * {@link #getMetaZoneID}, and {@link #getReferenceZoneID} won't be changed no matter
* what locale is used for getting an instance of <code>TimeZoneNames</code >. * what locale is used for getting an instance of <code>TimeZoneNames</code >.
* *
* @draft ICU 50 * @stable ICU 50
*/ */
class U_I18N_API TimeZoneNames : public UObject { class U_I18N_API TimeZoneNames : public UObject {
public: public:
/** /**
* Destructor. * Destructor.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual ~TimeZoneNames(); virtual ~TimeZoneNames();
/** /**
* Return true if the given TimeZoneNames objects are emantically equal . * Return true if the given TimeZoneNames objects are emantically equal .
* @param other the object to be compared with. * @param other the object to be compared with.
* @return Return TRUE if the given Format objects are semantically equ al. * @return Return TRUE if the given Format objects are semantically equ al.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual UBool operator==(const TimeZoneNames& other) const = 0; virtual UBool operator==(const TimeZoneNames& other) const = 0;
/** /**
* Return true if the given TimeZoneNames objects are not semantically * Return true if the given TimeZoneNames objects are not semantically
* equal. * equal.
* @param other the object to be compared with. * @param other the object to be compared with.
* @return Return TRUE if the given Format objects are not semantically equal. * @return Return TRUE if the given Format objects are not semantically equal.
* @draft ICU 50 * @stable ICU 50
*/ */
UBool operator!=(const TimeZoneNames& other) const { return !operator== (other); } UBool operator!=(const TimeZoneNames& other) const { return !operator== (other); }
/** /**
* Clone this object polymorphically. The caller is responsible * Clone this object polymorphically. The caller is responsible
* for deleting the result when done. * for deleting the result when done.
* @return A copy of the object * @return A copy of the object
* @draft ICU 50 * @stable ICU 50
*/ */
virtual TimeZoneNames* clone() const = 0; virtual TimeZoneNames* clone() const = 0;
/** /**
* Returns an instance of <code>TimeZoneDisplayNames</code> for the spe cified locale. * Returns an instance of <code>TimeZoneDisplayNames</code> for the spe cified locale.
* *
* @param locale The locale. * @param locale The locale.
* @param status Recevies the status. * @param status Recevies the status.
* @return An instance of <code>TimeZoneDisplayNames</code> * @return An instance of <code>TimeZoneDisplayNames</code>
* @draft ICU 50 * @stable ICU 50
*/ */
static TimeZoneNames* U_EXPORT2 createInstance(const Locale& locale, UE rrorCode& status); static TimeZoneNames* U_EXPORT2 createInstance(const Locale& locale, UE rrorCode& status);
/** /**
* Returns an enumeration of all available meta zone IDs. * Returns an enumeration of all available meta zone IDs.
* @param status Recevies the status. * @param status Recevies the status.
* @return an enumeration object, owned by the caller. * @return an enumeration object, owned by the caller.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual StringEnumeration* getAvailableMetaZoneIDs(UErrorCode& status) const = 0; virtual StringEnumeration* getAvailableMetaZoneIDs(UErrorCode& status) const = 0;
/** /**
* Returns an enumeration of all available meta zone IDs used by the gi ven time zone. * Returns an enumeration of all available meta zone IDs used by the gi ven time zone.
* @param tzID The canoical tiem zone ID. * @param tzID The canoical tiem zone ID.
* @param status Recevies the status. * @param status Recevies the status.
* @return an enumeration object, owned by the caller. * @return an enumeration object, owned by the caller.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual StringEnumeration* getAvailableMetaZoneIDs(const UnicodeString& tzID, UErrorCode& status) const = 0; virtual StringEnumeration* getAvailableMetaZoneIDs(const UnicodeString& tzID, UErrorCode& status) const = 0;
/** /**
* Returns the meta zone ID for the given canonical time zone ID at the given date. * Returns the meta zone ID for the given canonical time zone ID at the given date.
* @param tzID The canonical time zone ID. * @param tzID The canonical time zone ID.
* @param date The date. * @param date The date.
* @param mzID Receives the meta zone ID for the given time zone ID at the given date. If the time zone does not have a * @param mzID Receives the meta zone ID for the given time zone ID at the given date. If the time zone does not have a
* corresponding meta zone at the given date or the implementa tion does not support meta zones, "bogus" state * corresponding meta zone at the given date or the implementa tion does not support meta zones, "bogus" state
* is set. * is set.
* @return A reference to the result. * @return A reference to the result.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual UnicodeString& getMetaZoneID(const UnicodeString& tzID, UDate d ate, UnicodeString& mzID) const = 0; virtual UnicodeString& getMetaZoneID(const UnicodeString& tzID, UDate d ate, UnicodeString& mzID) const = 0;
/** /**
* Returns the reference zone ID for the given meta zone ID for the reg ion. * Returns the reference zone ID for the given meta zone ID for the reg ion.
* *
* Note: Each meta zone must have a reference zone associated with a sp ecial region "001" (world). * Note: Each meta zone must have a reference zone associated with a sp ecial region "001" (world).
* Some meta zones may have region specific reference zone IDs other th an the special region * Some meta zones may have region specific reference zone IDs other th an the special region
* "001". When a meta zone does not have any region specific reference zone IDs, this method * "001". When a meta zone does not have any region specific reference zone IDs, this method
* return the reference zone ID for the special region "001" (world). * return the reference zone ID for the special region "001" (world).
* *
* @param mzID The meta zone ID. * @param mzID The meta zone ID.
* @param region The region. * @param region The region.
* @param tzID Receives the reference zone ID ("golden zone" in the LDM L specification) for the given time zone ID for the * @param tzID Receives the reference zone ID ("golden zone" in the LDM L specification) for the given time zone ID for the
* region. If the meta zone is unknown or the implementation d oes not support meta zones, "bogus" state * region. If the meta zone is unknown or the implementation d oes not support meta zones, "bogus" state
* is set. * is set.
* @return A reference to the result. * @return A reference to the result.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual UnicodeString& getReferenceZoneID(const UnicodeString& mzID, co nst char* region, UnicodeString& tzID) const = 0; virtual UnicodeString& getReferenceZoneID(const UnicodeString& mzID, co nst char* region, UnicodeString& tzID) const = 0;
/** /**
* Returns the display name of the meta zone. * Returns the display name of the meta zone.
* @param mzID The meta zone ID. * @param mzID The meta zone ID.
* @param type The display name type. See {@link #UTimeZoneNameType}. * @param type The display name type. See {@link #UTimeZoneNameType}.
* @param name Receives the display name of the meta zone. When this ob ject does not have a localized display name for the given * @param name Receives the display name of the meta zone. When this ob ject does not have a localized display name for the given
* meta zone with the specified type or the implementation does not provide any display names associated * meta zone with the specified type or the implementation does not provide any display names associated
* with meta zones, "bogus" state is set. * with meta zones, "bogus" state is set.
* @return A reference to the result. * @return A reference to the result.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual UnicodeString& getMetaZoneDisplayName(const UnicodeString& mzID , UTimeZoneNameType type, UnicodeString& name) const = 0; virtual UnicodeString& getMetaZoneDisplayName(const UnicodeString& mzID , UTimeZoneNameType type, UnicodeString& name) const = 0;
/** /**
* Returns the display name of the time zone. Unlike {@link #getDisplay Name}, * Returns the display name of the time zone. Unlike {@link #getDisplay Name},
* this method does not get a name from a meta zone used by the time zo ne. * this method does not get a name from a meta zone used by the time zo ne.
* @param tzID The canonical time zone ID. * @param tzID The canonical time zone ID.
* @param type The display name type. See {@link #UTimeZoneNameType}. * @param type The display name type. See {@link #UTimeZoneNameType}.
* @param name Receives the display name for the time zone. When this o bject does not have a localized display name for the given * @param name Receives the display name for the time zone. When this o bject does not have a localized display name for the given
* time zone with the specified type, "bogus" state is set. * time zone with the specified type, "bogus" state is set.
* @return A reference to the result. * @return A reference to the result.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual UnicodeString& getTimeZoneDisplayName(const UnicodeString& tzID , UTimeZoneNameType type, UnicodeString& name) const = 0; virtual UnicodeString& getTimeZoneDisplayName(const UnicodeString& tzID , UTimeZoneNameType type, UnicodeString& name) const = 0;
/** /**
* Returns the exemplar location name for the given time zone. When thi s object does not have a localized location * Returns the exemplar location name for the given time zone. When thi s object does not have a localized location
* name, the default implementation may still returns a programmaticall y generated name with the logic described * name, the default implementation may still returns a programmaticall y generated name with the logic described
* below. * below.
* <ol> * <ol>
* <li>Check if the ID contains "/". If not, return null. * <li>Check if the ID contains "/". If not, return null.
* <li>Check if the ID does not start with "Etc/" or "SystemV/". If it does, return null. * <li>Check if the ID does not start with "Etc/" or "SystemV/". If it does, return null.
* <li>Extract a substring after the last occurrence of "/". * <li>Extract a substring after the last occurrence of "/".
* <li>Replace "_" with " ". * <li>Replace "_" with " ".
* </ol> * </ol>
* For example, "New York" is returned for the time zone ID "America/Ne w_York" when this object does not have the * For example, "New York" is returned for the time zone ID "America/Ne w_York" when this object does not have the
* localized location name. * localized location name.
* *
* @param tzID The canonical time zone ID * @param tzID The canonical time zone ID
* @param name Receives the exemplar location name for the given time z one, or "bogus" state is set when a localized * @param name Receives the exemplar location name for the given time z one, or "bogus" state is set when a localized
* location name is not available and the fallback logic descr ibed above cannot extract location from the ID. * location name is not available and the fallback logic descr ibed above cannot extract location from the ID.
* @return A reference to the result. * @return A reference to the result.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual UnicodeString& getExemplarLocationName(const UnicodeString& tzI D, UnicodeString& name) const; virtual UnicodeString& getExemplarLocationName(const UnicodeString& tzI D, UnicodeString& name) const;
/** /**
* Returns the display name of the time zone at the given date. * Returns the display name of the time zone at the given date.
* <p> * <p>
* <b>Note:</b> This method calls the subclass's {@link #getTimeZoneDis playName} first. When the * <b>Note:</b> This method calls the subclass's {@link #getTimeZoneDis playName} first. When the
* result is bogus, this method calls {@link #getMetaZoneID} to get the meta zone ID mapped from the * result is bogus, this method calls {@link #getMetaZoneID} to get the meta zone ID mapped from the
* time zone, then calls {@link #getMetaZoneDisplayName}. * time zone, then calls {@link #getMetaZoneDisplayName}.
* *
* @param tzID The canonical time zone ID. * @param tzID The canonical time zone ID.
* @param type The display name type. See {@link #UTimeZoneNameType}. * @param type The display name type. See {@link #UTimeZoneNameType}.
* @param date The date. * @param date The date.
* @param name Receives the display name for the time zone at the given date. When this object does not have a localized display * @param name Receives the display name for the time zone at the given date. When this object does not have a localized display
* name for the time zone with the specified type and date, "b ogus" state is set. * name for the time zone with the specified type and date, "b ogus" state is set.
* @return A reference to the result. * @return A reference to the result.
* @draft ICU 50 * @stable ICU 50
*/ */
virtual UnicodeString& getDisplayName(const UnicodeString& tzID, UTimeZ oneNameType type, UDate date, UnicodeString& name) const; virtual UnicodeString& getDisplayName(const UnicodeString& tzID, UTimeZ oneNameType type, UDate date, UnicodeString& name) const;
/** /**
* <code>MatchInfoCollection</code> represents a collection of time zon e name matches used by * <code>MatchInfoCollection</code> represents a collection of time zon e name matches used by
* {@link TimeZoneNames#find}. * {@link TimeZoneNames#find}.
* @internal * @internal
*/ */
class U_I18N_API MatchInfoCollection : public UMemory { class U_I18N_API MatchInfoCollection : public UMemory {
public: public:
skipping to change at line 392 skipping to change at line 391
* @return A collection of matches (owned by the caller), or NULL if no matches are found. * @return A collection of matches (owned by the caller), or NULL if no matches are found.
* @see UTimeZoneNameType * @see UTimeZoneNameType
* @see MatchInfoCollection * @see MatchInfoCollection
* @internal * @internal
*/ */
virtual MatchInfoCollection* find(const UnicodeString& text, int32_t st art, uint32_t types, UErrorCode& status) const = 0; virtual MatchInfoCollection* find(const UnicodeString& text, int32_t st art, uint32_t types, UErrorCode& status) const = 0;
}; };
U_NAMESPACE_END U_NAMESPACE_END
#endif /* U_HIDE_DRAFT_API */
#endif #endif
#endif #endif
 End of changes. 24 change blocks. 
24 lines changed or deleted 22 lines changed or added


 ubidi.h   ubidi.h 
/* /*
*************************************************************************** *** *************************************************************************** ***
* *
* Copyright (C) 1999-2012, International Business Machines * Copyright (C) 1999-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
* *
*************************************************************************** *** *************************************************************************** ***
* file name: ubidi.h * file name: ubidi.h
* encoding: US-ASCII * encoding: US-ASCII
* tab size: 8 (not used) * tab size: 8 (not used)
* indentation:4 * indentation:4
* *
* created on: 1999jul27 * created on: 1999jul27
* created by: Markus W. Scherer, updated by Matitiahu Allouche * created by: Markus W. Scherer, updated by Matitiahu Allouche
skipping to change at line 390 skipping to change at line 390
* @see UBIDI_REORDER_INVERSE_FOR_NUMBERS_SPECIAL * @see UBIDI_REORDER_INVERSE_FOR_NUMBERS_SPECIAL
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
#define UBIDI_DEFAULT_RTL 0xff #define UBIDI_DEFAULT_RTL 0xff
/** /**
* Maximum explicit embedding level. * Maximum explicit embedding level.
* (The maximum resolved level can be up to <code>UBIDI_MAX_EXPLICIT_LEVEL+ 1</code>). * (The maximum resolved level can be up to <code>UBIDI_MAX_EXPLICIT_LEVEL+ 1</code>).
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
#define UBIDI_MAX_EXPLICIT_LEVEL 61 #define UBIDI_MAX_EXPLICIT_LEVEL 125
/** Bit flag for level input. /** Bit flag for level input.
* Overrides directional properties. * Overrides directional properties.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
#define UBIDI_LEVEL_OVERRIDE 0x80 #define UBIDI_LEVEL_OVERRIDE 0x80
/** /**
* Special value which can be returned by the mapping functions when a logi cal * Special value which can be returned by the mapping functions when a logi cal
* index has no corresponding visual index or vice-versa. This may happen * index has no corresponding visual index or vice-versa. This may happen
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added


 ubrk.h   ubrk.h 
skipping to change at line 242 skipping to change at line 242
ubrk_openRules(const UChar *rules, ubrk_openRules(const UChar *rules,
int32_t rulesLength, int32_t rulesLength,
const UChar *text, const UChar *text,
int32_t textLength, int32_t textLength,
UParseError *parseErr, UParseError *parseErr,
UErrorCode *status); UErrorCode *status);
/** /**
* Thread safe cloning operation * Thread safe cloning operation
* @param bi iterator to be cloned * @param bi iterator to be cloned
* @param stackBuffer user allocated space for the new clone. If NULL new m * @param stackBuffer <em>Deprecated functionality as of ICU 52, use NULL.<
emory will be allocated. /em><br>
* user allocated space for the new clone. If NULL new memory will be allo
cated.
* If buffer is not large enough, new memory will be allocated. * If buffer is not large enough, new memory will be allocated.
* Clients can use the U_BRK_SAFECLONE_BUFFERSIZE. This will probably be e * Clients can use the U_BRK_SAFECLONE_BUFFERSIZE.
nough to avoid memory allocations. * @param pBufferSize <em>Deprecated functionality as of ICU 52, use NULL o
* @param pBufferSize pointer to size of allocated space. r 1.</em><br>
* pointer to size of allocated space.
* If *pBufferSize == 0, a sufficient size for use in cloning will * If *pBufferSize == 0, a sufficient size for use in cloning will
* be returned ('pre-flighting') * be returned ('pre-flighting')
* If *pBufferSize is not enough for a stack-based safe clone, * If *pBufferSize is not enough for a stack-based safe clone,
* new memory will be allocated. * new memory will be allocated.
* @param status to indicate whether the operation went on smoothly or ther e were errors * @param status to indicate whether the operation went on smoothly or ther e were errors
* An informational status value, U_SAFECLONE_ALLOCATED_ERROR, is used if any allocations were necessary. * An informational status value, U_SAFECLONE_ALLOCATED_ERROR, is used if any allocations were necessary.
* @return pointer to the new clone * @return pointer to the new clone
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE UBreakIterator * U_EXPORT2 U_STABLE UBreakIterator * U_EXPORT2
ubrk_safeClone( ubrk_safeClone(
const UBreakIterator *bi, const UBreakIterator *bi,
void *stackBuffer, void *stackBuffer,
int32_t *pBufferSize, int32_t *pBufferSize,
UErrorCode *status); UErrorCode *status);
#ifndef U_HIDE_DEPRECATED_API
/** /**
* A recommended size (in bytes) for the memory buffer to be passed to ubr k_saveClone(). * A recommended size (in bytes) for the memory buffer to be passed to ubr k_saveClone().
* @stable ICU 2.0 * @deprecated ICU 52. Do not rely on ubrk_safeClone() cloning into any pr ovided buffer.
*/ */
#define U_BRK_SAFECLONE_BUFFERSIZE 528 #define U_BRK_SAFECLONE_BUFFERSIZE 1
#endif /* U_HIDE_DEPRECATED_API */
/** /**
* Close a UBreakIterator. * Close a UBreakIterator.
* Once closed, a UBreakIterator may no longer be used. * Once closed, a UBreakIterator may no longer be used.
* @param bi The break iterator to close. * @param bi The break iterator to close.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE void U_EXPORT2 U_STABLE void U_EXPORT2
ubrk_close(UBreakIterator *bi); ubrk_close(UBreakIterator *bi);
 End of changes. 5 change blocks. 
7 lines changed or deleted 14 lines changed or added


 ucal.h   ucal.h 
skipping to change at line 1367 skipping to change at line 1367
* Call ucal_getWeekendTransition() to get the time of transition. * Call ucal_getWeekendTransition() to get the time of transition.
* @stable ICU 4.4 * @stable ICU 4.4
*/ */
UCAL_WEEKEND_CEASE UCAL_WEEKEND_CEASE
}; };
/** @stable ICU 4.4 */ /** @stable ICU 4.4 */
typedef enum UCalendarWeekdayType UCalendarWeekdayType; typedef enum UCalendarWeekdayType UCalendarWeekdayType;
/** /**
* Returns whether the given day of the week is a weekday, a * Returns whether the given day of the week is a weekday, a weekend day,
* weekend day, or a day that transitions from one to the other, * or a day that transitions from one to the other, for the locale and
* in this calendar system. If a transition occurs at midnight, * calendar system associated with this UCalendar (the locale's region is
* often the most determinant factor). If a transition occurs at midnight,
* then the days before and after the transition will have the * then the days before and after the transition will have the
* type UCAL_WEEKDAY or UCAL_WEEKEND. If a transition occurs at a time * type UCAL_WEEKDAY or UCAL_WEEKEND. If a transition occurs at a time
* other than midnight, then the day of the transition will have * other than midnight, then the day of the transition will have
* the type UCAL_WEEKEND_ONSET or UCAL_WEEKEND_CEASE. In this case, the * the type UCAL_WEEKEND_ONSET or UCAL_WEEKEND_CEASE. In this case, the
* method getWeekendTransition() will return the point of * function ucal_getWeekendTransition() will return the point of
* transition. * transition.
* @param cal The UCalendar to query. * @param cal The UCalendar to query.
* @param dayOfWeek The day of the week whose type is desired (UCAL_SUNDAY. .UCAL_SATURDAY). * @param dayOfWeek The day of the week whose type is desired (UCAL_SUNDAY. .UCAL_SATURDAY).
* @param status The error code for the operation. * @param status The error code for the operation.
* @return The UCalendarWeekdayType for the day of the week. * @return The UCalendarWeekdayType for the day of the week.
* @stable ICU 4.4 * @stable ICU 4.4
*/ */
U_STABLE UCalendarWeekdayType U_EXPORT2 U_STABLE UCalendarWeekdayType U_EXPORT2
ucal_getDayOfWeekType(const UCalendar *cal, UCalendarDaysOfWeek dayOfWeek, UErrorCode* status); ucal_getDayOfWeekType(const UCalendar *cal, UCalendarDaysOfWeek dayOfWeek, UErrorCode* status);
/** /**
* Returns the time during the day at which the weekend begins or ends in * Returns the time during the day at which the weekend begins or ends in
* this calendar system. If ucal_getDayOfWeekType() rerturns UCAL_WEEKEND_ ONSET * this calendar system. If ucal_getDayOfWeekType() returns UCAL_WEEKEND_O NSET
* for the specified dayOfWeek, return the time at which the weekend begins . * for the specified dayOfWeek, return the time at which the weekend begins .
* If ucal_getDayOfWeekType() returns UCAL_WEEKEND_CEASE for the specified dayOfWeek, * If ucal_getDayOfWeekType() returns UCAL_WEEKEND_CEASE for the specified dayOfWeek,
* return the time at which the weekend ends. If ucal_getDayOfWeekType() re turns * return the time at which the weekend ends. If ucal_getDayOfWeekType() re turns
* some other UCalendarWeekdayType for the specified dayOfWeek, is it an er ror condition * some other UCalendarWeekdayType for the specified dayOfWeek, is it an er ror condition
* (U_ILLEGAL_ARGUMENT_ERROR). * (U_ILLEGAL_ARGUMENT_ERROR).
* @param cal The UCalendar to query. * @param cal The UCalendar to query.
* @param dayOfWeek The day of the week for which the weekend transition ti me is * @param dayOfWeek The day of the week for which the weekend transition ti me is
* desired (UCAL_SUNDAY..UCAL_SATURDAY). * desired (UCAL_SUNDAY..UCAL_SATURDAY).
* @param status The error code for the operation. * @param status The error code for the operation.
* @return The milliseconds after midnight at which the weekend begins or e nds. * @return The milliseconds after midnight at which the weekend begins or e nds.
skipping to change at line 1446 skipping to change at line 1447
* @param status A pointer to an UErrorCode to receive any errors * @param status A pointer to an UErrorCode to receive any errors
* @return The date difference for the specified field. * @return The date difference for the specified field.
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
U_STABLE int32_t U_EXPORT2 U_STABLE int32_t U_EXPORT2
ucal_getFieldDifference(UCalendar* cal, ucal_getFieldDifference(UCalendar* cal,
UDate target, UDate target,
UCalendarDateFields field, UCalendarDateFields field,
UErrorCode* status); UErrorCode* status);
#ifndef U_HIDE_DRAFT_API
/** /**
* Time zone transition types for ucal_getTimeZoneTransitionDate * Time zone transition types for ucal_getTimeZoneTransitionDate
* @draft ICU 50 * @stable ICU 50
*/ */
enum UTimeZoneTransitionType { enum UTimeZoneTransitionType {
/** /**
* Get the next transition after the current date, * Get the next transition after the current date,
* i.e. excludes the current date * i.e. excludes the current date
* @draft ICU 50 * @stable ICU 50
*/ */
UCAL_TZ_TRANSITION_NEXT, UCAL_TZ_TRANSITION_NEXT,
/** /**
* Get the next transition on or after the current date, * Get the next transition on or after the current date,
* i.e. may include the current date * i.e. may include the current date
* @draft ICU 50 * @stable ICU 50
*/ */
UCAL_TZ_TRANSITION_NEXT_INCLUSIVE, UCAL_TZ_TRANSITION_NEXT_INCLUSIVE,
/** /**
* Get the previous transition before the current date, * Get the previous transition before the current date,
* i.e. excludes the current date * i.e. excludes the current date
* @draft ICU 50 * @stable ICU 50
*/ */
UCAL_TZ_TRANSITION_PREVIOUS, UCAL_TZ_TRANSITION_PREVIOUS,
/** /**
* Get the previous transition on or before the current date, * Get the previous transition on or before the current date,
* i.e. may include the current date * i.e. may include the current date
* @draft ICU 50 * @stable ICU 50
*/ */
UCAL_TZ_TRANSITION_PREVIOUS_INCLUSIVE UCAL_TZ_TRANSITION_PREVIOUS_INCLUSIVE
}; };
/** @draft ICU 50 */ typedef enum UTimeZoneTransitionType UTimeZoneTransitionType; /**< @stable
typedef enum UTimeZoneTransitionType UTimeZoneTransitionType; ICU 50 */
/** /**
* Get the UDate for the next/previous time zone transition relative to * Get the UDate for the next/previous time zone transition relative to
* the calendar's current date, in the time zone to which the calendar * the calendar's current date, in the time zone to which the calendar
* is currently set. If there is no known time zone transition of the * is currently set. If there is no known time zone transition of the
* requested type relative to the calendar's date, the function returns * requested type relative to the calendar's date, the function returns
* FALSE. * FALSE.
* @param cal The UCalendar to query. * @param cal The UCalendar to query.
* @param type The type of transition desired. * @param type The type of transition desired.
* @param transition A pointer to a UDate to be set to the transition time. * @param transition A pointer to a UDate to be set to the transition time.
* If the function returns FALSE, the value set is unspecified. * If the function returns FALSE, the value set is unspecified.
* @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 a valid transition time is set in *transition, FALSE * @return TRUE if a valid transition time is set in *transition, FALSE
* otherwise. * otherwise.
* @draft ICU 50 * @stable ICU 50
*/ */
U_DRAFT UBool U_EXPORT2 U_DRAFT UBool U_EXPORT2
ucal_getTimeZoneTransitionDate(const UCalendar* cal, UTimeZoneTransitionTyp e type, ucal_getTimeZoneTransitionDate(const UCalendar* cal, UTimeZoneTransitionTyp e type,
UDate* transition, UErrorCode* status); UDate* transition, UErrorCode* status);
#ifndef U_HIDE_DRAFT_API
/**
* Converts a system time zone ID to an equivalent Windows time zone ID. For
example,
* Windows time zone ID "Pacific Standard Time" is returned for input "Ameri
ca/Los_Angeles".
*
* <p>There are system time zones that cannot be mapped to Windows zones. Wh
en the input
* system time zone ID is unknown or unmappable to a Windows time zone, then
this
* function returns 0 as the result length, but the operation itself remains
successful
* (no error status set on return).
*
* <p>This implementation utilizes <a href="http://unicode.org/cldr/charts/s
upplemental/zone_tzid.html">
* Zone-Tzid mapping data</a>. The mapping data is updated time to time. To
get the latest changes,
* please read the ICU user guide section <a href="http://userguide.icu-proj
ect.org/datetime/timezone#TOC-Updating-the-Time-Zone-Data">
* Updating the Time Zone Data</a>.
*
* @param id A system time zone ID.
* @param len The length of <code>id</code>, or -1 if null-termina
ted.
* @param winid A buffer to receive a Windows time zone ID.
* @param winidCapacity The capacity of the result buffer <code>winid</code>
.
* @param status Receives the status.
* @return The result string length, not including the terminat
ing null.
* @see ucal_getTimeZoneIDForWindowsID
*
* @draft ICU 52
*/
U_DRAFT int32_t U_EXPORT2
ucal_getWindowsTimeZoneID(const UChar* id, int32_t len,
UChar* winid, int32_t winidCapacity, UErrorCode
* status);
/**
* Converts a Windows time zone ID to an equivalent system time zone ID
* for a region. For example, system time zone ID "America/Los_Angeles" is r
eturned
* for input Windows ID "Pacific Standard Time" and region "US" (or <code>nu
ll</code>),
* "America/Vancouver" is returned for the same Windows ID "Pacific Standard
Time" and
* region "CA".
*
* <p>Not all Windows time zones can be mapped to system time zones. When th
e input
* Windows time zone ID is unknown or unmappable to a system time zone, then
this
* function returns 0 as the result length, but the operation itself remains
successful
* (no error status set on return).
*
* <p>This implementation utilizes <a href="http://unicode.org/cldr/charts/s
upplemental/zone_tzid.html">
* Zone-Tzid mapping data</a>. The mapping data is updated time to time. To
get the latest changes,
* please read the ICU user guide section <a href="http://userguide.icu-proj
ect.org/datetime/timezone#TOC-Updating-the-Time-Zone-Data">
* Updating the Time Zone Data</a>.
*
* @param winid A Windows time zone ID.
* @param len The length of <code>winid</code>, or -1 if null-term
inated.
* @param region A null-terminated region code, or <code>NULL</code>
if no regional preference.
* @param id A buffer to receive a system time zone ID.
* @param idCapacity The capacity of the result buffer <code>id</code>.
* @param status Receives the status.
* @return The result string length, not including the terminat
ing null.
* @see ucal_getWindowsTimeZoneID
*
* @draft ICU 52
*/
U_DRAFT int32_t U_EXPORT2
ucal_getTimeZoneIDForWindowsID(const UChar* winid, int32_t len, const char*
region,
UChar* id, int32_t idCapacity, UErrorCode*
status);
#endif /* U_HIDE_DRAFT_API */ #endif /* U_HIDE_DRAFT_API */
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif #endif
 End of changes. 12 change blocks. 
14 lines changed or deleted 101 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 "6.2" #define U_UNICODE_VERSION "6.3"
/** /**
* \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 483 skipping to change at line 483
/** Enumerated property Sentence_Break (new in Unicode 4.1). /** Enumerated property Sentence_Break (new in Unicode 4.1).
Used in UAX #29: Text Boundaries Used in UAX #29: Text Boundaries
(http://www.unicode.org/reports/tr29/) (http://www.unicode.org/reports/tr29/)
Returns USentenceBreak values. @stable ICU 3.4 */ Returns USentenceBreak values. @stable ICU 3.4 */
UCHAR_SENTENCE_BREAK=0x1013, UCHAR_SENTENCE_BREAK=0x1013,
/** Enumerated property Word_Break (new in Unicode 4.1). /** Enumerated property Word_Break (new in Unicode 4.1).
Used in UAX #29: Text Boundaries Used in UAX #29: Text Boundaries
(http://www.unicode.org/reports/tr29/) (http://www.unicode.org/reports/tr29/)
Returns UWordBreakValues values. @stable ICU 3.4 */ Returns UWordBreakValues values. @stable ICU 3.4 */
UCHAR_WORD_BREAK=0x1014, UCHAR_WORD_BREAK=0x1014,
/** Enumerated property Bidi_Paired_Bracket_Type (new in Unicode 6.3).
Used in UAX #9: Unicode Bidirectional Algorithm
(http://www.unicode.org/reports/tr9/)
Returns UBidiPairedBracketType values. @stable ICU 52 */
UCHAR_BIDI_PAIRED_BRACKET_TYPE=0x1015,
/** One more than the last constant for enumerated/integer Unicode prop erties. @stable ICU 2.2 */ /** One more than the last constant for enumerated/integer Unicode prop erties. @stable ICU 2.2 */
UCHAR_INT_LIMIT=0x1015, UCHAR_INT_LIMIT=0x1016,
/** Bitmask property General_Category_Mask. /** Bitmask property General_Category_Mask.
This is the General_Category property returned as a bit mask. This is the General_Category property returned as a bit mask.
When used in u_getIntPropertyValue(c), same as U_MASK(u_charType(c) ), When used in u_getIntPropertyValue(c), same as U_MASK(u_charType(c) ),
returns bit masks for UCharCategory values where exactly one bit is set. returns bit masks for UCharCategory values where exactly one bit is set.
When used with u_getPropertyValueName() and u_getPropertyValueEnum( ), When used with u_getPropertyValueName() and u_getPropertyValueEnum( ),
a multi-bit mask is used for sets of categories like "Letters". a multi-bit mask is used for sets of categories like "Letters".
Mask values should be cast to uint32_t. Mask values should be cast to uint32_t.
@stable ICU 2.4 */ @stable ICU 2.4 */
UCHAR_GENERAL_CATEGORY_MASK=0x2000, UCHAR_GENERAL_CATEGORY_MASK=0x2000,
skipping to change at line 519 skipping to change at line 524
Corresponds to u_charAge. @stable ICU 2.4 */ Corresponds to u_charAge. @stable ICU 2.4 */
UCHAR_AGE=0x4000, UCHAR_AGE=0x4000,
/** First constant for string Unicode properties. @stable ICU 2.4 */ /** First constant for string Unicode properties. @stable ICU 2.4 */
UCHAR_STRING_START=UCHAR_AGE, UCHAR_STRING_START=UCHAR_AGE,
/** String property Bidi_Mirroring_Glyph. /** String property Bidi_Mirroring_Glyph.
Corresponds to u_charMirror. @stable ICU 2.4 */ Corresponds to u_charMirror. @stable ICU 2.4 */
UCHAR_BIDI_MIRRORING_GLYPH=0x4001, UCHAR_BIDI_MIRRORING_GLYPH=0x4001,
/** String property Case_Folding. /** String property Case_Folding.
Corresponds to u_strFoldCase in ustring.h. @stable ICU 2.4 */ Corresponds to u_strFoldCase in ustring.h. @stable ICU 2.4 */
UCHAR_CASE_FOLDING=0x4002, UCHAR_CASE_FOLDING=0x4002,
#ifndef U_HIDE_DEPRECATED_API
/** Deprecated string property ISO_Comment. /** Deprecated string property ISO_Comment.
Corresponds to u_getISOComment. @deprecated ICU 49 */ Corresponds to u_getISOComment. @deprecated ICU 49 */
UCHAR_ISO_COMMENT=0x4003, UCHAR_ISO_COMMENT=0x4003,
#endif /* U_HIDE_DEPRECATED_API */
/** String property Lowercase_Mapping. /** String property Lowercase_Mapping.
Corresponds to u_strToLower in ustring.h. @stable ICU 2.4 */ Corresponds to u_strToLower in ustring.h. @stable ICU 2.4 */
UCHAR_LOWERCASE_MAPPING=0x4004, UCHAR_LOWERCASE_MAPPING=0x4004,
/** String property Name. /** String property Name.
Corresponds to u_charName. @stable ICU 2.4 */ Corresponds to u_charName. @stable ICU 2.4 */
UCHAR_NAME=0x4005, UCHAR_NAME=0x4005,
/** String property Simple_Case_Folding. /** String property Simple_Case_Folding.
Corresponds to u_foldCase. @stable ICU 2.4 */ Corresponds to u_foldCase. @stable ICU 2.4 */
UCHAR_SIMPLE_CASE_FOLDING=0x4006, UCHAR_SIMPLE_CASE_FOLDING=0x4006,
/** String property Simple_Lowercase_Mapping. /** String property Simple_Lowercase_Mapping.
skipping to change at line 543 skipping to change at line 550
UCHAR_SIMPLE_LOWERCASE_MAPPING=0x4007, UCHAR_SIMPLE_LOWERCASE_MAPPING=0x4007,
/** String property Simple_Titlecase_Mapping. /** String property Simple_Titlecase_Mapping.
Corresponds to u_totitle. @stable ICU 2.4 */ Corresponds to u_totitle. @stable ICU 2.4 */
UCHAR_SIMPLE_TITLECASE_MAPPING=0x4008, UCHAR_SIMPLE_TITLECASE_MAPPING=0x4008,
/** String property Simple_Uppercase_Mapping. /** String property Simple_Uppercase_Mapping.
Corresponds to u_toupper. @stable ICU 2.4 */ Corresponds to u_toupper. @stable ICU 2.4 */
UCHAR_SIMPLE_UPPERCASE_MAPPING=0x4009, UCHAR_SIMPLE_UPPERCASE_MAPPING=0x4009,
/** String property Titlecase_Mapping. /** String property Titlecase_Mapping.
Corresponds to u_strToTitle in ustring.h. @stable ICU 2.4 */ Corresponds to u_strToTitle in ustring.h. @stable ICU 2.4 */
UCHAR_TITLECASE_MAPPING=0x400A, UCHAR_TITLECASE_MAPPING=0x400A,
#ifndef U_HIDE_DEPRECATED_API
/** String property Unicode_1_Name. /** String property Unicode_1_Name.
This property is of little practical value. This property is of little practical value.
Beginning with ICU 49, ICU APIs return an empty string for this pro perty. Beginning with ICU 49, ICU APIs return an empty string for this pro perty.
Corresponds to u_charName(U_UNICODE_10_CHAR_NAME). @deprecated ICU 49 */ Corresponds to u_charName(U_UNICODE_10_CHAR_NAME). @deprecated ICU 49 */
UCHAR_UNICODE_1_NAME=0x400B, UCHAR_UNICODE_1_NAME=0x400B,
#endif /* U_HIDE_DEPRECATED_API */
/** 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,
/** String property Bidi_Paired_Bracket (new in Unicode 6.3).
Corresponds to u_getBidiPairedBracket. @stable ICU 52 */
UCHAR_BIDI_PAIRED_BRACKET=0x400D,
/** 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=0x400E,
/** Provisional property Script_Extensions (new in Unicode 6.0).
As a provisional property, it may be modified or removed /** Miscellaneous property Script_Extensions (new in Unicode 6.0).
in future versions of the Unicode Standard, and thus in ICU.
Some characters are commonly used in multiple scripts. Some characters are commonly used in multiple scripts.
For more information, see UAX #24: http://www.unicode.org/reports/t r24/. For more information, see UAX #24: http://www.unicode.org/reports/t r24/.
Corresponds to uscript_hasScript and uscript_getScriptExtensions in uscript.h. Corresponds to uscript_hasScript and uscript_getScriptExtensions in uscript.h.
@stable ICU 4.6 */ @stable ICU 4.6 */
UCHAR_SCRIPT_EXTENSIONS=0x7000, UCHAR_SCRIPT_EXTENSIONS=0x7000,
/** First constant for Unicode properties with unusual value types. @st able ICU 4.6 */ /** First constant for Unicode properties with unusual value types. @st able ICU 4.6 */
UCHAR_OTHER_PROPERTY_START=UCHAR_SCRIPT_EXTENSIONS, UCHAR_OTHER_PROPERTY_START=UCHAR_SCRIPT_EXTENSIONS,
/** One more than the last constant for Unicode properties with unusual value types. /** One more than the last constant for Unicode properties with unusual value types.
* @stable ICU 4.6 */ * @stable ICU 4.6 */
UCHAR_OTHER_PROPERTY_LIMIT=0x7001, UCHAR_OTHER_PROPERTY_LIMIT=0x7001,
skipping to change at line 811 skipping to change at line 822
/** RLE @stable ICU 2.0 */ /** RLE @stable ICU 2.0 */
U_RIGHT_TO_LEFT_EMBEDDING = 14, U_RIGHT_TO_LEFT_EMBEDDING = 14,
/** RLO @stable ICU 2.0 */ /** RLO @stable ICU 2.0 */
U_RIGHT_TO_LEFT_OVERRIDE = 15, U_RIGHT_TO_LEFT_OVERRIDE = 15,
/** PDF @stable ICU 2.0 */ /** PDF @stable ICU 2.0 */
U_POP_DIRECTIONAL_FORMAT = 16, U_POP_DIRECTIONAL_FORMAT = 16,
/** NSM @stable ICU 2.0 */ /** NSM @stable ICU 2.0 */
U_DIR_NON_SPACING_MARK = 17, U_DIR_NON_SPACING_MARK = 17,
/** BN @stable ICU 2.0 */ /** BN @stable ICU 2.0 */
U_BOUNDARY_NEUTRAL = 18, U_BOUNDARY_NEUTRAL = 18,
/** FSI @stable ICU 52 */
U_FIRST_STRONG_ISOLATE = 19,
/** LRI @stable ICU 52 */
U_LEFT_TO_RIGHT_ISOLATE = 20,
/** RLI @stable ICU 52 */
U_RIGHT_TO_LEFT_ISOLATE = 21,
/** PDI @stable ICU 52 */
U_POP_DIRECTIONAL_ISOLATE = 22,
/** @stable ICU 2.0 */ /** @stable ICU 2.0 */
U_CHAR_DIRECTION_COUNT U_CHAR_DIRECTION_COUNT
} UCharDirection; } UCharDirection;
/** /**
* Bidi Paired Bracket Type constants.
*
* @see UCHAR_BIDI_PAIRED_BRACKET_TYPE
* @stable ICU 52
*/
typedef enum UBidiPairedBracketType {
/*
* Note: UBidiPairedBracketType constants are parsed by preparseucd.py.
* It matches lines like
* U_BPT_<Unicode Bidi_Paired_Bracket_Type value name>
*/
/** Not a paired bracket. @stable ICU 52 */
U_BPT_NONE,
/** Open paired bracket. @stable ICU 52 */
U_BPT_OPEN,
/** Close paired bracket. @stable ICU 52 */
U_BPT_CLOSE,
/** @stable ICU 52 */
U_BPT_COUNT /* 3 */
} UBidiPairedBracketType;
/**
* Constants for Unicode blocks, see the Unicode Data file Blocks.txt * Constants for Unicode blocks, see the Unicode Data file Blocks.txt
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
enum UBlockCode { enum UBlockCode {
/* /*
* Note: UBlockCode constants are parsed by preparseucd.py. * Note: UBlockCode constants are parsed by preparseucd.py.
* It matches lines like * It matches lines like
* UBLOCK_<Unicode Block value name> = <integer>, * UBLOCK_<Unicode Block value name> = <integer>,
*/ */
skipping to change at line 1682 skipping to change at line 1724
U_WB_MIDLETTER = 4, /*[ML]*/ U_WB_MIDLETTER = 4, /*[ML]*/
U_WB_MIDNUM = 5, /*[MN]*/ U_WB_MIDNUM = 5, /*[MN]*/
U_WB_NUMERIC = 6, /*[NU]*/ U_WB_NUMERIC = 6, /*[NU]*/
U_WB_EXTENDNUMLET = 7, /*[EX]*/ U_WB_EXTENDNUMLET = 7, /*[EX]*/
U_WB_CR = 8, /*[CR]*/ /* from here on: new in Unicode 5. 1/ICU 4.0 */ U_WB_CR = 8, /*[CR]*/ /* from here on: new in Unicode 5. 1/ICU 4.0 */
U_WB_EXTEND = 9, /*[Extend]*/ U_WB_EXTEND = 9, /*[Extend]*/
U_WB_LF = 10, /*[LF]*/ U_WB_LF = 10, /*[LF]*/
U_WB_MIDNUMLET =11, /*[MB]*/ U_WB_MIDNUMLET =11, /*[MB]*/
U_WB_NEWLINE =12, /*[NL]*/ U_WB_NEWLINE =12, /*[NL]*/
U_WB_REGIONAL_INDICATOR = 13, /*[RI]*/ /* new in Unicode 6.2/ICU 50 * / U_WB_REGIONAL_INDICATOR = 13, /*[RI]*/ /* new in Unicode 6.2/ICU 50 * /
U_WB_COUNT = 14 U_WB_HEBREW_LETTER = 14, /*[HL]*/ /* from here on: new in Unicode 6.
3/ICU 52 */
U_WB_SINGLE_QUOTE = 15, /*[SQ]*/
U_WB_DOUBLE_QUOTE = 16, /*[DQ]*/
U_WB_COUNT = 17
} UWordBreakValues; } UWordBreakValues;
/** /**
* Sentence Break constants. * Sentence Break constants.
* *
* @see UCHAR_SENTENCE_BREAK * @see UCHAR_SENTENCE_BREAK
* @stable ICU 3.4 * @stable ICU 3.4
*/ */
typedef enum USentenceBreak { typedef enum USentenceBreak {
/* /*
skipping to change at line 2485 skipping to change at line 2530
u_isMirrored(UChar32 c); u_isMirrored(UChar32 c);
/** /**
* Maps the specified character to a "mirror-image" character. * Maps the specified character to a "mirror-image" character.
* For characters with the Bidi_Mirrored property, implementations * For characters with the Bidi_Mirrored property, implementations
* sometimes need a "poor man's" mapping to another Unicode * sometimes need a "poor man's" mapping to another Unicode
* character (code point) such that the default glyph may serve * character (code point) such that the default glyph may serve
* as the mirror-image of the default glyph of the specified * as the mirror-image of the default glyph of the specified
* character. This is useful for text conversion to and from * character. This is useful for text conversion to and from
* codepages with visual order, and for displays without glyph * codepages with visual order, and for displays without glyph
* selecetion capabilities. * selection capabilities.
* *
* @param c the code point to be mapped * @param c the code point to be mapped
* @return another Unicode code point that may serve as a mirror-image * @return another Unicode code point that may serve as a mirror-image
* substitute, or c itself if there is no such mapping or c * substitute, or c itself if there is no such mapping or c
* does not have the Bidi_Mirrored property * does not have the Bidi_Mirrored property
* *
* @see UCHAR_BIDI_MIRRORED * @see UCHAR_BIDI_MIRRORED
* @see u_isMirrored * @see u_isMirrored
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE UChar32 U_EXPORT2 U_STABLE UChar32 U_EXPORT2
u_charMirror(UChar32 c); u_charMirror(UChar32 c);
/** /**
* Maps the specified character to its paired bracket character.
* For Bidi_Paired_Bracket_Type!=None, this is the same as u_charMirror().
* Otherwise c itself is returned.
* See http://www.unicode.org/reports/tr9/
*
* @param c the code point to be mapped
* @return the paired bracket code point,
* or c itself if there is no such mapping
* (Bidi_Paired_Bracket_Type=None)
*
* @see UCHAR_BIDI_PAIRED_BRACKET
* @see UCHAR_BIDI_PAIRED_BRACKET_TYPE
* @see u_charMirror
* @stable ICU 52
*/
U_STABLE UChar32 U_EXPORT2
u_getBidiPairedBracket(UChar32 c);
/**
* Returns the general category value for the code point. * Returns the general category value for the code point.
* *
* Same as java.lang.Character.getType(). * Same as java.lang.Character.getType().
* *
* @param c the code point to be tested * @param c the code point to be tested
* @return the general category (UCharCategory) value * @return the general category (UCharCategory) value
* *
* @see UCharCategory * @see UCharCategory
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
 End of changes. 14 change blocks. 
8 lines changed or deleted 73 lines changed or added


 ucharstriebuilder.h   ucharstriebuilder.h 
/* /*
*************************************************************************** **** *************************************************************************** ****
* Copyright (C) 2010-2012, International Business Machines * Copyright (C) 2010-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
*************************************************************************** **** *************************************************************************** ****
* file name: ucharstriebuilder.h * file name: ucharstriebuilder.h
* encoding: US-ASCII * encoding: US-ASCII
* tab size: 8 (not used) * tab size: 8 (not used)
* indentation:4 * indentation:4
* *
* created on: 2010nov14 * created on: 2010nov14
* created by: Markus W. Scherer * created by: Markus W. Scherer
*/ */
skipping to change at line 73 skipping to change at line 73
* function chaining. (See User Guide for details.) * function chaining. (See User Guide for details.)
* @return *this * @return *this
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
UCharsTrieBuilder &add(const UnicodeString &s, int32_t value, UErrorCod e &errorCode); UCharsTrieBuilder &add(const UnicodeString &s, int32_t value, UErrorCod e &errorCode);
/** /**
* Builds a UCharsTrie for the add()ed data. * Builds a UCharsTrie for the add()ed data.
* Once built, no further data can be add()ed until clear() is called. * Once built, no further data can be add()ed until clear() is called.
* *
* A UCharsTrie cannot be empty. At least one (string, value) pair
* must have been add()ed.
*
* This method passes ownership of the builder's internal result array to the new trie object. * This method passes ownership of the builder's internal result array to the new trie object.
* Another call to any build() variant will re-serialize the trie. * Another call to any build() variant will re-serialize the trie.
* After clear() has been called, a new array will be used as well. * After clear() has been called, a new array will be used as well.
* @param buildOption Build option, see UStringTrieBuildOption. * @param buildOption Build option, see UStringTrieBuildOption.
* @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
* function chaining. (See User Guide for details.) * function chaining. (See User Guide for details.)
* @return A new UCharsTrie for the add()ed data. * @return A new UCharsTrie for the add()ed data.
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
UCharsTrie *build(UStringTrieBuildOption buildOption, UErrorCode &error Code); UCharsTrie *build(UStringTrieBuildOption buildOption, UErrorCode &error Code);
/** /**
* Builds a UCharsTrie for the add()ed data and UChar-serializes it. * Builds a UCharsTrie for the add()ed data and UChar-serializes it.
* Once built, no further data can be add()ed until clear() is called. * Once built, no further data can be add()ed until clear() is called.
* *
* A UCharsTrie cannot be empty. At least one (string, value) pair
* must have been add()ed.
*
* Multiple calls to buildUnicodeString() set the UnicodeStrings to the * Multiple calls to buildUnicodeString() set the UnicodeStrings to the
* builder's same UChar array, without rebuilding. * builder's same UChar array, without rebuilding.
* If buildUnicodeString() is called after build(), the trie will be * If buildUnicodeString() is called after build(), the trie will be
* re-serialized into a new array. * re-serialized into a new array.
* If build() is called after buildUnicodeString(), the trie object wil l become * If build() is called after buildUnicodeString(), the trie object wil l become
* the owner of the previously returned array. * the owner of the previously returned array.
* After clear() has been called, a new array will be used as well. * After clear() has been called, a new array will be used as well.
* @param buildOption Build option, see UStringTrieBuildOption. * @param buildOption Build option, see UStringTrieBuildOption.
* @param result A UnicodeString which will be set to the UChar-seriali zed * @param result A UnicodeString which will be set to the UChar-seriali zed
* UCharsTrie for the add()ed data. * UCharsTrie for the add()ed data.
 End of changes. 3 change blocks. 
1 lines changed or deleted 7 lines changed or added


 uclean.h   uclean.h 
/* /*
*************************************************************************** *** *************************************************************************** ***
* Copyright (C) 2001-2012, International Business Machines * Copyright (C) 2001-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
*************************************************************************** *** *************************************************************************** ***
* file name: uclean.h * file name: uclean.h
* encoding: US-ASCII * encoding: US-ASCII
* tab size: 8 (not used) * tab size: 8 (not used)
* indentation:4 * indentation:4
* *
* created on: 2001July05 * created on: 2001July05
* created by: George Rhoten * created by: George Rhoten
*/ */
skipping to change at line 103 skipping to change at line 103
* <strong>Use this function with great care!</strong> * <strong>Use this function with great care!</strong>
* </p> * </p>
* *
* @stable ICU 2.0 * @stable ICU 2.0
* @system * @system
*/ */
U_STABLE void U_EXPORT2 U_STABLE void U_EXPORT2
u_cleanup(void); u_cleanup(void);
/** /**
* Pointer type for a user supplied memory allocation function.
* @param context user supplied value, obtained from from u_setMemoryFunc
tions().
* @param size The number of bytes to be allocated
* @return Pointer to the newly allocated memory, or NULL if the a
llocation failed.
* @stable ICU 2.8
* @system
*/
typedef void *U_CALLCONV UMemAllocFn(const void *context, size_t size);
/**
* Pointer type for a user supplied memory re-allocation function.
* @param context user supplied value, obtained from from u_setMemoryFunc
tions().
* @param size The number of bytes to be allocated
* @return Pointer to the newly allocated memory, or NULL if the a
llocation failed.
* @stable ICU 2.8
* @system
*/
typedef void *U_CALLCONV UMemReallocFn(const void *context, void *mem, size
_t size);
/**
* Pointer type for a user supplied memory free function. Behavior shou
ld be
* similar the standard C library free().
* @param context user supplied value, obtained from from u_setMemoryFunc
tions().
* @param mem Pointer to the memory block to be resized
* @param size The new size for the block
* @return Pointer to the resized memory block, or NULL if the res
izing failed.
* @stable ICU 2.8
* @system
*/
typedef void U_CALLCONV UMemFreeFn (const void *context, void *mem);
/**
* Set the functions that ICU will use for memory allocation.
* Use of this function is optional; by default (without this function), I
CU will
* use the standard C library malloc() and free() functions.
* This function can only be used when ICU is in an initial, unused state,
before
* u_init() has been called.
* @param context This pointer value will be saved, and then (later) passe
d as
* a parameter to the memory functions each time they
* are called.
* @param a Pointer to a user-supplied malloc function.
* @param r Pointer to a user-supplied realloc function.
* @param f Pointer to a user-supplied free function.
* @param status Receives error values.
* @stable ICU 2.8
* @system
*/
U_STABLE void U_EXPORT2
u_setMemoryFunctions(const void *context, UMemAllocFn *a, UMemReallocFn *r,
UMemFreeFn *f,
UErrorCode *status);
/**************************************************************************
*******
*
* Deprecated Functions
*
* The following functions for user supplied mutexes are no longer suppo
rted.
* Any attempt to use them will return a U_UNSUPPORTED_ERROR.
*
**************************************************************************
********/
/**
* An opaque pointer type that represents an ICU mutex. * An opaque pointer type that represents an ICU mutex.
* For user-implemented mutexes, the value will typically point to a * For user-implemented mutexes, the value will typically point to a
* struct or object that implements the mutex. * struct or object that implements the mutex.
* @stable ICU 2.8 * @deprecated ICU 52. This type is no longer supported.
* @system * @system
*/ */
typedef void *UMTX; typedef void *UMTX;
/** /**
* Function Pointer type for a user supplied mutex initialization functio n. * Function Pointer type for a user supplied mutex initialization functio n.
* The user-supplied function will be called by ICU whenever ICU needs to create a * The user-supplied function will be called by ICU whenever ICU needs to create a
* new mutex. The function implementation should create a mutex, and sto re a pointer * new mutex. The function implementation should create a mutex, and sto re a pointer
* to something that uniquely identifies the mutex into the UMTX that is supplied * to something that uniquely identifies the mutex into the UMTX that is supplied
* as a paramter. * as a paramter.
* @param context user supplied value, obtained from from u_setMutexFunct ions(). * @param context user supplied value, obtained from from u_setMutexFunct ions().
* @param mutex Receives a pointer that identifies the new mutex. * @param mutex Receives a pointer that identifies the new mutex.
* The mutex init function must set the UMTX to a non-null value. * The mutex init function must set the UMTX to a non-null value.
* Subsequent calls by ICU to lock, unlock, or destroy a m utex will * Subsequent calls by ICU to lock, unlock, or destroy a m utex will
* identify the mutex by the UMTX value. * identify the mutex by the UMTX value.
* @param status Error status. Report errors back to ICU by setting thi s variable * @param status Error status. Report errors back to ICU by setting thi s variable
* with an error code. * with an error code.
* @stable ICU 2.8 * @deprecated ICU 52. This function is no longer supported.
* @system * @system
*/ */
typedef void U_CALLCONV UMtxInitFn (const void *context, UMTX *mutex, UErr orCode* status); typedef void U_CALLCONV UMtxInitFn (const void *context, UMTX *mutex, UErr orCode* status);
/** /**
* Function Pointer type for a user supplied mutex functions. * Function Pointer type for a user supplied mutex functions.
* One of the user-supplied functions with this signature will be called by ICU * One of the user-supplied functions with this signature will be called by ICU
* whenever ICU needs to lock, unlock, or destroy a mutex. * whenever ICU needs to lock, unlock, or destroy a mutex.
* @param context user supplied value, obtained from from u_setMutexFunct ions(). * @param context user supplied value, obtained from from u_setMutexFunct ions().
* @param mutex specify the mutex on which to operate. * @param mutex specify the mutex on which to operate.
* @stable ICU 2.8 * @deprecated ICU 52. This function is no longer supported.
* @system * @system
*/ */
typedef void U_CALLCONV UMtxFn (const void *context, UMTX *mutex); typedef void U_CALLCONV UMtxFn (const void *context, UMTX *mutex);
/** /**
* Set the functions that ICU will use for mutex operations * Set the functions that ICU will use for mutex operations
* Use of this function is optional; by default (without this function), ICU will * Use of this function is optional; by default (without this function), ICU will
* directly access system functions for mutex operations * directly access system functions for mutex operations
* This function can only be used when ICU is in an initial, unused state , before * This function can only be used when ICU is in an initial, unused state , before
* u_init() has been called. * u_init() has been called.
* @param context This pointer value will be saved, and then (later) pass ed as * @param context This pointer value will be saved, and then (later) pass ed as
* a parameter to the user-supplied mutex functions each t ime they * a parameter to the user-supplied mutex functions each t ime they
* are called. * are called.
* @param init Pointer to a mutex initialization function. Must be no n-null. * @param init Pointer to a mutex initialization function. Must be no n-null.
* @param destroy Pointer to the mutex destroy function. Must be non-nul l. * @param destroy Pointer to the mutex destroy function. Must be non-nul l.
* @param lock pointer to the mutex lock function. Must be non-null. * @param lock pointer to the mutex lock function. Must be non-null.
* @param unlock Pointer to the mutex unlock function. Must be non-null . * @param unlock Pointer to the mutex unlock function. Must be non-null .
* @param status Receives error values. * @param status Receives error values.
* @stable ICU 2.8 * @deprecated ICU 52. This function is no longer supported.
* @system * @system
*/ */
U_STABLE void U_EXPORT2 U_DEPRECATED void U_EXPORT2
u_setMutexFunctions(const void *context, UMtxInitFn *init, UMtxFn *destroy, UMtxFn *lock, UMtxFn *unlock, u_setMutexFunctions(const void *context, UMtxInitFn *init, UMtxFn *destroy, UMtxFn *lock, UMtxFn *unlock,
UErrorCode *status); UErrorCode *status);
/** /**
* Pointer type for a user supplied atomic increment or decrement functio n. * Pointer type for a user supplied atomic increment or decrement functio n.
* @param context user supplied value, obtained from from u_setAtomicIncD ecFunctions(). * @param context user supplied value, obtained from from u_setAtomicIncD ecFunctions().
* @param p Pointer to a 32 bit int to be incremented or decremented * @param p Pointer to a 32 bit int to be incremented or decremented
* @return The value of the variable after the inc or dec operation. * @return The value of the variable after the inc or dec operation.
* @stable ICU 2.8 * @deprecated ICU 52. This function is no longer supported.
* @system * @system
*/ */
typedef int32_t U_CALLCONV UMtxAtomicFn(const void *context, int32_t *p); typedef int32_t U_CALLCONV UMtxAtomicFn(const void *context, int32_t *p);
/** /**
* Set the functions that ICU will use for atomic increment and decrement of int32_t values. * Set the functions that ICU will use for atomic increment and decrement of int32_t values.
* Use of this function is optional; by default (without this function), I CU will * Use of this function is optional; by default (without this function), I CU will
* use its own internal implementation of atomic increment/decrement. * use its own internal implementation of atomic increment/decrement.
* This function can only be used when ICU is in an initial, unused state, before * This function can only be used when ICU is in an initial, unused state, before
* u_init() has been called. * u_init() has been called.
* @param context This pointer value will be saved, and then (later) passe d as * @param context This pointer value will be saved, and then (later) passe d as
* a parameter to the increment and decrement functions eac h time they * a parameter to the increment and decrement functions eac h time they
* are called. This function can only be called * are called. This function can only be called
* @param inc Pointer to a function to do an atomic increment operatio n. Must be non-null. * @param inc Pointer to a function to do an atomic increment operatio n. Must be non-null.
* @param dec Pointer to a function to do an atomic decrement operatio n. Must be non-null. * @param dec Pointer to a function to do an atomic decrement operatio n. Must be non-null.
* @param status Receives error values. * @param status Receives error values.
* @stable ICU 2.8 * @deprecated ICU 52. This function is no longer supported.
* @system * @system
*/ */
U_STABLE void U_EXPORT2 U_DEPRECATED void U_EXPORT2
u_setAtomicIncDecFunctions(const void *context, UMtxAtomicFn *inc, UMtxAtom icFn *dec, u_setAtomicIncDecFunctions(const void *context, UMtxAtomicFn *inc, UMtxAtom icFn *dec,
UErrorCode *status); UErrorCode *status);
/**
* Pointer type for a user supplied memory allocation function.
* @param context user supplied value, obtained from from u_setMemoryFunc
tions().
* @param size The number of bytes to be allocated
* @return Pointer to the newly allocated memory, or NULL if the a
llocation failed.
* @stable ICU 2.8
* @system
*/
typedef void *U_CALLCONV UMemAllocFn(const void *context, size_t size);
/**
* Pointer type for a user supplied memory re-allocation function.
* @param context user supplied value, obtained from from u_setMemoryFunc
tions().
* @param size The number of bytes to be allocated
* @return Pointer to the newly allocated memory, or NULL if the a
llocation failed.
* @stable ICU 2.8
* @system
*/
typedef void *U_CALLCONV UMemReallocFn(const void *context, void *mem, size
_t size);
/**
* Pointer type for a user supplied memory free function. Behavior shou
ld be
* similar the standard C library free().
* @param context user supplied value, obtained from from u_setMemoryFunc
tions().
* @param mem Pointer to the memory block to be resized
* @param size The new size for the block
* @return Pointer to the resized memory block, or NULL if the res
izing failed.
* @stable ICU 2.8
* @system
*/
typedef void U_CALLCONV UMemFreeFn (const void *context, void *mem);
/**
* Set the functions that ICU will use for memory allocation.
* Use of this function is optional; by default (without this function), I
CU will
* use the standard C library malloc() and free() functions.
* This function can only be used when ICU is in an initial, unused state,
before
* u_init() has been called.
* @param context This pointer value will be saved, and then (later) passe
d as
* a parameter to the memory functions each time they
* are called.
* @param a Pointer to a user-supplied malloc function.
* @param r Pointer to a user-supplied realloc function.
* @param f Pointer to a user-supplied free function.
* @param status Receives error values.
* @stable ICU 2.8
* @system
*/
U_STABLE void U_EXPORT2
u_setMemoryFunctions(const void *context, UMemAllocFn *a, UMemReallocFn *r,
UMemFreeFn *f,
UErrorCode *status);
#endif /* U_HIDE_SYSTEM_API */ #endif /* U_HIDE_SYSTEM_API */
#endif #endif
 End of changes. 11 change blocks. 
70 lines changed or deleted 83 lines changed or added


 ucnv.h   ucnv.h 
/* /*
********************************************************************** **********************************************************************
* Copyright (C) 1999-2012, International Business Machines * Copyright (C) 1999-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
********************************************************************** **********************************************************************
* ucnv.h: * ucnv.h:
* External APIs for the ICU's codeset conversion library * External APIs for the ICU's codeset conversion library
* Bertrand A. Damiba * Bertrand A. Damiba
* *
* Modification History: * Modification History:
* *
* Date Name Description * Date Name Description
* 04/04/99 helena Fixed internal header inclusion. * 04/04/99 helena Fixed internal header inclusion.
skipping to change at line 522 skipping to change at line 522
* *
* If *pBufferSize is greater than zero but not large enough for a stack-ba sed * If *pBufferSize is greater than zero but not large enough for a stack-ba sed
* clone, then the converter is cloned using newly allocated memory * clone, then the converter is cloned using newly allocated memory
* and *pBufferSize is changed to the necessary size. * and *pBufferSize is changed to the necessary size.
* *
* If the converter clone fits into the stack buffer but the stack buffer i s not * If the converter clone fits into the stack buffer but the stack buffer i s not
* sufficiently aligned for the clone, then the clone will use an * sufficiently aligned for the clone, then the clone will use an
* adjusted pointer and use an accordingly smaller buffer size. * adjusted pointer and use an accordingly smaller buffer size.
* *
* @param cnv converter to be cloned * @param cnv converter to be cloned
* @param stackBuffer user allocated space for the new clone. If NULL new m * @param stackBuffer <em>Deprecated functionality as of ICU 52, use NULL.<
emory will be allocated. /em><br>
* user allocated space for the new clone. If NULL new memory will be allo
cated.
* If buffer is not large enough, new memory will be allocated. * If buffer is not large enough, new memory will be allocated.
* Clients can use the U_CNV_SAFECLONE_BUFFERSIZE. This will probably be e nough to avoid memory allocations. * Clients can use the U_CNV_SAFECLONE_BUFFERSIZE. This will probably be e nough to avoid memory allocations.
* @param pBufferSize pointer to size of allocated space. pBufferSize must * @param pBufferSize <em>Deprecated functionality as of ICU 52, use NULL o
not be NULL. r 1.</em><br>
* pointer to size of allocated space.
* @param status to indicate whether the operation went on smoothly or ther e were errors * @param status to indicate whether the operation went on smoothly or ther e were errors
* An informational status value, U_SAFECLONE_ALLOCATED_WARNING, * An informational status value, U_SAFECLONE_ALLOCATED_WARNING,
* is used if any allocations were necessary. * is used if any allocations were necessary.
* However, it is better to check if *pBufferSize grew for checking for * However, it is better to check if *pBufferSize grew for checking for
* allocations because warning codes can be overridden by subsequent * allocations because warning codes can be overridden by subsequent
* function calls. * function calls.
* @return pointer to the new clone * @return pointer to the new clone
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE UConverter * U_EXPORT2 U_STABLE UConverter * U_EXPORT2
ucnv_safeClone(const UConverter *cnv, ucnv_safeClone(const UConverter *cnv,
void *stackBuffer, void *stackBuffer,
int32_t *pBufferSize, int32_t *pBufferSize,
UErrorCode *status); UErrorCode *status);
#ifndef U_HIDE_DEPRECATED_API
/** /**
* \def U_CNV_SAFECLONE_BUFFERSIZE * \def U_CNV_SAFECLONE_BUFFERSIZE
* Definition of a buffer size that is designed to be large enough for * Definition of a buffer size that is designed to be large enough for
* converters to be cloned with ucnv_safeClone(). * converters to be cloned with ucnv_safeClone().
* @stable ICU 2.0 * @deprecated ICU 52. Do not rely on ucnv_safeClone() cloning into any pro vided buffer.
*/ */
#define U_CNV_SAFECLONE_BUFFERSIZE 1024 #define U_CNV_SAFECLONE_BUFFERSIZE 1024
#endif /* U_HIDE_DEPRECATED_API */
/** /**
* Deletes the unicode converter and releases resources associated * Deletes the unicode converter and releases resources associated
* with just this instance. * with just this instance.
* Does not free up shared converter tables. * Does not free up shared converter tables.
* *
* @param converter the converter object to be deleted * @param converter the converter object to be deleted
* @see ucnv_open * @see ucnv_open
* @see ucnv_openU * @see ucnv_openU
* @see ucnv_openCCSID * @see ucnv_openCCSID
* @stable ICU 2.0 * @stable ICU 2.0
 End of changes. 6 change blocks. 
6 lines changed or deleted 13 lines changed or added


 ucol.h   ucol.h 
skipping to change at line 66 skipping to change at line 66
* For usage in C programs. * For usage in C programs.
*/ */
struct UCollator; struct UCollator;
/** structure representing a collator object instance /** structure representing a collator object instance
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
typedef struct UCollator UCollator; typedef struct UCollator UCollator;
/** /**
* UCOL_LESS is returned if source string is compared to be less than targe t * UCOL_LESS is returned if source string is compared to be less than targe t
* string in the u_strcoll() method. * string in the ucol_strcoll() method.
* UCOL_EQUAL is returned if source string is compared to be equal to targe t * UCOL_EQUAL is returned if source string is compared to be equal to targe t
* string in the u_strcoll() method. * string in the ucol_strcoll() method.
* UCOL_GREATER is returned if source string is compared to be greater than * UCOL_GREATER is returned if source string is compared to be greater than
* target string in the u_strcoll() method. * target string in the ucol_strcoll() method.
* @see u_strcoll() * @see ucol_strcoll()
* <p> * <p>
* Possible values for a comparison result * Possible values for a comparison result
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
typedef enum { typedef enum {
/** string a == string b */ /** string a == string b */
UCOL_EQUAL = 0, UCOL_EQUAL = 0,
/** string a > string b */ /** string a > string b */
UCOL_GREATER = 1, UCOL_GREATER = 1,
/** string a < string b */ /** string a < string b */
skipping to change at line 303 skipping to change at line 303
* is useful when combined with shifted setting for alternate handling * is useful when combined with shifted setting for alternate handling
* attribute and for JIS x 4061 collation, when it is used to distingu ish * attribute and for JIS x 4061 collation, when it is used to distingu ish
* between Katakana and Hiragana (this is achieved by setting the * between Katakana and Hiragana (this is achieved by setting the
* UCOL_HIRAGANA_QUATERNARY mode to on. Otherwise, quaternary level * UCOL_HIRAGANA_QUATERNARY mode to on. Otherwise, quaternary level
* is affected only by the number of non ignorable code points in * is affected only by the number of non ignorable code points in
* the string. Identical strength is rarely useful, as it amounts * the string. Identical strength is rarely useful, as it amounts
* to codepoints of the NFD form of the string. * to codepoints of the NFD form of the string.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
UCOL_STRENGTH, UCOL_STRENGTH,
#ifndef U_HIDE_DEPRECATED_API
/** When turned on, this attribute positions Hiragana before all /** When turned on, this attribute positions Hiragana before all
* non-ignorables on quaternary level This is a sneaky way to produce JIS * non-ignorables on quaternary level This is a sneaky way to produce JIS
* sort order. * sort order.
* *
* This attribute is an implementation detail of the CLDR Japanese tai loring. * This attribute is an implementation detail of the CLDR Japanese tai loring.
* The implementation might change to use a different mechanism * The implementation might change to use a different mechanism
* to achieve the same Japanese sort order. * to achieve the same Japanese sort order.
* Since ICU 50, this attribute is not settable any more via API funct ions. * Since ICU 50, this attribute is not settable any more via API funct ions.
* @deprecated ICU 50 Implementation detail, cannot be set via API, mi ght be removed from implementation. * @deprecated ICU 50 Implementation detail, cannot be set via API, mi ght be removed from implementation.
*/ */
UCOL_HIRAGANA_QUATERNARY_MODE, UCOL_HIRAGANA_QUATERNARY_MODE = UCOL_STRENGTH + 1,
#endif /* U_HIDE_DEPRECATED_API */
/** When turned on, this attribute generates a collation key /** When turned on, this attribute generates a collation key
* for the numeric value of substrings of digits. * for the numeric value of substrings of digits.
* This is a way to get '100' to sort AFTER '2'. Note that the longest * This is a way to get '100' to sort AFTER '2'. Note that the longest
* digit substring that can be treated as a single collation element i s * digit substring that can be treated as a single collation element i s
* 254 digits (not counting leading zeros). If a digit substring is * 254 digits (not counting leading zeros). If a digit substring is
* longer than that, the digits beyond the limit will be treated as a * longer than that, the digits beyond the limit will be treated as a
* separate digit substring associated with a separate collation eleme nt. * separate digit substring associated with a separate collation eleme nt.
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
UCOL_NUMERIC_COLLATION, UCOL_NUMERIC_COLLATION = UCOL_STRENGTH + 2,
/** /**
* The number of UColAttribute constants. * The number of UColAttribute constants.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
UCOL_ATTRIBUTE_COUNT UCOL_ATTRIBUTE_COUNT
} UColAttribute; } UColAttribute;
/** Options for retrieving the rule string /** Options for retrieving the rule string
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
skipping to change at line 534 skipping to change at line 536
* @see ucol_equal * @see ucol_equal
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE UCollationResult U_EXPORT2 U_STABLE UCollationResult U_EXPORT2
ucol_strcoll( const UCollator *coll, ucol_strcoll( const UCollator *coll,
const UChar *source, const UChar *source,
int32_t sourceLength, int32_t sourceLength,
const UChar *target, const UChar *target,
int32_t targetLength); int32_t targetLength);
#ifndef U_HIDE_DRAFT_API
/** /**
* Compare two strings in UTF-8. * Compare two strings in UTF-8.
* The strings will be compared using the options already specified. * The strings will be compared using the options already specified.
* Note: When input string contains malformed a UTF-8 byte sequence, * Note: When input string contains malformed a UTF-8 byte sequence,
* this function treats these bytes as REPLACEMENT CHARACTER (U+FFFD). * this function treats these bytes as REPLACEMENT CHARACTER (U+FFFD).
* @param coll The UCollator containing the comparison rules. * @param coll The UCollator containing the comparison rules.
* @param source The source UTF-8 string. * @param source The source UTF-8 string.
* @param sourceLength The length of source, or -1 if null-terminated. * @param sourceLength The length of source, or -1 if null-terminated.
* @param target The target UTF-8 string. * @param target The target UTF-8 string.
* @param targetLength The length of target, or -1 if null-terminated. * @param targetLength The length of target, or -1 if null-terminated.
* @param status A pointer to an UErrorCode to receive any errors * @param status A pointer to an UErrorCode to receive any errors
* @return The result of comparing the strings; one of UCOL_EQUAL, * @return The result of comparing the strings; one of UCOL_EQUAL,
* UCOL_GREATER, UCOL_LESS * UCOL_GREATER, UCOL_LESS
* @see ucol_greater * @see ucol_greater
* @see ucol_greaterOrEqual * @see ucol_greaterOrEqual
* @see ucol_equal * @see ucol_equal
* @draft ICU 50 * @stable ICU 50
*/ */
U_DRAFT UCollationResult U_EXPORT2 U_STABLE UCollationResult U_EXPORT2
ucol_strcollUTF8( ucol_strcollUTF8(
const UCollator *coll, const UCollator *coll,
const char *source, const char *source,
int32_t sourceLength, int32_t sourceLength,
const char *target, const char *target,
int32_t targetLength, int32_t targetLength,
UErrorCode *status); UErrorCode *status);
#endif /* U_HIDE_DRAFT_API */
/** /**
* Determine if one string is greater than another. * Determine if one string is greater than another.
* This function is equivalent to {@link #ucol_strcoll } == UCOL_GREATER * This function is equivalent to {@link #ucol_strcoll } == UCOL_GREATER
* @param coll The UCollator containing the comparison rules. * @param coll The UCollator containing the comparison rules.
* @param source The source string. * @param source The source string.
* @param sourceLength The length of source, or -1 if null-terminated. * @param sourceLength The length of source, or -1 if null-terminated.
* @param target The target string. * @param target The target string.
* @param targetLength The length of target, or -1 if null-terminated. * @param targetLength The length of target, or -1 if null-terminated.
* @return TRUE if source is greater than target, FALSE otherwise. * @return TRUE if source is greater than target, FALSE otherwise.
skipping to change at line 1211 skipping to change at line 1211
* @see ucol_getVariableTop * @see ucol_getVariableTop
* @see ucol_setVariableTop * @see ucol_setVariableTop
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE void U_EXPORT2 U_STABLE void U_EXPORT2
ucol_restoreVariableTop(UCollator *coll, const uint32_t varTop, UErrorCode *status); ucol_restoreVariableTop(UCollator *coll, const uint32_t varTop, UErrorCode *status);
/** /**
* Thread safe cloning operation. The result is a clone of a given collator . * Thread safe cloning operation. The result is a clone of a given collator .
* @param coll collator to be cloned * @param coll collator to be cloned
* @param stackBuffer user allocated space for the new clone. * @param stackBuffer <em>Deprecated functionality as of ICU 52, use NULL.<
/em><br>
* user allocated space for the new clone.
* If NULL new memory will be allocated. * If NULL new memory will be allocated.
* If buffer is not large enough, new memory will be allocated. * If buffer is not large enough, new memory will be allocated.
* Clients can use the U_COL_SAFECLONE_BUFFERSIZE. * Clients can use the U_COL_SAFECLONE_BUFFERSIZE.
* This will probably be enough to avoid memory allocations. * @param pBufferSize <em>Deprecated functionality as of ICU 52, use NULL o
* @param pBufferSize pointer to size of allocated space. r 1.</em><br>
* pointer to size of allocated space.
* If *pBufferSize == 0, a sufficient size for use in cloning will * If *pBufferSize == 0, a sufficient size for use in cloning will
* be returned ('pre-flighting') * be returned ('pre-flighting')
* If *pBufferSize is not enough for a stack-based safe clone, * If *pBufferSize is not enough for a stack-based safe clone,
* new memory will be allocated. * new memory will be allocated.
* @param status to indicate whether the operation went on smoothly or ther e were errors * @param status to indicate whether the operation went on smoothly or ther e were errors
* An informational status value, U_SAFECLONE_ALLOCATED_ERROR, is used i f any * An informational status value, U_SAFECLONE_ALLOCATED_ERROR, is used i f any
* allocations were necessary. * allocations were necessary.
* @return pointer to the new clone * @return pointer to the new clone
* @see ucol_open * @see ucol_open
* @see ucol_openRules * @see ucol_openRules
* @see ucol_close * @see ucol_close
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE UCollator* U_EXPORT2 U_STABLE UCollator* U_EXPORT2
ucol_safeClone(const UCollator *coll, ucol_safeClone(const UCollator *coll,
void *stackBuffer, void *stackBuffer,
int32_t *pBufferSize, int32_t *pBufferSize,
UErrorCode *status); UErrorCode *status);
/** default memory size for the new clone. It needs to be this large for os #ifndef U_HIDE_DEPRECATED_API
/400 large pointers
* @stable ICU 2.0 /** default memory size for the new clone.
* @deprecated ICU 52. Do not rely on ucol_safeClone() cloning into any pro
vided buffer.
*/ */
#define U_COL_SAFECLONE_BUFFERSIZE 528 #define U_COL_SAFECLONE_BUFFERSIZE 1
#endif /* U_HIDE_DEPRECATED_API */
/** /**
* Returns current rules. Delta defines whether full rules are returned or just the tailoring. * Returns current rules. Delta defines whether full rules are returned or just the tailoring.
* Returns number of UChars needed to store rules. If buffer is NULL or buf ferLen is not enough * Returns number of UChars needed to store rules. If buffer is NULL or buf ferLen is not enough
* to store rules, will store up to available space. * to store rules, will store up to available space.
* *
* ucol_getRules() should normally be used instead. * ucol_getRules() should normally be used instead.
* See http://userguide.icu-project.org/collation/customization#TOC-Buildin g-on-Existing-Locales * See http://userguide.icu-project.org/collation/customization#TOC-Buildin g-on-Existing-Locales
* @param coll collator to get the rules from * @param coll collator to get the rules from
* @param delta one of UCOL_TAILORING_ONLY, UCOL_FULL_RULES. * @param delta one of UCOL_TAILORING_ONLY, UCOL_FULL_RULES.
 End of changes. 14 change blocks. 
17 lines changed or deleted 24 lines changed or added


 ucsdet.h   ucsdet.h 
/* /*
********************************************************************** **********************************************************************
* Copyright (C) 2005-2010, International Business Machines * Copyright (C) 2005-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
********************************************************************** **********************************************************************
* file name: ucsdet.h * file name: ucsdet.h
* encoding: US-ASCII * encoding: US-ASCII
* indentation:4 * indentation:4
* *
* created on: 2005Aug04 * created on: 2005Aug04
* created by: Andy Heninger * created by: Andy Heninger
* *
* ICU Character Set Detection, API for C * ICU Character Set Detection, API for C
skipping to change at line 315 skipping to change at line 315
UChar *buf, int32_t cap, UErrorCode *status); UChar *buf, int32_t cap, UErrorCode *status);
/** /**
* Get an iterator over the set of all detectable charsets - * Get an iterator over the set of all detectable charsets -
* over the charsets that are known to the charset detection * over the charsets that are known to the charset detection
* service. * service.
* *
* The returned UEnumeration provides access to the names of * The returned UEnumeration provides access to the names of
* the charsets. * the charsets.
* *
* <p>
* The state of the Charset detector that is passed in does not * The state of the Charset detector that is passed in does not
* affect the result of this function, but requiring a valid, open * affect the result of this function, but requiring a valid, open
* charset detector as a parameter insures that the charset detection * charset detector as a parameter insures that the charset detection
* service has been safely initialized and that the required detection * service has been safely initialized and that the required detection
* data is available. * data is available.
* *
* <p>
* <b>Note:</b> Multiple different charset encodings in a same family may
use
* a single shared name in this implementation. For example, this method
returns
* an array including "ISO-8859-1" (ISO Latin 1), but not including "wind
ows-1252"
* (Windows Latin 1). However, actual detection result could be "windows-
1252"
* when the input data matches Latin 1 code points with any points only a
vailable
* in "windows-1252".
*
* @param ucsd a Charset detector. * @param ucsd a Charset detector.
* @param status Any error conditions are reported back in this variable . * @param status Any error conditions are reported back in this variable .
* @return an iterator providing access to the detectable charset names. * @return an iterator providing access to the detectable charset names.
* @stable ICU 3.6 * @stable ICU 3.6
*/ */
U_STABLE UEnumeration * U_EXPORT2 U_STABLE UEnumeration * U_EXPORT2
ucsdet_getAllDetectableCharsets(const UCharsetDetector *ucsd, UErrorCode * status); ucsdet_getAllDetectableCharsets(const UCharsetDetector *ucsd, UErrorCode * status);
/** /**
* Test whether input filtering is enabled for this charset detector. * Test whether input filtering is enabled for this charset detector.
* Input filtering removes text that appears to be HTML or xml * Input filtering removes text that appears to be HTML or xml
* markup from the input before applying the code page detection * markup from the input before applying the code page detection
* heuristics. * heuristics.
* *
* @param ucsd The charset detector to check. * @param ucsd The charset detector to check.
* @return TRUE if filtering is enabled. * @return TRUE if filtering is enabled.
* @stable ICU 3.6 * @stable ICU 3.6
*/ */
U_STABLE UBool U_EXPORT2 U_STABLE UBool U_EXPORT2
ucsdet_isInputFilterEnabled(const UCharsetDetector *ucsd); ucsdet_isInputFilterEnabled(const UCharsetDetector *ucsd);
/** /**
* Enable filtering of input text. If filtering is enabled, * Enable filtering of input text. If filtering is enabled,
* text within angle brackets ("<" and ">") will be removed * text within angle brackets ("<" and ">") will be removed
* before detection, which will remove most HTML or xml markup. * before detection, which will remove most HTML or xml markup.
* *
* @param ucsd the charset detector to be modified. * @param ucsd the charset detector to be modified.
* @param filter <code>true</code> to enable input text filtering. * @param filter <code>true</code> to enable input text filtering.
* @return The previous setting. * @return The previous setting.
* *
* @stable ICU 3.6 * @stable ICU 3.6
*/ */
U_STABLE UBool U_EXPORT2 U_STABLE UBool U_EXPORT2
ucsdet_enableInputFilter(UCharsetDetector *ucsd, UBool filter); ucsdet_enableInputFilter(UCharsetDetector *ucsd, UBool filter);
#ifndef U_HIDE_INTERNAL_API
/**
* Get an iterator over the set of detectable charsets -
* over the charsets that are enabled by the specified charset detector.
*
* The returned UEnumeration provides access to the names of
* the charsets.
*
* @param ucsd a Charset detector.
* @param status Any error conditions are reported back in this variable
.
* @return an iterator providing access to the detectable charset names b
y
* the specified charset detector.
* @internal
*/
U_INTERNAL UEnumeration * U_EXPORT2
ucsdet_getDetectableCharsets(const UCharsetDetector *ucsd, UErrorCode *sta
tus);
/**
* Enable or disable individual charset encoding.
* A name of charset encoding must be included in the names returned by
* {@link #getAllDetectableCharsets()}.
*
* @param ucsd a Charset detector.
* @param encoding encoding the name of charset encoding.
* @param enabled <code>TRUE</code> to enable, or <code>FALSE</code> to di
sable the
* charset encoding.
* @param status receives the return status. When the name of charset enco
ding
* is not supported, U_ILLEGAL_ARGUMENT_ERROR is set.
* @internal
*/
U_INTERNAL void U_EXPORT2
ucsdet_setDetectableCharset(UCharsetDetector *ucsd, const char *encoding, U
Bool enabled, UErrorCode *status);
#endif /* U_HIDE_INTERNAL_API */
#endif #endif
#endif /* __UCSDET_H */ #endif /* __UCSDET_H */
 End of changes. 5 change blocks. 
1 lines changed or deleted 56 lines changed or added


 udat.h   udat.h 
skipping to change at line 134 skipping to change at line 134
* </ul> * </ul>
* You can also set the time zone on the format if you wish. * You can also set the time zone on the format if you wish.
* <P> * <P>
* You can also use forms of the parse and format methods with Parse Positi on and * You can also use forms of the parse and format methods with Parse Positi on and
* UFieldPosition to allow you to * UFieldPosition to allow you to
* <ul type=round> * <ul type=round>
* <li> Progressively parse through pieces of a string. * <li> Progressively parse through pieces of a string.
* <li> Align any particular field, or find out where it is for selecti on * <li> Align any particular field, or find out where it is for selecti on
* on the screen. * on the screen.
* </ul> * </ul>
* <p><strong>Date and Time Patterns:</strong></p>
*
* <p>Date and time formats are specified by <em>date and time pattern</em>
strings.
* Within date and time pattern strings, all unquoted ASCII letters [A-Za-z
] are reserved
* as pattern letters representing calendar fields. <code>UDateFormat</code
> supports
* the date and time formatting algorithm and pattern letters defined by
* <a href="http://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_
Symbol_Table">UTS#35
* Unicode Locale Data Markup Language (LDML)</a> and further documented fo
r ICU in the
* <a href="https://sites.google.com/site/icuprojectuserguide/formatparse/d
atetime?pli=1#TOC-Date-Field-Symbol-Table">ICU
* User Guide</a>.</p>
*/ */
/** A date formatter. /** A date formatter.
* For usage in C programs. * For usage in C programs.
* @stable ICU 2.6 * @stable ICU 2.6
*/ */
typedef void* UDateFormat; typedef void* UDateFormat;
/** The possible date/time format styles /** The possible date/time format styles
* @stable ICU 2.6 * @stable ICU 2.6
skipping to change at line 171 skipping to change at line 181
UDAT_LONG_RELATIVE = UDAT_LONG | UDAT_RELATIVE, UDAT_LONG_RELATIVE = UDAT_LONG | UDAT_RELATIVE,
UDAT_MEDIUM_RELATIVE = UDAT_MEDIUM | UDAT_RELATIVE, UDAT_MEDIUM_RELATIVE = UDAT_MEDIUM | UDAT_RELATIVE,
UDAT_SHORT_RELATIVE = UDAT_SHORT | UDAT_RELATIVE, UDAT_SHORT_RELATIVE = UDAT_SHORT | UDAT_RELATIVE,
/** No style */ /** No style */
UDAT_NONE = -1, UDAT_NONE = -1,
#ifndef U_HIDE_DRAFT_API
/** /**
* Use the pattern given in the parameter to udat_open * Use the pattern given in the parameter to udat_open
* @see udat_open * @see udat_open
* @draft ICU 50 * @stable ICU 50
*/ */
UDAT_PATTERN = -2, UDAT_PATTERN = -2,
/** @internal alias to UDAT_PATTERN */ /** @internal alias to UDAT_PATTERN */
UDAT_IGNORE = UDAT_PATTERN UDAT_IGNORE = UDAT_PATTERN
#endif /* U_HIDE_DRAFT_API */
} UDateFormatStyle; } UDateFormatStyle;
// Skeletons for dates. /* Skeletons for dates. */
/** /**
* Constant for date skeleton with year. * Constant for date skeleton with year.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
#define UDAT_YEAR "y" #define UDAT_YEAR "y"
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
/** /**
* Constant for date skeleton with quarter. * Constant for date skeleton with quarter.
* @draft ICU 51 * @draft ICU 51
skipping to change at line 333 skipping to change at line 341
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
#define UDAT_ABBR_MONTH_WEEKDAY_DAY "MMMEd" #define UDAT_ABBR_MONTH_WEEKDAY_DAY "MMMEd"
/** /**
* Constant for date skeleton with numeric month, weekday, and day. * Constant for date skeleton with numeric month, weekday, and day.
* Used in combinations date + time, date + time + zone, or time + zone. * Used in combinations date + time, date + time + zone, or time + zone.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
#define UDAT_NUM_MONTH_WEEKDAY_DAY "MEd" #define UDAT_NUM_MONTH_WEEKDAY_DAY "MEd"
// Skeletons for times. /* Skeletons for times. */
/** /**
* Constant for date skeleton with hour, with the locale's preferred hour f ormat (12 or 24). * Constant for date skeleton with hour, with the locale's preferred hour f ormat (12 or 24).
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
#define UDAT_HOUR "j" #define UDAT_HOUR "j"
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
/** /**
* Constant for date skeleton with hour in 24-hour presentation. * Constant for date skeleton with hour in 24-hour presentation.
* @draft ICU 51 * @draft ICU 51
skipping to change at line 392 skipping to change at line 400
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
#define UDAT_HOUR24_MINUTE_SECOND "Hms" #define UDAT_HOUR24_MINUTE_SECOND "Hms"
/** /**
* Constant for date skeleton with minute and second. * Constant for date skeleton with minute and second.
* Used in combinations date + time, date + time + zone, or time + zone. * Used in combinations date + time, date + time + zone, or time + zone.
* @stable ICU 4.0 * @stable ICU 4.0
*/ */
#define UDAT_MINUTE_SECOND "ms" #define UDAT_MINUTE_SECOND "ms"
// Skeletons for time zones. /* Skeletons for time zones. */
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
/** /**
* Constant for <i>generic location format</i>, such as Los Angeles Time; * Constant for <i>generic location format</i>, such as Los Angeles Time;
* used in combinations date + time + zone, or time + zone. * used in combinations date + time + zone, or time + zone.
* @see <a href="http://unicode.org/reports/tr35/#Date_Format_Patterns">LDM L Date Format Patterns</a> * @see <a href="http://unicode.org/reports/tr35/#Date_Format_Patterns">LDM L Date Format Patterns</a>
* @see <a href="http://unicode.org/reports/tr35/#Time_Zone_Fallback">LDML Time Zone Fallback</a> * @see <a href="http://unicode.org/reports/tr35/#Time_Zone_Fallback">LDML Time Zone Fallback</a>
* @draft ICU 51 * @draft ICU 51
*/ */
#define UDAT_LOCATION_TZ "VVVV" #define UDAT_LOCATION_TZ "VVVV"
skipping to change at line 445 skipping to change at line 453
/** /**
* Constant for <i>localized GMT/UTC format</i>, such as GMT+8:00 or HPG-8: 00; * Constant for <i>localized GMT/UTC format</i>, such as GMT+8:00 or HPG-8: 00;
* used in combinations date + time + zone, or time + zone. * used in combinations date + time + zone, or time + zone.
* @see <a href="http://unicode.org/reports/tr35/#Date_Format_Patterns">LDM L Date Format Patterns</a> * @see <a href="http://unicode.org/reports/tr35/#Date_Format_Patterns">LDM L Date Format Patterns</a>
* @see <a href="http://unicode.org/reports/tr35/#Time_Zone_Fallback">LDML Time Zone Fallback</a> * @see <a href="http://unicode.org/reports/tr35/#Time_Zone_Fallback">LDML Time Zone Fallback</a>
* @draft ICU 51 * @draft ICU 51
*/ */
#define UDAT_ABBR_UTC_TZ "ZZZZ" #define UDAT_ABBR_UTC_TZ "ZZZZ"
#endif /* U_HIDE_DRAFT_API */ #endif /* U_HIDE_DRAFT_API */
// deprecated skeleton constants /* deprecated skeleton constants */
#ifndef U_HIDE_DEPRECATED_API #ifndef U_HIDE_DEPRECATED_API
/** /**
* Constant for date skeleton with standalone month. * Constant for date skeleton with standalone month.
* @deprecated ICU 50 Use UDAT_MONTH instead. * @deprecated ICU 50 Use UDAT_MONTH instead.
*/ */
#define UDAT_STANDALONE_MONTH "LLLL" #define UDAT_STANDALONE_MONTH "LLLL"
/** /**
* Constant for date skeleton with standalone abbreviated month. * Constant for date skeleton with standalone abbreviated month.
* @deprecated ICU 50 Use UDAT_ABBR_MONTH instead. * @deprecated ICU 50 Use UDAT_ABBR_MONTH instead.
skipping to change at line 825 skipping to change at line 833
/** /**
* Close a UDateFormat. * Close a UDateFormat.
* Once closed, a UDateFormat may no longer be used. * Once closed, a UDateFormat may no longer be used.
* @param format The formatter to close. * @param format The formatter to close.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE void U_EXPORT2 U_STABLE void U_EXPORT2
udat_close(UDateFormat* format); udat_close(UDateFormat* format);
/**
* DateFormat boolean attributes
* @internal ICU technology preview
*/
typedef enum UDateFormatBooleanAttribute {
/**
* indicates whether whitespace is allowed. Includes trailing dot toler
ance.
* @internal ICU technology preview
*/
UDAT_PARSE_ALLOW_WHITESPACE,
/**
* indicates tolerance of numeric data when String data may be assumed.
eg: UDAT_YEAR_NAME_FIELD,
* UDAT_STANDALONE_MONTH_FIELD, UDAT_DAY_OF_WEEK_FIELD
* @internal ICU technology preview
*/
UDAT_PARSE_ALLOW_NUMERIC,
/**
* count boolean date format constants
* @internal ICU technology preview
*/
UDAT_BOOLEAN_ATTRIBUTE_COUNT
} UDateFormatBooleanAttribute;
#ifndef U_HIDE_INTERNAL_API
/**
* Get a boolean attribute associated with a UDateFormat.
* An example would be a true value for a key of UDAT_PARSE_ALLOW_WHITESPAC
E indicating allowing whitespace leniency.
* If the formatter does not understand the attribute, -1 is returned.
* @param fmt The formatter to query.
* @param attr The attribute to query; e.g. UDAT_PARSE_ALLOW_WHITESPACE.
* @param status A pointer to an UErrorCode to receive any errors
* @return The value of attr.
* @internal technology preview
*/
U_INTERNAL UBool U_EXPORT2
udat_getBooleanAttribute(const UDateFormat* fmt, UDateFormatBooleanAttribut
e attr, UErrorCode* status);
/**
* Set a boolean attribute associated with a UDateFormat.
* An example of a boolean attribute is parse leniency control. If the for
matter does not understand
* the attribute, the call is ignored.
* @param fmt The formatter to set.
* @param attr The attribute to set; one of UDAT_PARSE_ALLOW_WHITESPACE or
UDAT_PARSE_ALLOW_NUMERIC
* @param newValue The new value of attr.
* @param status A pointer to an UErrorCode to receive any errors
* @internal ICU technology preview
*/
U_INTERNAL void U_EXPORT2
udat_setBooleanAttribute(UDateFormat *fmt, UDateFormatBooleanAttribute attr
, UBool, UErrorCode* status);
#endif /* U_HIDE_INTERNAL_API */
#if U_SHOW_CPLUSPLUS_API #if U_SHOW_CPLUSPLUS_API
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
/** /**
* \class LocalUDateFormatPointer * \class LocalUDateFormatPointer
* "Smart pointer" class, closes a UDateFormat via udat_close(). * "Smart pointer" class, closes a UDateFormat via udat_close().
* For most methods see the LocalPointerBase base class. * For most methods see the LocalPointerBase base class.
* *
* @see LocalPointerBase * @see LocalPointerBase
 End of changes. 9 change blocks. 
7 lines changed or deleted 80 lines changed or added


 udisplaycontext.h   udisplaycontext.h 
skipping to change at line 17 skipping to change at line 17
#ifndef UDISPLAYCONTEXT_H #ifndef UDISPLAYCONTEXT_H
#define UDISPLAYCONTEXT_H #define UDISPLAYCONTEXT_H
#include "unicode/utypes.h" #include "unicode/utypes.h"
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
/* Dont hide with #ifndef U_HIDE_DRAFT_API, needed by virtual methods */ /* Dont hide with #ifndef U_HIDE_DRAFT_API, needed by virtual methods */
/** /**
* \file
* \brief C API: Display context types (enum values)
*/
/**
* Display context types, for getting values of a particular setting. * Display context types, for getting values of a particular setting.
* Note, the specific numeric values are internal and may change. * Note, the specific numeric values are internal and may change.
* @draft ICU 51 * @draft ICU 51
*/ */
enum UDisplayContextType { enum UDisplayContextType {
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
/** /**
* Type to retrieve the dialect handling setting, e.g. * Type to retrieve the dialect handling setting, e.g.
* UDISPCTX_STANDARD_NAMES or UDISPCTX_DIALECT_NAMES. * UDISPCTX_STANDARD_NAMES or UDISPCTX_DIALECT_NAMES.
* @draft ICU 51 * @draft ICU 51
 End of changes. 1 change blocks. 
0 lines changed or deleted 5 lines changed or added


 uenum.h   uenum.h 
/* /*
*************************************************************************** **** *************************************************************************** ****
* *
* Copyright (C) 2002-2012, International Business Machines * Copyright (C) 2002-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
* *
*************************************************************************** **** *************************************************************************** ****
* file name: uenum.h * file name: uenum.h
* encoding: US-ASCII * encoding: US-ASCII
* tab size: 8 (not used) * tab size: 8 (not used)
* indentation:2 * indentation:2
* *
* created on: 2002jul08 * created on: 2002jul08
* created by: Vladimir Weinstein * created by: Vladimir Weinstein
skipping to change at line 174 skipping to change at line 174
* @param adopted the C++ StringEnumeration to be wrapped in a UEnumeration . * @param adopted the C++ StringEnumeration to be wrapped in a UEnumeration .
* @param ec the error code. * @param ec the error code.
* @return a UEnumeration wrapping the adopted StringEnumeration. * @return a UEnumeration wrapping the adopted StringEnumeration.
* @stable ICU 4.2 * @stable ICU 4.2
*/ */
U_STABLE UEnumeration* U_EXPORT2 U_STABLE UEnumeration* U_EXPORT2
uenum_openFromStringEnumeration(icu::StringEnumeration* adopted, UErrorCode * ec); uenum_openFromStringEnumeration(icu::StringEnumeration* adopted, UErrorCode * ec);
#endif #endif
#ifndef U_HIDE_DRAFT_API
/** /**
* Given an array of const UChar* strings, return a UEnumeration. String p ointers from 0..count-1 must not be null. * Given an array of const UChar* strings, return a UEnumeration. String p ointers from 0..count-1 must not be null.
* Do not free or modify either the string array or the characters it point s to until this object has been destroyed with uenum_close. * Do not free or modify either the string array or the characters it point s to until this object has been destroyed with uenum_close.
* \snippet test/cintltst/uenumtst.c uenum_openUCharStringsEnumeration * \snippet test/cintltst/uenumtst.c uenum_openUCharStringsEnumeration
* @param strings array of const UChar* strings (each null terminated). All storage is owned by the caller. * @param strings array of const UChar* strings (each null terminated). All storage is owned by the caller.
* @param count length of the array * @param count length of the array
* @param ec error code * @param ec error code
* @return the new UEnumeration object. Caller is responsible for calling u enum_close to free memory. * @return the new UEnumeration object. Caller is responsible for calling u enum_close to free memory.
* @see uenum_close * @see uenum_close
* @draft ICU 50 * @stable ICU 50
*/ */
U_DRAFT UEnumeration* U_EXPORT2 U_STABLE UEnumeration* U_EXPORT2
uenum_openUCharStringsEnumeration(const UChar* const strings[], int32_t cou nt, uenum_openUCharStringsEnumeration(const UChar* const strings[], int32_t cou nt,
UErrorCode* ec); UErrorCode* ec);
#endif
/* Note: next function is not hidden as draft, as it is used internally (i t was formerly an internal function). */ /* Note: next function is not hidden as draft, as it is used internally (i t was formerly an internal function). */
/** /**
* Given an array of const char* strings (invariant chars only), return a U Enumeration. String pointers from 0..count-1 must not be null. * Given an array of const char* strings (invariant chars only), return a U Enumeration. String pointers from 0..count-1 must not be null.
* Do not free or modify either the string array or the characters it point s to until this object has been destroyed with uenum_close. * Do not free or modify either the string array or the characters it point s to until this object has been destroyed with uenum_close.
* \snippet test/cintltst/uenumtst.c uenum_openCharStringsEnumeration * \snippet test/cintltst/uenumtst.c uenum_openCharStringsEnumeration
* @param strings array of char* strings (each null terminated). All stora ge is owned by the caller. * @param strings array of char* strings (each null terminated). All stora ge is owned by the caller.
* @param count length of the array * @param count length of the array
* @param ec error code * @param ec error code
* @return the new UEnumeration object. Caller is responsible for calling u enum_close to free memory * @return the new UEnumeration object. Caller is responsible for calling u enum_close to free memory
* @see uenum_close * @see uenum_close
* @draft ICU 50 * @stable ICU 50
*/ */
U_DRAFT UEnumeration* U_EXPORT2 U_STABLE UEnumeration* U_EXPORT2
uenum_openCharStringsEnumeration(const char* const strings[], int32_t count , uenum_openCharStringsEnumeration(const char* const strings[], int32_t count ,
UErrorCode* ec); UErrorCode* ec);
#endif #endif
 End of changes. 7 change blocks. 
7 lines changed or deleted 5 lines changed or added


 ugender.h   ugender.h 
skipping to change at line 14 skipping to change at line 14
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
*************************************************************************** ************** *************************************************************************** **************
*/ */
#ifndef UGENDER_H #ifndef UGENDER_H
#define UGENDER_H #define UGENDER_H
#include "unicode/utypes.h" #include "unicode/utypes.h"
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
#ifndef U_HIDE_DRAFT_API
#include "unicode/localpointer.h" #include "unicode/localpointer.h"
/** /**
* \file * \file
* \brief C API: The purpose of this API is to compute the gender of a list as a * \brief C API: The purpose of this API is to compute the gender of a list as a
* whole given the gender of each element. * whole given the gender of each element.
* *
*/ */
/** /**
* Genders * Genders
* @draft ICU 50 * @stable ICU 50
*/ */
enum UGender { enum UGender {
/** /**
* Male gender. * Male gender.
* @draft ICU 50 * @stable ICU 50
*/ */
UGENDER_MALE, UGENDER_MALE,
/** /**
* Female gender. * Female gender.
* @draft ICU 50 * @stable ICU 50
*/ */
UGENDER_FEMALE, UGENDER_FEMALE,
/** /**
* Neutral gender. * Neutral gender.
* @draft ICU 50 * @stable ICU 50
*/ */
UGENDER_OTHER UGENDER_OTHER
}; };
/** /**
* @draft ICU 50 * @stable ICU 50
*/ */
typedef enum UGender UGender; typedef enum UGender UGender;
/** /**
* Opaque UGenderInfo object for use in C programs. * Opaque UGenderInfo object for use in C programs.
* @draft ICU 50 * @stable ICU 50
*/ */
struct UGenderInfo; struct UGenderInfo;
typedef struct UGenderInfo UGenderInfo; typedef struct UGenderInfo UGenderInfo;
/** /**
* Opens a new UGenderInfo object given locale. * Opens a new UGenderInfo object given locale.
* @param locale The locale for which the rules are desired. * @param locale The locale for which the rules are desired.
* @param status UErrorCode pointer
* @return A UGenderInfo for the specified locale, or NULL if an error occu rred. * @return A UGenderInfo for the specified locale, or NULL if an error occu rred.
* @draft ICU 50 * @stable ICU 50
*/ */
U_DRAFT const UGenderInfo* U_EXPORT2 U_STABLE const UGenderInfo* U_EXPORT2
ugender_getInstance(const char *locale, UErrorCode *status); ugender_getInstance(const char *locale, UErrorCode *status);
/** /**
* Given a list, returns the gender of the list as a whole. * Given a list, returns the gender of the list as a whole.
* @param genderInfo pointer that ugender_getInstance returns. * @param genderInfo pointer that ugender_getInstance returns.
* @param genders the gender of each element in the list. * @param genders the gender of each element in the list.
* @param size the size of the list. * @param size the size of the list.
* @param status A pointer to a UErrorCode to receive any errors. * @param status A pointer to a UErrorCode to receive any errors.
* @return The gender of the list. * @return The gender of the list.
* @draft ICU 50 * @stable ICU 50
*/ */
U_DRAFT UGender U_EXPORT2 U_STABLE UGender U_EXPORT2
ugender_getListGender(const UGenderInfo* genderinfo, const UGender *genders , int32_t size, UErrorCode *status); ugender_getListGender(const UGenderInfo* genderinfo, const UGender *genders , int32_t size, UErrorCode *status);
#endif /* U_HIDE_DRAFT_API */
#endif /* #if !UCONFIG_NO_FORMATTING */ #endif /* #if !UCONFIG_NO_FORMATTING */
#endif #endif
 End of changes. 13 change blocks. 
12 lines changed or deleted 11 lines changed or added


 uloc.h   uloc.h 
skipping to change at line 796 skipping to change at line 796
* @return The length of the parent locale ID. * @return The length of the parent locale ID.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE int32_t U_EXPORT2 U_STABLE int32_t U_EXPORT2
uloc_getParent(const char* localeID, uloc_getParent(const char* localeID,
char* parent, char* parent,
int32_t parentCapacity, int32_t parentCapacity,
UErrorCode* err); UErrorCode* err);
/** /**
* Gets the full name for the specified locale. * Gets the full name for the specified locale, like uloc_getName(),
* but without keywords.
*
* Note: This has the effect of 'canonicalizing' the string to * Note: This has the effect of 'canonicalizing' the string to
* a certain extent. Upper and lower case are set as needed, * a certain extent. Upper and lower case are set as needed,
* and if the components were in 'POSIX' format they are changed to * and if the components were in 'POSIX' format they are changed to
* ICU format. It does NOT map aliased names in any way. * ICU format. It does NOT map aliased names in any way.
* See the top of this header file. * See the top of this header file.
*
* This API strips off the keyword part, so "de_DE\@collation=phonebook" * This API strips off the keyword part, so "de_DE\@collation=phonebook"
* will become "de_DE". * will become "de_DE".
* This API supports preflighting. * This API supports preflighting.
* *
* @param localeID the locale to get the full name with * @param localeID the locale to get the full name with
* @param name fill in buffer for the name without keywords. * @param name fill in buffer for the name without keywords.
* @param nameCapacity capacity of the fill in buffer. * @param nameCapacity capacity of the fill in buffer.
* @param err error information if retrieving the full name failed * @param err error information if retrieving the full name failed
* @return the actual buffer size needed for the full name. If it's greate r * @return the actual buffer size needed for the full name. If it's greate r
* than nameCapacity, the returned full name will be truncated. * than nameCapacity, the returned full name will be truncated.
skipping to change at line 851 skipping to change at line 854
* @return the length of keyword value * @return the length of keyword value
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
U_STABLE int32_t U_EXPORT2 U_STABLE int32_t U_EXPORT2
uloc_getKeywordValue(const char* localeID, uloc_getKeywordValue(const char* localeID,
const char* keywordName, const char* keywordName,
char* buffer, int32_t bufferCapacity, char* buffer, int32_t bufferCapacity,
UErrorCode* status); UErrorCode* status);
/** /**
* Set the value of the specified keyword. * Sets or removes the value of the specified keyword.
*
* For removing all keywords, use uloc_getBaseName().
*
* NOTE: Unlike almost every other ICU function which takes a * NOTE: Unlike almost every other ICU function which takes a
* buffer, this function will NOT truncate the output text. If a * buffer, this function will NOT truncate the output text. If a
* BUFFER_OVERFLOW_ERROR is received, it means that the original * BUFFER_OVERFLOW_ERROR is received, it means that the original
* buffer is untouched. This is done to prevent incorrect or possibly * buffer is untouched. This is done to prevent incorrect or possibly
* even malformed locales from being generated and used. * even malformed locales from being generated and used.
* *
* @param keywordName name of the keyword to be set. Case insensitive. * @param keywordName name of the keyword to be set. Case insensitive.
* @param keywordValue value of the keyword to be set. If 0-length or * @param keywordValue value of the keyword to be set. If 0-length or
* NULL, will result in the keyword being removed. No error is given if * NULL, will result in the keyword being removed. No error is given if
* that keyword does not exist. * that keyword does not exist.
 End of changes. 3 change blocks. 
2 lines changed or deleted 8 lines changed or added


 uniset.h   uniset.h 
/* /*
*************************************************************************** ***************************************************************************
* Copyright (C) 1999-2011, International Business Machines Corporation * Copyright (C) 1999-2013, International Business Machines Corporation
* and others. All Rights Reserved. * and others. All Rights Reserved.
*************************************************************************** ***************************************************************************
* Date Name Description * Date Name Description
* 10/20/99 alan Creation. * 10/20/99 alan Creation.
*************************************************************************** ***************************************************************************
*/ */
#ifndef UNICODESET_H #ifndef UNICODESET_H
#define UNICODESET_H #define UNICODESET_H
skipping to change at line 25 skipping to change at line 25
#include "unicode/unistr.h" #include "unicode/unistr.h"
#include "unicode/uset.h" #include "unicode/uset.h"
/** /**
* \file * \file
* \brief C++ API: Unicode Set * \brief C++ API: Unicode Set
*/ */
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
// Forward Declarations.
void UnicodeSet_initInclusion(int32_t src, UErrorCode &status); /**< @inter
nal */
class BMPSet; class BMPSet;
class ParsePosition; class ParsePosition;
class RBBIRuleScanner; class RBBIRuleScanner;
class SymbolTable; class SymbolTable;
class UnicodeSetStringSpan; class UnicodeSetStringSpan;
class UVector; class UVector;
class RuleCharacterIterator; class RuleCharacterIterator;
/** /**
* A mutable set of Unicode characters and multicharacter strings. Objects of this class * A mutable set of Unicode characters and multicharacter strings. Objects of this class
skipping to change at line 1585 skipping to change at line 1588
* @return a reference to this. * @return a reference to this.
*/ */
UnicodeSet& applyPropertyPattern(const UnicodeString& pattern, UnicodeSet& applyPropertyPattern(const UnicodeString& pattern,
ParsePosition& ppos, ParsePosition& ppos,
UErrorCode &ec); UErrorCode &ec);
void applyPropertyPattern(RuleCharacterIterator& chars, void applyPropertyPattern(RuleCharacterIterator& chars,
UnicodeString& rebuiltPat, UnicodeString& rebuiltPat,
UErrorCode& ec); UErrorCode& ec);
friend void UnicodeSet_initInclusion(int32_t src, UErrorCode &status);
static const UnicodeSet* getInclusions(int32_t src, UErrorCode &status) ; static const UnicodeSet* getInclusions(int32_t src, UErrorCode &status) ;
/** /**
* A filter that returns TRUE if the given code point should be * A filter that returns TRUE if the given code point should be
* included in the UnicodeSet being constructed. * included in the UnicodeSet being constructed.
*/ */
typedef UBool (*Filter)(UChar32 codePoint, void* context); typedef UBool (*Filter)(UChar32 codePoint, void* context);
/** /**
* Given a filter, set this UnicodeSet to the code points * Given a filter, set this UnicodeSet to the code points
 End of changes. 3 change blocks. 
1 lines changed or deleted 6 lines changed or added


 unistr.h   unistr.h 
skipping to change at line 57 skipping to change at line 57
#endif #endif
#ifndef USTRING_H #ifndef USTRING_H
/** /**
* \ingroup ustring_ustrlen * \ingroup ustring_ustrlen
*/ */
U_STABLE int32_t U_EXPORT2 U_STABLE int32_t U_EXPORT2
u_strlen(const UChar *s); u_strlen(const UChar *s);
#endif #endif
#ifndef U_HIDE_INTERNAL_API
/** /**
* \def U_STRING_CASE_MAPPER_DEFINED * \def U_STRING_CASE_MAPPER_DEFINED
* @internal * @internal
*/ */
#ifndef U_STRING_CASE_MAPPER_DEFINED #ifndef U_STRING_CASE_MAPPER_DEFINED
#define U_STRING_CASE_MAPPER_DEFINED #define U_STRING_CASE_MAPPER_DEFINED
/** /**
* Internal string case mapping function type. * Internal string case mapping function type.
* @internal * @internal
*/ */
typedef int32_t U_CALLCONV typedef int32_t U_CALLCONV
UStringCaseMapper(const UCaseMap *csm, UStringCaseMapper(const UCaseMap *csm,
UChar *dest, int32_t destCapacity, UChar *dest, int32_t destCapacity,
const UChar *src, int32_t srcLength, const UChar *src, int32_t srcLength,
UErrorCode *pErrorCode); UErrorCode *pErrorCode);
#endif #endif
#endif /* U_HIDE_INTERNAL_API */
U_NAMESPACE_BEGIN U_NAMESPACE_BEGIN
class BreakIterator; // unicode/brkiter.h class BreakIterator; // unicode/brkiter.h
class Locale; // unicode/locid.h class Locale; // unicode/locid.h
class StringCharacterIterator; class StringCharacterIterator;
class UnicodeStringAppendable; // unicode/appendable.h class UnicodeStringAppendable; // unicode/appendable.h
/* The <iostream> include has been moved to unicode/ustream.h */ /* The <iostream> include has been moved to unicode/ustream.h */
skipping to change at line 344 skipping to change at line 341
* this are bitwise less than the characters in <code>text</code>, +1 if the * this are bitwise less than the characters in <code>text</code>, +1 if the
* characters in this are bitwise greater than the characters * characters in this are bitwise greater than the characters
* in <code>text</code>. * in <code>text</code>.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
inline int8_t compare(const UnicodeString& text) const; inline int8_t compare(const UnicodeString& text) const;
/** /**
* Compare the characters bitwise in the range * Compare the characters bitwise in the range
* [<TT>start</TT>, <TT>start + length</TT>) with the characters * [<TT>start</TT>, <TT>start + length</TT>) with the characters
* in <TT>text</TT> * in the <b>entire string</b> <TT>text</TT>.
* (The parameters "start" and "length" are not applied to the other text
"text".)
* @param start the offset at which the compare operation begins * @param start the offset at which the compare operation begins
* @param length the number of characters of text to compare. * @param length the number of characters of text to compare.
* @param text the other text to be compared against this string. * @param text the other text to be compared against this string.
* @return The result of bitwise character comparison: 0 if this * @return The result of bitwise character comparison: 0 if this
* contains the same characters as <code>text</code>, -1 if the character s in * contains the same characters as <code>text</code>, -1 if the character s in
* this are bitwise less than the characters in <code>text</code>, +1 if the * this are bitwise less than the characters in <code>text</code>, +1 if the
* characters in this are bitwise greater than the characters * characters in this are bitwise greater than the characters
* in <code>text</code>. * in <code>text</code>.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
skipping to change at line 1797 skipping to change at line 1795
inline int32_t hashCode(void) const; inline int32_t hashCode(void) const;
/** /**
* Determine if this object contains a valid string. * Determine if this object contains a valid string.
* A bogus string has no value. It is different from an empty string, * A bogus string has no value. It is different from an empty string,
* although in both cases isEmpty() returns TRUE and length() returns 0. * although in both cases isEmpty() returns TRUE and length() returns 0.
* setToBogus() and isBogus() can be used to indicate that no string valu e is available. * setToBogus() and isBogus() can be used to indicate that no string valu e is available.
* For a bogus string, getBuffer() and getTerminatedBuffer() return NULL, and * For a bogus string, getBuffer() and getTerminatedBuffer() return NULL, and
* length() returns 0. * length() returns 0.
* *
* @return TRUE if the string is valid, FALSE otherwise * @return TRUE if the string is bogus/invalid, FALSE otherwise
* @see setToBogus() * @see setToBogus()
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
inline UBool isBogus(void) const; inline UBool isBogus(void) const;
//======================================== //========================================
// Write operations // Write operations
//======================================== //========================================
/* Assignment operations */ /* Assignment operations */
skipping to change at line 2840 skipping to change at line 2838
* The buffer may reside in read-only memory. Its contents must not * The buffer may reside in read-only memory. Its contents must not
* be modified. * be modified.
* *
* @return a read-only pointer to the internal string buffer, * @return a read-only pointer to the internal string buffer,
* or 0 if the string is empty or bogus * or 0 if the string is empty or bogus
* *
* @see getBuffer(int32_t minCapacity) * @see getBuffer(int32_t minCapacity)
* @see getBuffer() * @see getBuffer()
* @stable ICU 2.2 * @stable ICU 2.2
*/ */
inline const UChar *getTerminatedBuffer(); const UChar *getTerminatedBuffer();
//======================================== //========================================
// Constructors // Constructors
//======================================== //========================================
/** Construct an empty UnicodeString. /** Construct an empty UnicodeString.
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
inline UnicodeString(); inline UnicodeString();
skipping to change at line 4275 skipping to change at line 4273
fFlags = kShortString; fFlags = kShortString;
} }
inline void inline void
UnicodeString::setArray(UChar *array, int32_t len, int32_t capacity) { UnicodeString::setArray(UChar *array, int32_t len, int32_t capacity) {
setLength(len); setLength(len);
fUnion.fFields.fArray = array; fUnion.fFields.fArray = array;
fUnion.fFields.fCapacity = capacity; fUnion.fFields.fCapacity = capacity;
} }
inline const UChar *
UnicodeString::getTerminatedBuffer() {
if(!isWritable()) {
return 0;
} else {
UChar *array = getArrayStart();
int32_t len = length();
if(len < getCapacity() && ((fFlags&kRefCounted) == 0 || refCount() == 1
)) {
/*
* kRefCounted: Do not write the NUL if the buffer is shared.
* That is mostly safe, except when the length of one copy was modifi
ed
* without copy-on-write, e.g., via truncate(newLength) or remove(voi
d).
* Then the NUL would be written into the middle of another copy's st
ring.
*/
if(!(fFlags&kBufferIsReadonly)) {
/*
* We must not write to a readonly buffer, but it is known to be
* NUL-terminated if len<capacity.
* A shared, allocated buffer (refCount()>1) must not have its cont
ents
* modified, but the NUL at [len] is beyond the string contents,
* and multiple string objects and threads writing the same NUL int
o the
* same location is harmless.
* In all other cases, the buffer is fully writable and it is anywa
y safe
* to write the NUL.
*
* Note: An earlier version of this code tested whether there is a
NUL
* at [len] already, but, while safe, it generated lots of warnings
from
* tools like valgrind and Purify.
*/
array[len] = 0;
}
return array;
} else if(cloneArrayIfNeeded(len+1)) {
array = getArrayStart();
array[len] = 0;
return array;
} else {
return 0;
}
}
}
inline UnicodeString& inline UnicodeString&
UnicodeString::operator= (UChar ch) UnicodeString::operator= (UChar ch)
{ return doReplace(0, length(), &ch, 0, 1); } { return doReplace(0, length(), &ch, 0, 1); }
inline UnicodeString& inline UnicodeString&
UnicodeString::operator= (UChar32 ch) UnicodeString::operator= (UChar32 ch)
{ return replace(0, length(), ch); } { return replace(0, length(), ch); }
inline UnicodeString& inline UnicodeString&
UnicodeString::setTo(const UnicodeString& srcText, UnicodeString::setTo(const UnicodeString& srcText,
skipping to change at line 4448 skipping to change at line 4404
inline UnicodeString& inline UnicodeString&
UnicodeString::insert(int32_t start, UnicodeString::insert(int32_t start,
UChar32 srcChar) UChar32 srcChar)
{ return replace(start, 0, srcChar); } { return replace(start, 0, srcChar); }
inline UnicodeString& inline UnicodeString&
UnicodeString::remove() UnicodeString::remove()
{ {
// remove() of a bogus string makes the string empty and non-bogus // remove() of a bogus string makes the string empty and non-bogus
// we also un-alias a read-only alias to deal with NUL-termination if(isBogus()) {
// issues with getTerminatedBuffer()
if(fFlags & (kIsBogus|kBufferIsReadonly)) {
setToEmpty(); setToEmpty();
} else { } else {
fShortLength = 0; fShortLength = 0;
} }
return *this; return *this;
} }
inline UnicodeString& inline UnicodeString&
UnicodeString::remove(int32_t start, UnicodeString::remove(int32_t start,
int32_t _length) int32_t _length)
skipping to change at line 4489 skipping to change at line 4443
inline UBool inline UBool
UnicodeString::truncate(int32_t targetLength) UnicodeString::truncate(int32_t targetLength)
{ {
if(isBogus() && targetLength == 0) { if(isBogus() && targetLength == 0) {
// truncate(0) of a bogus string makes the string empty and non-bogus // truncate(0) of a bogus string makes the string empty and non-bogus
unBogus(); unBogus();
return FALSE; return FALSE;
} else if((uint32_t)targetLength < (uint32_t)length()) { } else if((uint32_t)targetLength < (uint32_t)length()) {
setLength(targetLength); setLength(targetLength);
if(fFlags&kBufferIsReadonly) {
fUnion.fFields.fCapacity = targetLength; // not NUL-terminated any m
ore
}
return TRUE; return TRUE;
} else { } else {
return FALSE; return FALSE;
} }
} }
inline UnicodeString& inline UnicodeString&
UnicodeString::reverse() UnicodeString::reverse()
{ return doReverse(0, length()); } { return doReverse(0, length()); }
 End of changes. 9 change blocks. 
64 lines changed or deleted 6 lines changed or added


 unum.h   unum.h 
skipping to change at line 23 skipping to change at line 23
#define _UNUM #define _UNUM
#include "unicode/utypes.h" #include "unicode/utypes.h"
#if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_FORMATTING
#include "unicode/localpointer.h" #include "unicode/localpointer.h"
#include "unicode/uloc.h" #include "unicode/uloc.h"
#include "unicode/umisc.h" #include "unicode/umisc.h"
#include "unicode/parseerr.h" #include "unicode/parseerr.h"
#include "unicode/uformattable.h"
/** /**
* \file * \file
* \brief C API: NumberFormat * \brief C API: NumberFormat
* *
* <h2> Number Format C API </h2> * <h2> Number Format C API </h2>
* *
* Number Format C API Provides functions for * Number Format C API Provides functions for
* formatting and parsing a number. Also provides methods for * formatting and parsing a number. Also provides methods for
* determining which locales have number formats, and what their names * determining which locales have number formats, and what their names
* are. * are.
skipping to change at line 234 skipping to change at line 236
* @stable, ICU 3.8 * @stable, ICU 3.8
*/ */
UNUM_ROUND_HALFEVEN, UNUM_ROUND_HALFEVEN,
#ifndef U_HIDE_DEPRECATED_API #ifndef U_HIDE_DEPRECATED_API
/** /**
* Half-even rounding, misspelled name * Half-even rounding, misspelled name
* @deprecated, ICU 3.8 * @deprecated, ICU 3.8
*/ */
UNUM_FOUND_HALFEVEN = UNUM_ROUND_HALFEVEN, UNUM_FOUND_HALFEVEN = UNUM_ROUND_HALFEVEN,
#endif /* U_HIDE_DEPRECATED_API */ #endif /* U_HIDE_DEPRECATED_API */
UNUM_ROUND_HALFDOWN, UNUM_ROUND_HALFDOWN = UNUM_ROUND_HALFEVEN + 1,
UNUM_ROUND_HALFUP, UNUM_ROUND_HALFUP,
/** /**
* ROUND_UNNECESSARY reports an error if formatted result is not exact . * ROUND_UNNECESSARY reports an error if formatted result is not exact .
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
UNUM_ROUND_UNNECESSARY UNUM_ROUND_UNNECESSARY
} UNumberFormatRoundingMode; } UNumberFormatRoundingMode;
/** The possible number format pad positions. /** The possible number format pad positions.
* @stable ICU 2.0 * @stable ICU 2.0
skipping to change at line 399 skipping to change at line 401
*/ */
U_STABLE UNumberFormat* U_EXPORT2 U_STABLE UNumberFormat* U_EXPORT2
unum_clone(const UNumberFormat *fmt, unum_clone(const UNumberFormat *fmt,
UErrorCode *status); UErrorCode *status);
/** /**
* Format an integer using a UNumberFormat. * Format an integer using a UNumberFormat.
* The integer will be formatted according to the UNumberFormat's locale. * The integer will be formatted according to the UNumberFormat's locale.
* @param fmt The formatter to use. * @param fmt The formatter to use.
* @param number The number to format. * @param number The number to format.
* @param result A pointer to a buffer to receive the formatted number. * @param result A pointer to a buffer to receive the NULL-terminated format
ted number. If
* the formatted number fits into dest but cannot be NULL-terminated (length
== resultLength)
* then the error code is set to U_STRING_NOT_TERMINATED_WARNING. If the for
matted number
* doesn't fit into result then the error code is set to U_BUFFER_OVERFLOW_E
RROR.
* @param resultLength The maximum size of result. * @param resultLength The maximum size of result.
* @param pos A pointer to a UFieldPosition. On input, position->field * @param pos A pointer to a UFieldPosition. On input, position->field
* is read. On output, position->beginIndex and position->endIndex indicate * is read. On output, position->beginIndex and position->endIndex indicate
* the beginning and ending indices of field number position->field, if such * the beginning and ending indices of field number position->field, if such
* a field exists. This parameter may be NULL, in which case no field * a field exists. This parameter may be NULL, in which case no field
* @param status A pointer to an UErrorCode to receive any errors * @param status A pointer to an UErrorCode to receive any errors
* @return The total buffer size needed; if greater than resultLength, the o utput was truncated. * @return The total buffer size needed; if greater than resultLength, the o utput was truncated.
* @see unum_formatInt64 * @see unum_formatInt64
* @see unum_formatDouble * @see unum_formatDouble
* @see unum_parse * @see unum_parse
skipping to change at line 428 skipping to change at line 433
UChar* result, UChar* result,
int32_t resultLength, int32_t resultLength,
UFieldPosition *pos, UFieldPosition *pos,
UErrorCode* status); UErrorCode* status);
/** /**
* Format an int64 using a UNumberFormat. * Format an int64 using a UNumberFormat.
* The int64 will be formatted according to the UNumberFormat's locale. * The int64 will be formatted according to the UNumberFormat's locale.
* @param fmt The formatter to use. * @param fmt The formatter to use.
* @param number The number to format. * @param number The number to format.
* @param result A pointer to a buffer to receive the formatted number. * @param result A pointer to a buffer to receive the NULL-terminated format
ted number. If
* the formatted number fits into dest but cannot be NULL-terminated (length
== resultLength)
* then the error code is set to U_STRING_NOT_TERMINATED_WARNING. If the for
matted number
* doesn't fit into result then the error code is set to U_BUFFER_OVERFLOW_E
RROR.
* @param resultLength The maximum size of result. * @param resultLength The maximum size of result.
* @param pos A pointer to a UFieldPosition. On input, position->field * @param pos A pointer to a UFieldPosition. On input, position->field
* is read. On output, position->beginIndex and position->endIndex indicate * is read. On output, position->beginIndex and position->endIndex indicate
* the beginning and ending indices of field number position->field, if such * the beginning and ending indices of field number position->field, if such
* a field exists. This parameter may be NULL, in which case no field * a field exists. This parameter may be NULL, in which case no field
* @param status A pointer to an UErrorCode to receive any errors * @param status A pointer to an UErrorCode to receive any errors
* @return The total buffer size needed; if greater than resultLength, the o utput was truncated. * @return The total buffer size needed; if greater than resultLength, the o utput was truncated.
* @see unum_format * @see unum_format
* @see unum_formatDouble * @see unum_formatDouble
* @see unum_parse * @see unum_parse
skipping to change at line 457 skipping to change at line 465
UChar* result, UChar* result,
int32_t resultLength, int32_t resultLength,
UFieldPosition *pos, UFieldPosition *pos,
UErrorCode* status); UErrorCode* status);
/** /**
* Format a double using a UNumberFormat. * Format a double using a UNumberFormat.
* The double will be formatted according to the UNumberFormat's locale. * The double will be formatted according to the UNumberFormat's locale.
* @param fmt The formatter to use. * @param fmt The formatter to use.
* @param number The number to format. * @param number The number to format.
* @param result A pointer to a buffer to receive the formatted number. * @param result A pointer to a buffer to receive the NULL-terminated format
ted number. If
* the formatted number fits into dest but cannot be NULL-terminated (length
== resultLength)
* then the error code is set to U_STRING_NOT_TERMINATED_WARNING. If the for
matted number
* doesn't fit into result then the error code is set to U_BUFFER_OVERFLOW_E
RROR.
* @param resultLength The maximum size of result. * @param resultLength The maximum size of result.
* @param pos A pointer to a UFieldPosition. On input, position->field * @param pos A pointer to a UFieldPosition. On input, position->field
* is read. On output, position->beginIndex and position->endIndex indicate * is read. On output, position->beginIndex and position->endIndex indicate
* the beginning and ending indices of field number position->field, if such * the beginning and ending indices of field number position->field, if such
* a field exists. This parameter may be NULL, in which case no field * a field exists. This parameter may be NULL, in which case no field
* @param status A pointer to an UErrorCode to receive any errors * @param status A pointer to an UErrorCode to receive any errors
* @return The total buffer size needed; if greater than resultLength, the o utput was truncated. * @return The total buffer size needed; if greater than resultLength, the o utput was truncated.
* @see unum_format * @see unum_format
* @see unum_formatInt64 * @see unum_formatInt64
* @see unum_parse * @see unum_parse
skipping to change at line 490 skipping to change at line 501
/** /**
* Format a decimal number using a UNumberFormat. * Format a decimal number using a UNumberFormat.
* The number will be formatted according to the UNumberFormat's locale. * The number will be formatted according to the UNumberFormat's locale.
* The syntax of the input number is a "numeric string" * The syntax of the input number is a "numeric string"
* as defined in the Decimal Arithmetic Specification, available at * as defined in the Decimal Arithmetic Specification, available at
* http://speleotrove.com/decimal * http://speleotrove.com/decimal
* @param fmt The formatter to use. * @param fmt The formatter to use.
* @param number The number to format. * @param number The number to format.
* @param length The length of the input number, or -1 if the input is nul-t erminated. * @param length The length of the input number, or -1 if the input is nul-t erminated.
* @param result A pointer to a buffer to receive the formatted number. * @param result A pointer to a buffer to receive the NULL-terminated format
ted number. If
* the formatted number fits into dest but cannot be NULL-terminated (length
== resultLength)
* then the error code is set to U_STRING_NOT_TERMINATED_WARNING. If the for
matted number
* doesn't fit into result then the error code is set to U_BUFFER_OVERFLOW_E
RROR.
* @param resultLength The maximum size of result. * @param resultLength The maximum size of result.
* @param pos A pointer to a UFieldPosition. On input, position->field * @param pos A pointer to a UFieldPosition. On input, position->field
* is read. On output, position->beginIndex and position->end Index indicate * is read. On output, position->beginIndex and position->end Index indicate
* the beginning and ending indices of field number position-> field, if such * the beginning and ending indices of field number position-> field, if such
* a field exists. This parameter may be NULL, in which case it is ignored. * a field exists. This parameter may be NULL, in which case it is ignored.
* @param status A pointer to an UErrorCode to receive any errors * @param status A pointer to an UErrorCode to receive any errors
* @return The total buffer size needed; if greater than resultLength, the o utput was truncated. * @return The total buffer size needed; if greater than resultLength, the o utput was truncated.
* @see unum_format * @see unum_format
* @see unum_formatInt64 * @see unum_formatInt64
* @see unum_parse * @see unum_parse
skipping to change at line 521 skipping to change at line 535
int32_t resultLength, int32_t resultLength,
UFieldPosition *pos, /* 0 if ignore */ UFieldPosition *pos, /* 0 if ignore */
UErrorCode* status); UErrorCode* status);
/** /**
* Format a double currency amount using a UNumberFormat. * Format a double currency amount using a UNumberFormat.
* The double will be formatted according to the UNumberFormat's locale. * The double will be formatted according to the UNumberFormat's locale.
* @param fmt the formatter to use * @param fmt the formatter to use
* @param number the number to format * @param number the number to format
* @param currency the 3-letter null-terminated ISO 4217 currency code * @param currency the 3-letter null-terminated ISO 4217 currency code
* @param result a pointer to the buffer to receive the formatted number * @param result A pointer to a buffer to receive the NULL-terminated forma
tted number. If
* the formatted number fits into dest but cannot be NULL-terminated (lengt
h == resultLength)
* then the error code is set to U_STRING_NOT_TERMINATED_WARNING. If the fo
rmatted number
* doesn't fit into result then the error code is set to U_BUFFER_OVERFLOW_
ERROR.
* @param resultLength the maximum number of UChars to write to result * @param resultLength the maximum number of UChars to write to result
* @param pos a pointer to a UFieldPosition. On input, * @param pos a pointer to a UFieldPosition. On input,
* position->field is read. On output, position->beginIndex and * position->field is read. On output, position->beginIndex and
* position->endIndex indicate the beginning and ending indices of * position->endIndex indicate the beginning and ending indices of
* field number position->field, if such a field exists. This * field number position->field, if such a field exists. This
* parameter may be NULL, in which case it is ignored. * parameter may be NULL, in which case it is ignored.
* @param status a pointer to an input-output UErrorCode * @param status a pointer to an input-output UErrorCode
* @return the total buffer size needed; if greater than resultLength, * @return the total buffer size needed; if greater than resultLength,
* the output was truncated. * the output was truncated.
* @see unum_formatDouble * @see unum_formatDouble
* @see unum_parseDoubleCurrency * @see unum_parseDoubleCurrency
* @see UFieldPosition * @see UFieldPosition
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE int32_t U_EXPORT2 U_STABLE int32_t U_EXPORT2
unum_formatDoubleCurrency(const UNumberFormat* fmt, unum_formatDoubleCurrency(const UNumberFormat* fmt,
double number, double number,
UChar* currency, UChar* currency,
UChar* result, UChar* result,
int32_t resultLength, int32_t resultLength,
UFieldPosition* pos, /* ignored if 0 */ UFieldPosition* pos,
UErrorCode* status); UErrorCode* status);
#ifndef U_HIDE_DRAFT_API
/**
* Format a UFormattable into a string.
* @param fmt the formatter to use
* @param number the number to format, as a UFormattable
* @param result A pointer to a buffer to receive the NULL-terminated forma
tted number. If
* the formatted number fits into dest but cannot be NULL-terminated (lengt
h == resultLength)
* then the error code is set to U_STRING_NOT_TERMINATED_WARNING. If the fo
rmatted number
* doesn't fit into result then the error code is set to U_BUFFER_OVERFLOW_
ERROR.
* @param resultLength the maximum number of UChars to write to result
* @param pos a pointer to a UFieldPosition. On input,
* position->field is read. On output, position->beginIndex and
* position->endIndex indicate the beginning and ending indices of
* field number position->field, if such a field exists. This
* parameter may be NULL, in which case it is ignored.
* @param status a pointer to an input-output UErrorCode
* @return the total buffer size needed; if greater than resultLength,
* the output was truncated. Will return 0 on error.
* @see unum_parseToUFormattable
* @draft ICU 52
*/
U_DRAFT int32_t U_EXPORT2
unum_formatUFormattable(const UNumberFormat* fmt,
const UFormattable *number,
UChar *result,
int32_t resultLength,
UFieldPosition *pos,
UErrorCode *status);
#endif /* U_HIDE_DRAFT_API */
/** /**
* Parse a string into an integer using a UNumberFormat. * Parse a string into an integer using a UNumberFormat.
* The string will be parsed according to the UNumberFormat's locale. * The string will be parsed according to the UNumberFormat's locale.
* @param fmt The formatter to use. * @param fmt The formatter to use.
* @param text The text to parse. * @param text The text to parse.
* @param textLength The length of text, or -1 if null-terminated. * @param textLength The length of text, or -1 if null-terminated.
* @param parsePos If not 0, on input a pointer to an integer specifying the * @param parsePos If not NULL, on input a pointer to an integer specifying
offset at which the offset at which
* to begin parsing. If not 0, on output the offset at which parsing ended. * to begin parsing. If not NULL, on output the offset at which parsing end
ed.
* @param status A pointer to an UErrorCode to receive any errors * @param status A pointer to an UErrorCode to receive any errors
* @return The value of the parsed integer * @return The value of the parsed integer
* @see unum_parseInt64 * @see unum_parseInt64
* @see unum_parseDouble * @see unum_parseDouble
* @see unum_format * @see unum_format
* @see unum_formatInt64 * @see unum_formatInt64
* @see unum_formatDouble * @see unum_formatDouble
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE int32_t U_EXPORT2 U_STABLE int32_t U_EXPORT2
skipping to change at line 575 skipping to change at line 622
int32_t textLength, int32_t textLength,
int32_t *parsePos /* 0 = start */, int32_t *parsePos /* 0 = start */,
UErrorCode *status); UErrorCode *status);
/** /**
* Parse a string into an int64 using a UNumberFormat. * Parse a string into an int64 using a UNumberFormat.
* The string will be parsed according to the UNumberFormat's locale. * The string will be parsed according to the UNumberFormat's locale.
* @param fmt The formatter to use. * @param fmt The formatter to use.
* @param text The text to parse. * @param text The text to parse.
* @param textLength The length of text, or -1 if null-terminated. * @param textLength The length of text, or -1 if null-terminated.
* @param parsePos If not 0, on input a pointer to an integer specifying the * @param parsePos If not NULL, on input a pointer to an integer specifying
offset at which the offset at which
* to begin parsing. If not 0, on output the offset at which parsing ended. * to begin parsing. If not NULL, on output the offset at which parsing end
ed.
* @param status A pointer to an UErrorCode to receive any errors * @param status A pointer to an UErrorCode to receive any errors
* @return The value of the parsed integer * @return The value of the parsed integer
* @see unum_parse * @see unum_parse
* @see unum_parseDouble * @see unum_parseDouble
* @see unum_format * @see unum_format
* @see unum_formatInt64 * @see unum_formatInt64
* @see unum_formatDouble * @see unum_formatDouble
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
U_STABLE int64_t U_EXPORT2 U_STABLE int64_t U_EXPORT2
skipping to change at line 599 skipping to change at line 646
int32_t textLength, int32_t textLength,
int32_t *parsePos /* 0 = start */, int32_t *parsePos /* 0 = start */,
UErrorCode *status); UErrorCode *status);
/** /**
* Parse a string into a double using a UNumberFormat. * Parse a string into a double using a UNumberFormat.
* The string will be parsed according to the UNumberFormat's locale. * The string will be parsed according to the UNumberFormat's locale.
* @param fmt The formatter to use. * @param fmt The formatter to use.
* @param text The text to parse. * @param text The text to parse.
* @param textLength The length of text, or -1 if null-terminated. * @param textLength The length of text, or -1 if null-terminated.
* @param parsePos If not 0, on input a pointer to an integer specifying the * @param parsePos If not NULL, on input a pointer to an integer specifying
offset at which the offset at which
* to begin parsing. If not 0, on output the offset at which parsing ended. * to begin parsing. If not NULL, on output the offset at which parsing end
ed.
* @param status A pointer to an UErrorCode to receive any errors * @param status A pointer to an UErrorCode to receive any errors
* @return The value of the parsed double * @return The value of the parsed double
* @see unum_parse * @see unum_parse
* @see unum_parseInt64 * @see unum_parseInt64
* @see unum_format * @see unum_format
* @see unum_formatInt64 * @see unum_formatInt64
* @see unum_formatDouble * @see unum_formatDouble
* @stable ICU 2.0 * @stable ICU 2.0
*/ */
U_STABLE double U_EXPORT2 U_STABLE double U_EXPORT2
skipping to change at line 626 skipping to change at line 673
/** /**
* Parse a number from a string into an unformatted numeric string using a U NumberFormat. * Parse a number from a string into an unformatted numeric string using a U NumberFormat.
* The input string will be parsed according to the UNumberFormat's locale. * The input string will be parsed according to the UNumberFormat's locale.
* The syntax of the output is a "numeric string" * The syntax of the output is a "numeric string"
* as defined in the Decimal Arithmetic Specification, available at * as defined in the Decimal Arithmetic Specification, available at
* http://speleotrove.com/decimal * http://speleotrove.com/decimal
* @param fmt The formatter to use. * @param fmt The formatter to use.
* @param text The text to parse. * @param text The text to parse.
* @param textLength The length of text, or -1 if null-terminated. * @param textLength The length of text, or -1 if null-terminated.
* @param parsePos If not 0, on input a pointer to an integer specifying the * @param parsePos If not NULL, on input a pointer to an integer specifying
offset at which the offset at which
* to begin parsing. If not 0, on output the offset at whic * to begin parsing. If not NULL, on output the offset at w
h parsing ended. hich parsing ended.
* @param outBuf A (char *) buffer to receive the parsed number as a string. The output string * @param outBuf A (char *) buffer to receive the parsed number as a string. The output string
* will be nul-terminated if there is sufficient space. * will be nul-terminated if there is sufficient space.
* @param outBufLength The size of the output buffer. May be zero, in which case * @param outBufLength The size of the output buffer. May be zero, in which case
* the outBuf pointer may be NULL, and the function will retur n the * the outBuf pointer may be NULL, and the function will retur n the
* size of the output string. * size of the output string.
* @param status A pointer to an UErrorCode to receive any errors * @param status A pointer to an UErrorCode to receive any errors
* @return the length of the output string, not including any terminating nu l. * @return the length of the output string, not including any terminating nu l.
* @see unum_parse * @see unum_parse
* @see unum_parseInt64 * @see unum_parseInt64
* @see unum_format * @see unum_format
skipping to change at line 659 skipping to change at line 706
UErrorCode *status); UErrorCode *status);
/** /**
* Parse a string into a double and a currency using a UNumberFormat. * Parse a string into a double and a currency using a UNumberFormat.
* The string will be parsed according to the UNumberFormat's locale. * The string will be parsed according to the UNumberFormat's locale.
* @param fmt the formatter to use * @param fmt the formatter to use
* @param text the text to parse * @param text the text to parse
* @param textLength the length of text, or -1 if null-terminated * @param textLength the length of text, or -1 if null-terminated
* @param parsePos a pointer to an offset index into text at which to * @param parsePos a pointer to an offset index into text at which to
* begin parsing. On output, *parsePos will point after the last * begin parsing. On output, *parsePos will point after the last
* parsed character. This parameter may be 0, in which case parsing * parsed character. This parameter may be NULL, in which case parsing
* begins at offset 0. * begins at offset 0.
* @param currency a pointer to the buffer to receive the parsed null- * @param currency a pointer to the buffer to receive the parsed null-
* terminated currency. This buffer must have a capacity of at least * terminated currency. This buffer must have a capacity of at least
* 4 UChars. * 4 UChars.
* @param status a pointer to an input-output UErrorCode * @param status a pointer to an input-output UErrorCode
* @return the parsed double * @return the parsed double
* @see unum_parseDouble * @see unum_parseDouble
* @see unum_formatDoubleCurrency * @see unum_formatDoubleCurrency
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
U_STABLE double U_EXPORT2 U_STABLE double U_EXPORT2
unum_parseDoubleCurrency(const UNumberFormat* fmt, unum_parseDoubleCurrency(const UNumberFormat* fmt,
const UChar* text, const UChar* text,
int32_t textLength, int32_t textLength,
int32_t* parsePos, /* 0 = start */ int32_t* parsePos, /* 0 = start */
UChar* currency, UChar* currency,
UErrorCode* status); UErrorCode* status);
#ifndef U_HIDE_DRAFT_API
/**
* Parse a UChar string into a UFormattable.
* Example code:
* \snippet test/cintltst/cnumtst.c unum_parseToUFormattable
* @param fmt the formatter to use
* @param result the UFormattable to hold the result. If NULL, a new UForma
ttable will be allocated (which the caller must close with ufmt_close).
* @param text the text to parse
* @param textLength the length of text, or -1 if null-terminated
* @param parsePos a pointer to an offset index into text at which to
* begin parsing. On output, *parsePos will point after the last
* parsed character. This parameter may be NULL in which case parsing
* begins at offset 0.
* @param status a pointer to an input-output UErrorCode
* @return the UFormattable. Will be ==result unless NULL was passed in fo
r result, in which case it will be the newly opened UFormattable.
* @see ufmt_getType
* @see ufmt_close
* @draft ICU 52
*/
U_DRAFT UFormattable* U_EXPORT2
unum_parseToUFormattable(const UNumberFormat* fmt,
UFormattable *result,
const UChar* text,
int32_t textLength,
int32_t* parsePos, /* 0 = start */
UErrorCode* status);
#endif /* U_HIDE_DRAFT_API */
/** /**
* Set the pattern used by a UNumberFormat. This can only be used * Set the pattern used by a UNumberFormat. This can only be used
* on a DecimalFormat, other formats return U_UNSUPPORTED_ERROR * on a DecimalFormat, other formats return U_UNSUPPORTED_ERROR
* in the status. * in the status.
* @param format The formatter to set. * @param format The formatter to set.
* @param localized TRUE if the pattern is localized, FALSE otherwise. * @param localized TRUE if the pattern is localized, FALSE otherwise.
* @param pattern The new pattern * @param pattern The new pattern
* @param patternLength The length of pattern, or -1 if null-terminated. * @param patternLength The length of pattern, or -1 if null-terminated.
* @param parseError A pointer to UParseError to recieve information * @param parseError A pointer to UParseError to recieve information
* about errors occurred during parsing, or NULL if no parse error * about errors occurred during parsing, or NULL if no parse error
skipping to change at line 794 skipping to change at line 869
UNUM_MAX_SIGNIFICANT_DIGITS, UNUM_MAX_SIGNIFICANT_DIGITS,
/** Lenient parse mode used by rule-based formats. /** Lenient parse mode used by rule-based formats.
* @stable ICU 3.0 * @stable ICU 3.0
*/ */
UNUM_LENIENT_PARSE, UNUM_LENIENT_PARSE,
#if UCONFIG_HAVE_PARSEALLINPUT #if UCONFIG_HAVE_PARSEALLINPUT
/** Consume all input. (may use fastpath). Set to UNUM_YES (require fastp ath), UNUM_NO (skip fastpath), or UNUM_MAYBE (heuristic). /** Consume all input. (may use fastpath). Set to UNUM_YES (require fastp ath), UNUM_NO (skip fastpath), or UNUM_MAYBE (heuristic).
* This is an internal ICU API. Do not use. * This is an internal ICU API. Do not use.
* @internal * @internal
*/ */
UNUM_PARSE_ALL_INPUT, UNUM_PARSE_ALL_INPUT = UNUM_LENIENT_PARSE + 1,
#endif #endif
#ifndef U_HIDE_DRAFT_API #ifndef U_HIDE_DRAFT_API
/** /**
* Scale, which adjusts the position of the * Scale, which adjusts the position of the
* decimal point when formatting. Amounts will be multiplied by 10 ^ (s cale) * decimal point when formatting. Amounts will be multiplied by 10 ^ (s cale)
* before they are formatted. The default value for the scale is 0 ( no adjustment ). * before they are formatted. The default value for the scale is 0 ( no adjustment ).
* *
* <p>Example: setting the scale to 3, 123 formats as "123,000" * <p>Example: setting the scale to 3, 123 formats as "123,000"
* <p>Example: setting the scale to -4, 123 formats as "0.0123" * <p>Example: setting the scale to -4, 123 formats as "0.0123"
* *
* @draft ICU 51 */ * @draft ICU 51 */
UNUM_SCALE = UNUM_LENIENT_PARSE + 2, UNUM_SCALE = UNUM_LENIENT_PARSE + 2,
#endif /* U_HIDE_DRAFT_API */ #endif /* U_HIDE_DRAFT_API */
#ifndef U_HIDE_INTERNAL_API #ifndef U_HIDE_INTERNAL_API
/** Count of "regular" numeric attributes. /** Count of "regular" numeric attributes.
* @internal */ * @internal */
UNUM_NUMERIC_ATTRIBUTE_COUNT, UNUM_NUMERIC_ATTRIBUTE_COUNT = UNUM_LENIENT_PARSE + 3,
/** One below the first bitfield-boolean item. /** One below the first bitfield-boolean item.
* All items after this one are stored in boolean form. * All items after this one are stored in boolean form.
* @internal */ * @internal */
UNUM_MAX_NONBOOLEAN_ATTRIBUTE = 0x0FFF, UNUM_MAX_NONBOOLEAN_ATTRIBUTE = 0x0FFF,
#endif /* U_HIDE_INTERNAL_API */ #endif /* U_HIDE_INTERNAL_API */
#ifndef U_HIDE_DRAFT_API
/** If 1, specifies that if setting the "max integer digits" attribute wo uld truncate a value, set an error status rather than silently truncating. /** If 1, specifies that if setting the "max integer digits" attribute wo uld truncate a value, set an error status rather than silently truncating.
* For example, formatting the value 1234 with 4 max int digits would su cceed, but formatting 12345 would fail. There is no effect on parsing. * For example, formatting the value 1234 with 4 max int digits would su cceed, but formatting 12345 would fail. There is no effect on parsing.
* Default: 0 (not set) * Default: 0 (not set)
* @draft ICU 50 * @stable ICU 50
*/ */
UNUM_FORMAT_FAIL_IF_MORE_THAN_MAX_DIGITS = 0x1000, UNUM_FORMAT_FAIL_IF_MORE_THAN_MAX_DIGITS = 0x1000,
/** /**
* if this attribute is set to 1, specifies that, if the pattern doesn't contain an exponent, the exponent will not be parsed. If the pattern does c ontain an exponent, this attribute has no effect. * if this attribute is set to 1, specifies that, if the pattern doesn't contain an exponent, the exponent will not be parsed. If the pattern does c ontain an exponent, this attribute has no effect.
* Has no effect on formatting. * Has no effect on formatting.
* Default: 0 (unset) * Default: 0 (unset)
* @draft ICU 50 * @stable ICU 50
*/ */
UNUM_PARSE_NO_EXPONENT, UNUM_PARSE_NO_EXPONENT,
#endif /* U_HIDE_DRAFT_API */
#ifndef U_HIDE_INTERNAL_API #ifndef U_HIDE_INTERNAL_API
/** Limit of boolean attributes. /** Limit of boolean attributes.
* @internal */ * @internal */
UNUM_LIMIT_BOOLEAN_ATTRIBUTE UNUM_LIMIT_BOOLEAN_ATTRIBUTE
#endif /* U_HIDE_INTERNAL_API */ #endif /* U_HIDE_INTERNAL_API */
} UNumberFormatAttribute; } UNumberFormatAttribute;
/** /**
* Get a numeric attribute associated with a UNumberFormat. * Get a numeric attribute associated with a UNumberFormat.
 End of changes. 22 change blocks. 
27 lines changed or deleted 130 lines changed or added


 upluralrules.h   upluralrules.h 
skipping to change at line 40 skipping to change at line 40
* *
* Keywords: ICU locale data has 6 predefined values - * Keywords: ICU locale data has 6 predefined values -
* 'zero', 'one', 'two', 'few', 'many' and 'other'. Callers need to check * 'zero', 'one', 'two', 'few', 'many' and 'other'. Callers need to check
* the value of keyword returned by the uplrules_select function. * the value of keyword returned by the uplrules_select function.
* *
* These are based on CLDR <i>Language Plural Rules</i>. For these * These are based on CLDR <i>Language Plural Rules</i>. For these
* predefined rules, see the CLDR page at * predefined rules, see the CLDR page at
* http://unicode.org/repos/cldr-tmp/trunk/diff/supplemental/language_plura l_rules.html * http://unicode.org/repos/cldr-tmp/trunk/diff/supplemental/language_plura l_rules.html
*/ */
#ifndef U_HIDE_DRAFT_API
/** /**
* Type of plurals and PluralRules. * Type of plurals and PluralRules.
* @draft ICU 50 * @stable ICU 50
*/ */
enum UPluralType { enum UPluralType {
/** /**
* Plural rules for cardinal numbers: 1 file vs. 2 files. * Plural rules for cardinal numbers: 1 file vs. 2 files.
* @draft ICU 50 * @stable ICU 50
*/ */
UPLURAL_TYPE_CARDINAL, UPLURAL_TYPE_CARDINAL,
/** /**
* Plural rules for ordinal numbers: 1st file, 2nd file, 3rd file, 4th file, etc. * Plural rules for ordinal numbers: 1st file, 2nd file, 3rd file, 4th file, etc.
* @draft ICU 50 * @stable ICU 50
*/ */
UPLURAL_TYPE_ORDINAL, UPLURAL_TYPE_ORDINAL,
/** /**
* Number of Plural rules types. * Number of Plural rules types.
* @draft ICU 50 * @stable ICU 50
*/ */
UPLURAL_TYPE_COUNT UPLURAL_TYPE_COUNT
}; };
/** /**
* @draft ICU 50 * @stable ICU 50
*/ */
typedef enum UPluralType UPluralType; typedef enum UPluralType UPluralType;
#endif /* U_HIDE_DRAFT_API */
/** /**
* Opaque UPluralRules object for use in C programs. * Opaque UPluralRules object for use in C programs.
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
struct UPluralRules; struct UPluralRules;
typedef struct UPluralRules UPluralRules; /**< C typedef for struct UPlura lRules. @stable ICU 4.8 */ typedef struct UPluralRules UPluralRules; /**< C typedef for struct UPlura lRules. @stable ICU 4.8 */
/** /**
* Opens a new UPluralRules object using the predefined cardinal-number plu ral rules for a * Opens a new UPluralRules object using the predefined cardinal-number plu ral rules for a
* given locale. * given locale.
* Same as uplrules_openForType(locale, UPLURAL_TYPE_CARDINAL, status). * Same as uplrules_openForType(locale, UPLURAL_TYPE_CARDINAL, status).
* @param locale The locale for which the rules are desired. * @param locale The locale for which the rules are desired.
* @param status A pointer to a UErrorCode to receive any errors. * @param status A pointer to a UErrorCode to receive any errors.
* @return A UPluralRules for the specified locale, or NULL if an error occ urred. * @return A UPluralRules for the specified locale, or NULL if an error occ urred.
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
U_STABLE UPluralRules* U_EXPORT2 U_STABLE UPluralRules* U_EXPORT2
uplrules_open(const char *locale, UErrorCode *status); uplrules_open(const char *locale, UErrorCode *status);
#ifndef U_HIDE_DRAFT_API
/** /**
* Opens a new UPluralRules object using the predefined plural rules for a * Opens a new UPluralRules object using the predefined plural rules for a
* given locale and the plural type. * given locale and the plural type.
* @param locale The locale for which the rules are desired. * @param locale The locale for which the rules are desired.
* @param type The plural type (e.g., cardinal or ordinal). * @param type The plural type (e.g., cardinal or ordinal).
* @param status A pointer to a UErrorCode to receive any errors. * @param status A pointer to a UErrorCode to receive any errors.
* @return A UPluralRules for the specified locale, or NULL if an error occ urred. * @return A UPluralRules for the specified locale, or NULL if an error occ urred.
* @draft ICU 50 * @stable ICU 50
*/ */
U_DRAFT UPluralRules* U_EXPORT2 U_DRAFT UPluralRules* U_EXPORT2
uplrules_openForType(const char *locale, UPluralType type, UErrorCode *stat us); uplrules_openForType(const char *locale, UPluralType type, UErrorCode *stat us);
#endif /* U_HIDE_DRAFT_API */
/** /**
* Closes a UPluralRules object. Once closed it may no longer be used. * Closes a UPluralRules object. Once closed it may no longer be used.
* @param uplrules The UPluralRules object to close. * @param uplrules The UPluralRules object to close.
* @stable ICU 4.8 * @stable ICU 4.8
*/ */
U_STABLE void U_EXPORT2 U_STABLE void U_EXPORT2
uplrules_close(UPluralRules *uplrules); uplrules_close(UPluralRules *uplrules);
#if U_SHOW_CPLUSPLUS_API #if U_SHOW_CPLUSPLUS_API
 End of changes. 10 change blocks. 
10 lines changed or deleted 6 lines changed or added


 uregex.h   uregex.h 
skipping to change at line 1422 skipping to change at line 1422
* maintained on the heap. This function sets the limit to the amount of m emory * maintained on the heap. This function sets the limit to the amount of m emory
* that can be used for this purpose. A backtracking stack overflow will * that can be used for this purpose. A backtracking stack overflow will
* result in an error from the match operation that caused it. * result in an error from the match operation that caused it.
* <p> * <p>
* A limit is desirable because a malicious or poorly designed pattern can use * A limit is desirable because a malicious or poorly designed pattern can use
* excessive memory, potentially crashing the process. A limit is enabled * excessive memory, potentially crashing the process. A limit is enabled
* by default. * by default.
* <p> * <p>
* @param regexp The compiled regular expression. * @param regexp The compiled regular expression.
* @param limit The maximum size, in bytes, of the matching backtra ck stack. * @param limit The maximum size, in bytes, of the matching backtra ck stack.
* A value of -1 means no limit. * A value of zero means no limit.
* The limit must be greater than zero, or -1. * The limit must be greater than or equal to zero.
* @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_setStackLimit(URegularExpression *regexp, uregex_setStackLimit(URegularExpression *regexp,
int32_t limit, int32_t limit,
UErrorCode *status); UErrorCode *status);
/** /**
 End of changes. 1 change blocks. 
2 lines changed or deleted 2 lines changed or added


 urename.h   urename.h 
skipping to change at line 256 skipping to change at line 256
#define u_fputc U_ICU_ENTRY_POINT_RENAME(u_fputc) #define u_fputc U_ICU_ENTRY_POINT_RENAME(u_fputc)
#define u_fputs U_ICU_ENTRY_POINT_RENAME(u_fputs) #define u_fputs U_ICU_ENTRY_POINT_RENAME(u_fputs)
#define u_frewind U_ICU_ENTRY_POINT_RENAME(u_frewind) #define u_frewind U_ICU_ENTRY_POINT_RENAME(u_frewind)
#define u_fscanf U_ICU_ENTRY_POINT_RENAME(u_fscanf) #define u_fscanf U_ICU_ENTRY_POINT_RENAME(u_fscanf)
#define u_fscanf_u U_ICU_ENTRY_POINT_RENAME(u_fscanf_u) #define u_fscanf_u U_ICU_ENTRY_POINT_RENAME(u_fscanf_u)
#define u_fsetcodepage U_ICU_ENTRY_POINT_RENAME(u_fsetcodepage) #define u_fsetcodepage U_ICU_ENTRY_POINT_RENAME(u_fsetcodepage)
#define u_fsetlocale U_ICU_ENTRY_POINT_RENAME(u_fsetlocale) #define u_fsetlocale U_ICU_ENTRY_POINT_RENAME(u_fsetlocale)
#define u_fsettransliterator U_ICU_ENTRY_POINT_RENAME(u_fsettransliterator) #define u_fsettransliterator U_ICU_ENTRY_POINT_RENAME(u_fsettransliterator)
#define u_fstropen U_ICU_ENTRY_POINT_RENAME(u_fstropen) #define u_fstropen U_ICU_ENTRY_POINT_RENAME(u_fstropen)
#define u_fungetc U_ICU_ENTRY_POINT_RENAME(u_fungetc) #define u_fungetc U_ICU_ENTRY_POINT_RENAME(u_fungetc)
#define u_getBidiPairedBracket U_ICU_ENTRY_POINT_RENAME(u_getBidiPairedBrac ket)
#define u_getCombiningClass U_ICU_ENTRY_POINT_RENAME(u_getCombiningClass) #define u_getCombiningClass U_ICU_ENTRY_POINT_RENAME(u_getCombiningClass)
#define u_getDataDirectory U_ICU_ENTRY_POINT_RENAME(u_getDataDirectory) #define u_getDataDirectory U_ICU_ENTRY_POINT_RENAME(u_getDataDirectory)
#define u_getDataVersion U_ICU_ENTRY_POINT_RENAME(u_getDataVersion) #define u_getDataVersion U_ICU_ENTRY_POINT_RENAME(u_getDataVersion)
#define u_getDefaultConverter U_ICU_ENTRY_POINT_RENAME(u_getDefaultConverte r) #define u_getDefaultConverter U_ICU_ENTRY_POINT_RENAME(u_getDefaultConverte r)
#define u_getFC_NFKC_Closure U_ICU_ENTRY_POINT_RENAME(u_getFC_NFKC_Closure) #define u_getFC_NFKC_Closure U_ICU_ENTRY_POINT_RENAME(u_getFC_NFKC_Closure)
#define u_getISOComment U_ICU_ENTRY_POINT_RENAME(u_getISOComment) #define u_getISOComment U_ICU_ENTRY_POINT_RENAME(u_getISOComment)
#define u_getIntPropertyMaxValue U_ICU_ENTRY_POINT_RENAME(u_getIntPropertyM axValue) #define u_getIntPropertyMaxValue U_ICU_ENTRY_POINT_RENAME(u_getIntPropertyM axValue)
#define u_getIntPropertyMinValue U_ICU_ENTRY_POINT_RENAME(u_getIntPropertyM inValue) #define u_getIntPropertyMinValue U_ICU_ENTRY_POINT_RENAME(u_getIntPropertyM inValue)
#define u_getIntPropertyValue U_ICU_ENTRY_POINT_RENAME(u_getIntPropertyValu e) #define u_getIntPropertyValue U_ICU_ENTRY_POINT_RENAME(u_getIntPropertyValu e)
#define u_getMainProperties U_ICU_ENTRY_POINT_RENAME(u_getMainProperties) #define u_getMainProperties U_ICU_ENTRY_POINT_RENAME(u_getMainProperties)
skipping to change at line 437 skipping to change at line 438
#define ubidi_getJoiningType U_ICU_ENTRY_POINT_RENAME(ubidi_getJoiningType) #define ubidi_getJoiningType U_ICU_ENTRY_POINT_RENAME(ubidi_getJoiningType)
#define ubidi_getLength U_ICU_ENTRY_POINT_RENAME(ubidi_getLength) #define ubidi_getLength U_ICU_ENTRY_POINT_RENAME(ubidi_getLength)
#define ubidi_getLevelAt U_ICU_ENTRY_POINT_RENAME(ubidi_getLevelAt) #define ubidi_getLevelAt U_ICU_ENTRY_POINT_RENAME(ubidi_getLevelAt)
#define ubidi_getLevels U_ICU_ENTRY_POINT_RENAME(ubidi_getLevels) #define ubidi_getLevels U_ICU_ENTRY_POINT_RENAME(ubidi_getLevels)
#define ubidi_getLogicalIndex U_ICU_ENTRY_POINT_RENAME(ubidi_getLogicalInde x) #define ubidi_getLogicalIndex U_ICU_ENTRY_POINT_RENAME(ubidi_getLogicalInde x)
#define ubidi_getLogicalMap U_ICU_ENTRY_POINT_RENAME(ubidi_getLogicalMap) #define ubidi_getLogicalMap U_ICU_ENTRY_POINT_RENAME(ubidi_getLogicalMap)
#define ubidi_getLogicalRun U_ICU_ENTRY_POINT_RENAME(ubidi_getLogicalRun) #define ubidi_getLogicalRun U_ICU_ENTRY_POINT_RENAME(ubidi_getLogicalRun)
#define ubidi_getMaxValue U_ICU_ENTRY_POINT_RENAME(ubidi_getMaxValue) #define ubidi_getMaxValue U_ICU_ENTRY_POINT_RENAME(ubidi_getMaxValue)
#define ubidi_getMemory U_ICU_ENTRY_POINT_RENAME(ubidi_getMemory) #define ubidi_getMemory U_ICU_ENTRY_POINT_RENAME(ubidi_getMemory)
#define ubidi_getMirror U_ICU_ENTRY_POINT_RENAME(ubidi_getMirror) #define ubidi_getMirror U_ICU_ENTRY_POINT_RENAME(ubidi_getMirror)
#define ubidi_getPairedBracket U_ICU_ENTRY_POINT_RENAME(ubidi_getPairedBrac
ket)
#define ubidi_getPairedBracketType U_ICU_ENTRY_POINT_RENAME(ubidi_getPaired
BracketType)
#define ubidi_getParaLevel U_ICU_ENTRY_POINT_RENAME(ubidi_getParaLevel) #define ubidi_getParaLevel U_ICU_ENTRY_POINT_RENAME(ubidi_getParaLevel)
#define ubidi_getParaLevelAtIndex U_ICU_ENTRY_POINT_RENAME(ubidi_getParaLev elAtIndex)
#define ubidi_getParagraph U_ICU_ENTRY_POINT_RENAME(ubidi_getParagraph) #define ubidi_getParagraph U_ICU_ENTRY_POINT_RENAME(ubidi_getParagraph)
#define ubidi_getParagraphByIndex U_ICU_ENTRY_POINT_RENAME(ubidi_getParagra phByIndex) #define ubidi_getParagraphByIndex U_ICU_ENTRY_POINT_RENAME(ubidi_getParagra phByIndex)
#define ubidi_getProcessedLength U_ICU_ENTRY_POINT_RENAME(ubidi_getProcesse dLength) #define ubidi_getProcessedLength U_ICU_ENTRY_POINT_RENAME(ubidi_getProcesse dLength)
#define ubidi_getReorderingMode U_ICU_ENTRY_POINT_RENAME(ubidi_getReorderin gMode) #define ubidi_getReorderingMode U_ICU_ENTRY_POINT_RENAME(ubidi_getReorderin gMode)
#define ubidi_getReorderingOptions U_ICU_ENTRY_POINT_RENAME(ubidi_getReorde ringOptions) #define ubidi_getReorderingOptions U_ICU_ENTRY_POINT_RENAME(ubidi_getReorde ringOptions)
#define ubidi_getResultLength U_ICU_ENTRY_POINT_RENAME(ubidi_getResultLengt h) #define ubidi_getResultLength U_ICU_ENTRY_POINT_RENAME(ubidi_getResultLengt h)
#define ubidi_getRuns U_ICU_ENTRY_POINT_RENAME(ubidi_getRuns) #define ubidi_getRuns U_ICU_ENTRY_POINT_RENAME(ubidi_getRuns)
#define ubidi_getSingleton U_ICU_ENTRY_POINT_RENAME(ubidi_getSingleton) #define ubidi_getSingleton U_ICU_ENTRY_POINT_RENAME(ubidi_getSingleton)
#define ubidi_getText U_ICU_ENTRY_POINT_RENAME(ubidi_getText) #define ubidi_getText U_ICU_ENTRY_POINT_RENAME(ubidi_getText)
#define ubidi_getVisualIndex U_ICU_ENTRY_POINT_RENAME(ubidi_getVisualIndex) #define ubidi_getVisualIndex U_ICU_ENTRY_POINT_RENAME(ubidi_getVisualIndex)
skipping to change at line 516 skipping to change at line 520
#define ucal_getFieldDifference U_ICU_ENTRY_POINT_RENAME(ucal_getFieldDiffe rence) #define ucal_getFieldDifference U_ICU_ENTRY_POINT_RENAME(ucal_getFieldDiffe rence)
#define ucal_getGregorianChange U_ICU_ENTRY_POINT_RENAME(ucal_getGregorianC hange) #define ucal_getGregorianChange U_ICU_ENTRY_POINT_RENAME(ucal_getGregorianC hange)
#define ucal_getKeywordValuesForLocale U_ICU_ENTRY_POINT_RENAME(ucal_getKey wordValuesForLocale) #define ucal_getKeywordValuesForLocale U_ICU_ENTRY_POINT_RENAME(ucal_getKey wordValuesForLocale)
#define ucal_getLimit U_ICU_ENTRY_POINT_RENAME(ucal_getLimit) #define ucal_getLimit U_ICU_ENTRY_POINT_RENAME(ucal_getLimit)
#define ucal_getLocaleByType U_ICU_ENTRY_POINT_RENAME(ucal_getLocaleByType) #define ucal_getLocaleByType U_ICU_ENTRY_POINT_RENAME(ucal_getLocaleByType)
#define ucal_getMillis U_ICU_ENTRY_POINT_RENAME(ucal_getMillis) #define ucal_getMillis U_ICU_ENTRY_POINT_RENAME(ucal_getMillis)
#define ucal_getNow U_ICU_ENTRY_POINT_RENAME(ucal_getNow) #define ucal_getNow U_ICU_ENTRY_POINT_RENAME(ucal_getNow)
#define ucal_getTZDataVersion U_ICU_ENTRY_POINT_RENAME(ucal_getTZDataVersio n) #define ucal_getTZDataVersion U_ICU_ENTRY_POINT_RENAME(ucal_getTZDataVersio n)
#define ucal_getTimeZoneDisplayName U_ICU_ENTRY_POINT_RENAME(ucal_getTimeZo neDisplayName) #define ucal_getTimeZoneDisplayName U_ICU_ENTRY_POINT_RENAME(ucal_getTimeZo neDisplayName)
#define ucal_getTimeZoneID U_ICU_ENTRY_POINT_RENAME(ucal_getTimeZoneID) #define ucal_getTimeZoneID U_ICU_ENTRY_POINT_RENAME(ucal_getTimeZoneID)
#define ucal_getTimeZoneIDForWindowsID U_ICU_ENTRY_POINT_RENAME(ucal_getTim eZoneIDForWindowsID)
#define ucal_getTimeZoneTransitionDate U_ICU_ENTRY_POINT_RENAME(ucal_getTim eZoneTransitionDate) #define ucal_getTimeZoneTransitionDate U_ICU_ENTRY_POINT_RENAME(ucal_getTim eZoneTransitionDate)
#define ucal_getType U_ICU_ENTRY_POINT_RENAME(ucal_getType) #define ucal_getType U_ICU_ENTRY_POINT_RENAME(ucal_getType)
#define ucal_getWeekendTransition U_ICU_ENTRY_POINT_RENAME(ucal_getWeekendT ransition) #define ucal_getWeekendTransition U_ICU_ENTRY_POINT_RENAME(ucal_getWeekendT ransition)
#define ucal_getWindowsTimeZoneID U_ICU_ENTRY_POINT_RENAME(ucal_getWindowsT imeZoneID)
#define ucal_inDaylightTime U_ICU_ENTRY_POINT_RENAME(ucal_inDaylightTime) #define ucal_inDaylightTime U_ICU_ENTRY_POINT_RENAME(ucal_inDaylightTime)
#define ucal_isSet U_ICU_ENTRY_POINT_RENAME(ucal_isSet) #define ucal_isSet U_ICU_ENTRY_POINT_RENAME(ucal_isSet)
#define ucal_isWeekend U_ICU_ENTRY_POINT_RENAME(ucal_isWeekend) #define ucal_isWeekend U_ICU_ENTRY_POINT_RENAME(ucal_isWeekend)
#define ucal_open U_ICU_ENTRY_POINT_RENAME(ucal_open) #define ucal_open U_ICU_ENTRY_POINT_RENAME(ucal_open)
#define ucal_openCountryTimeZones U_ICU_ENTRY_POINT_RENAME(ucal_openCountry TimeZones) #define ucal_openCountryTimeZones U_ICU_ENTRY_POINT_RENAME(ucal_openCountry TimeZones)
#define ucal_openTimeZoneIDEnumeration U_ICU_ENTRY_POINT_RENAME(ucal_openTi meZoneIDEnumeration) #define ucal_openTimeZoneIDEnumeration U_ICU_ENTRY_POINT_RENAME(ucal_openTi meZoneIDEnumeration)
#define ucal_openTimeZones U_ICU_ENTRY_POINT_RENAME(ucal_openTimeZones) #define ucal_openTimeZones U_ICU_ENTRY_POINT_RENAME(ucal_openTimeZones)
#define ucal_roll U_ICU_ENTRY_POINT_RENAME(ucal_roll) #define ucal_roll U_ICU_ENTRY_POINT_RENAME(ucal_roll)
#define ucal_set U_ICU_ENTRY_POINT_RENAME(ucal_set) #define ucal_set U_ICU_ENTRY_POINT_RENAME(ucal_set)
#define ucal_setAttribute U_ICU_ENTRY_POINT_RENAME(ucal_setAttribute) #define ucal_setAttribute U_ICU_ENTRY_POINT_RENAME(ucal_setAttribute)
skipping to change at line 575 skipping to change at line 581
#define ucasemap_utf8ToLower U_ICU_ENTRY_POINT_RENAME(ucasemap_utf8ToLower) #define ucasemap_utf8ToLower U_ICU_ENTRY_POINT_RENAME(ucasemap_utf8ToLower)
#define ucasemap_utf8ToTitle U_ICU_ENTRY_POINT_RENAME(ucasemap_utf8ToTitle) #define ucasemap_utf8ToTitle U_ICU_ENTRY_POINT_RENAME(ucasemap_utf8ToTitle)
#define ucasemap_utf8ToUpper U_ICU_ENTRY_POINT_RENAME(ucasemap_utf8ToUpper) #define ucasemap_utf8ToUpper U_ICU_ENTRY_POINT_RENAME(ucasemap_utf8ToUpper)
#define uchar_addPropertyStarts U_ICU_ENTRY_POINT_RENAME(uchar_addPropertyS tarts) #define uchar_addPropertyStarts U_ICU_ENTRY_POINT_RENAME(uchar_addPropertyS tarts)
#define uchar_swapNames U_ICU_ENTRY_POINT_RENAME(uchar_swapNames) #define uchar_swapNames U_ICU_ENTRY_POINT_RENAME(uchar_swapNames)
#define ucln_cleanupOne U_ICU_ENTRY_POINT_RENAME(ucln_cleanupOne) #define ucln_cleanupOne U_ICU_ENTRY_POINT_RENAME(ucln_cleanupOne)
#define ucln_common_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_common_re gisterCleanup) #define ucln_common_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_common_re gisterCleanup)
#define ucln_i18n_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_i18n_regist erCleanup) #define ucln_i18n_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_i18n_regist erCleanup)
#define ucln_io_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_io_registerCl eanup) #define ucln_io_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_io_registerCl eanup)
#define ucln_lib_cleanup U_ICU_ENTRY_POINT_RENAME(ucln_lib_cleanup) #define ucln_lib_cleanup U_ICU_ENTRY_POINT_RENAME(ucln_lib_cleanup)
#define ucln_mutexedInit U_ICU_ENTRY_POINT_RENAME(ucln_mutexedInit)
#define ucln_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_registerCleanup) #define ucln_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_registerCleanup)
#define ucnv_MBCSFromUChar32 U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSFromUChar32) #define ucnv_MBCSFromUChar32 U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSFromUChar32)
#define ucnv_MBCSFromUnicodeWithOffsets U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSF romUnicodeWithOffsets) #define ucnv_MBCSFromUnicodeWithOffsets U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSF romUnicodeWithOffsets)
#define ucnv_MBCSGetFilteredUnicodeSetForUnicode U_ICU_ENTRY_POINT_RENAME(u cnv_MBCSGetFilteredUnicodeSetForUnicode) #define ucnv_MBCSGetFilteredUnicodeSetForUnicode U_ICU_ENTRY_POINT_RENAME(u cnv_MBCSGetFilteredUnicodeSetForUnicode)
#define ucnv_MBCSGetType U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSGetType) #define ucnv_MBCSGetType U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSGetType)
#define ucnv_MBCSGetUnicodeSetForUnicode U_ICU_ENTRY_POINT_RENAME(ucnv_MBCS GetUnicodeSetForUnicode) #define ucnv_MBCSGetUnicodeSetForUnicode U_ICU_ENTRY_POINT_RENAME(ucnv_MBCS GetUnicodeSetForUnicode)
#define ucnv_MBCSIsLeadByte U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSIsLeadByte) #define ucnv_MBCSIsLeadByte U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSIsLeadByte)
#define ucnv_MBCSSimpleGetNextUChar U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSSimpl eGetNextUChar) #define ucnv_MBCSSimpleGetNextUChar U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSSimpl eGetNextUChar)
#define ucnv_MBCSToUnicodeWithOffsets U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSToU nicodeWithOffsets) #define ucnv_MBCSToUnicodeWithOffsets U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSToU nicodeWithOffsets)
#define ucnv_bld_countAvailableConverters U_ICU_ENTRY_POINT_RENAME(ucnv_bld _countAvailableConverters) #define ucnv_bld_countAvailableConverters U_ICU_ENTRY_POINT_RENAME(ucnv_bld _countAvailableConverters)
skipping to change at line 693 skipping to change at line 698
#define ucnvsel_openFromSerialized U_ICU_ENTRY_POINT_RENAME(ucnvsel_openFro mSerialized) #define ucnvsel_openFromSerialized U_ICU_ENTRY_POINT_RENAME(ucnvsel_openFro mSerialized)
#define ucnvsel_selectForString U_ICU_ENTRY_POINT_RENAME(ucnvsel_selectForS tring) #define ucnvsel_selectForString U_ICU_ENTRY_POINT_RENAME(ucnvsel_selectForS tring)
#define ucnvsel_selectForUTF8 U_ICU_ENTRY_POINT_RENAME(ucnvsel_selectForUTF 8) #define ucnvsel_selectForUTF8 U_ICU_ENTRY_POINT_RENAME(ucnvsel_selectForUTF 8)
#define ucnvsel_serialize U_ICU_ENTRY_POINT_RENAME(ucnvsel_serialize) #define ucnvsel_serialize U_ICU_ENTRY_POINT_RENAME(ucnvsel_serialize)
#define ucol_allocWeights U_ICU_ENTRY_POINT_RENAME(ucol_allocWeights) #define ucol_allocWeights U_ICU_ENTRY_POINT_RENAME(ucol_allocWeights)
#define ucol_assembleTailoringTable U_ICU_ENTRY_POINT_RENAME(ucol_assembleT ailoringTable) #define ucol_assembleTailoringTable U_ICU_ENTRY_POINT_RENAME(ucol_assembleT ailoringTable)
#define ucol_buildPermutationTable U_ICU_ENTRY_POINT_RENAME(ucol_buildPermu tationTable) #define ucol_buildPermutationTable U_ICU_ENTRY_POINT_RENAME(ucol_buildPermu tationTable)
#define ucol_calcSortKey U_ICU_ENTRY_POINT_RENAME(ucol_calcSortKey) #define ucol_calcSortKey U_ICU_ENTRY_POINT_RENAME(ucol_calcSortKey)
#define ucol_calcSortKeySimpleTertiary U_ICU_ENTRY_POINT_RENAME(ucol_calcSo rtKeySimpleTertiary) #define ucol_calcSortKeySimpleTertiary U_ICU_ENTRY_POINT_RENAME(ucol_calcSo rtKeySimpleTertiary)
#define ucol_cloneBinary U_ICU_ENTRY_POINT_RENAME(ucol_cloneBinary) #define ucol_cloneBinary U_ICU_ENTRY_POINT_RENAME(ucol_cloneBinary)
#define ucol_cloneRuleData U_ICU_ENTRY_POINT_RENAME(ucol_cloneRuleData)
#define ucol_close U_ICU_ENTRY_POINT_RENAME(ucol_close) #define ucol_close U_ICU_ENTRY_POINT_RENAME(ucol_close)
#define ucol_closeElements U_ICU_ENTRY_POINT_RENAME(ucol_closeElements) #define ucol_closeElements U_ICU_ENTRY_POINT_RENAME(ucol_closeElements)
#define ucol_countAvailable U_ICU_ENTRY_POINT_RENAME(ucol_countAvailable) #define ucol_countAvailable U_ICU_ENTRY_POINT_RENAME(ucol_countAvailable)
#define ucol_createElements U_ICU_ENTRY_POINT_RENAME(ucol_createElements) #define ucol_createElements U_ICU_ENTRY_POINT_RENAME(ucol_createElements)
#define ucol_doCE U_ICU_ENTRY_POINT_RENAME(ucol_doCE) #define ucol_doCE U_ICU_ENTRY_POINT_RENAME(ucol_doCE)
#define ucol_equal U_ICU_ENTRY_POINT_RENAME(ucol_equal) #define ucol_equal U_ICU_ENTRY_POINT_RENAME(ucol_equal)
#define ucol_equals U_ICU_ENTRY_POINT_RENAME(ucol_equals) #define ucol_equals U_ICU_ENTRY_POINT_RENAME(ucol_equals)
#define ucol_findReorderingEntry U_ICU_ENTRY_POINT_RENAME(ucol_findReorderi ngEntry) #define ucol_findReorderingEntry U_ICU_ENTRY_POINT_RENAME(ucol_findReorderi ngEntry)
#define ucol_forceHanImplicit U_ICU_ENTRY_POINT_RENAME(ucol_forceHanImplici t) #define ucol_forceHanImplicit U_ICU_ENTRY_POINT_RENAME(ucol_forceHanImplici t)
#define ucol_forgetUCA U_ICU_ENTRY_POINT_RENAME(ucol_forgetUCA) #define ucol_forgetUCA U_ICU_ENTRY_POINT_RENAME(ucol_forgetUCA)
skipping to change at line 802 skipping to change at line 806
#define ucol_tok_getRulesFromBundle U_ICU_ENTRY_POINT_RENAME(ucol_tok_getRu lesFromBundle) #define ucol_tok_getRulesFromBundle U_ICU_ENTRY_POINT_RENAME(ucol_tok_getRu lesFromBundle)
#define ucol_tok_initTokenList U_ICU_ENTRY_POINT_RENAME(ucol_tok_initTokenL ist) #define ucol_tok_initTokenList U_ICU_ENTRY_POINT_RENAME(ucol_tok_initTokenL ist)
#define ucol_tok_parseNextToken U_ICU_ENTRY_POINT_RENAME(ucol_tok_parseNext Token) #define ucol_tok_parseNextToken U_ICU_ENTRY_POINT_RENAME(ucol_tok_parseNext Token)
#define ucol_updateInternalState U_ICU_ENTRY_POINT_RENAME(ucol_updateIntern alState) #define ucol_updateInternalState U_ICU_ENTRY_POINT_RENAME(ucol_updateIntern alState)
#define ucsdet_close U_ICU_ENTRY_POINT_RENAME(ucsdet_close) #define ucsdet_close U_ICU_ENTRY_POINT_RENAME(ucsdet_close)
#define ucsdet_detect U_ICU_ENTRY_POINT_RENAME(ucsdet_detect) #define ucsdet_detect U_ICU_ENTRY_POINT_RENAME(ucsdet_detect)
#define ucsdet_detectAll U_ICU_ENTRY_POINT_RENAME(ucsdet_detectAll) #define ucsdet_detectAll U_ICU_ENTRY_POINT_RENAME(ucsdet_detectAll)
#define ucsdet_enableInputFilter U_ICU_ENTRY_POINT_RENAME(ucsdet_enableInpu tFilter) #define ucsdet_enableInputFilter U_ICU_ENTRY_POINT_RENAME(ucsdet_enableInpu tFilter)
#define ucsdet_getAllDetectableCharsets U_ICU_ENTRY_POINT_RENAME(ucsdet_get AllDetectableCharsets) #define ucsdet_getAllDetectableCharsets U_ICU_ENTRY_POINT_RENAME(ucsdet_get AllDetectableCharsets)
#define ucsdet_getConfidence U_ICU_ENTRY_POINT_RENAME(ucsdet_getConfidence) #define ucsdet_getConfidence U_ICU_ENTRY_POINT_RENAME(ucsdet_getConfidence)
#define ucsdet_getDetectableCharsets U_ICU_ENTRY_POINT_RENAME(ucsdet_getDet ectableCharsets)
#define ucsdet_getLanguage U_ICU_ENTRY_POINT_RENAME(ucsdet_getLanguage) #define ucsdet_getLanguage U_ICU_ENTRY_POINT_RENAME(ucsdet_getLanguage)
#define ucsdet_getName U_ICU_ENTRY_POINT_RENAME(ucsdet_getName) #define ucsdet_getName U_ICU_ENTRY_POINT_RENAME(ucsdet_getName)
#define ucsdet_getUChars U_ICU_ENTRY_POINT_RENAME(ucsdet_getUChars) #define ucsdet_getUChars U_ICU_ENTRY_POINT_RENAME(ucsdet_getUChars)
#define ucsdet_isInputFilterEnabled U_ICU_ENTRY_POINT_RENAME(ucsdet_isInput FilterEnabled) #define ucsdet_isInputFilterEnabled U_ICU_ENTRY_POINT_RENAME(ucsdet_isInput FilterEnabled)
#define ucsdet_open U_ICU_ENTRY_POINT_RENAME(ucsdet_open) #define ucsdet_open U_ICU_ENTRY_POINT_RENAME(ucsdet_open)
#define ucsdet_setDeclaredEncoding U_ICU_ENTRY_POINT_RENAME(ucsdet_setDecla redEncoding) #define ucsdet_setDeclaredEncoding U_ICU_ENTRY_POINT_RENAME(ucsdet_setDecla redEncoding)
#define ucsdet_setDetectableCharset U_ICU_ENTRY_POINT_RENAME(ucsdet_setDete ctableCharset)
#define ucsdet_setText U_ICU_ENTRY_POINT_RENAME(ucsdet_setText) #define ucsdet_setText U_ICU_ENTRY_POINT_RENAME(ucsdet_setText)
#define ucurr_countCurrencies U_ICU_ENTRY_POINT_RENAME(ucurr_countCurrencie s) #define ucurr_countCurrencies U_ICU_ENTRY_POINT_RENAME(ucurr_countCurrencie s)
#define ucurr_forLocale U_ICU_ENTRY_POINT_RENAME(ucurr_forLocale) #define ucurr_forLocale U_ICU_ENTRY_POINT_RENAME(ucurr_forLocale)
#define ucurr_forLocaleAndDate U_ICU_ENTRY_POINT_RENAME(ucurr_forLocaleAndD ate) #define ucurr_forLocaleAndDate U_ICU_ENTRY_POINT_RENAME(ucurr_forLocaleAndD ate)
#define ucurr_getDefaultFractionDigits U_ICU_ENTRY_POINT_RENAME(ucurr_getDe faultFractionDigits) #define ucurr_getDefaultFractionDigits U_ICU_ENTRY_POINT_RENAME(ucurr_getDe faultFractionDigits)
#define ucurr_getKeywordValuesForLocale U_ICU_ENTRY_POINT_RENAME(ucurr_getK eywordValuesForLocale) #define ucurr_getKeywordValuesForLocale U_ICU_ENTRY_POINT_RENAME(ucurr_getK eywordValuesForLocale)
#define ucurr_getName U_ICU_ENTRY_POINT_RENAME(ucurr_getName) #define ucurr_getName U_ICU_ENTRY_POINT_RENAME(ucurr_getName)
#define ucurr_getNumericCode U_ICU_ENTRY_POINT_RENAME(ucurr_getNumericCode) #define ucurr_getNumericCode U_ICU_ENTRY_POINT_RENAME(ucurr_getNumericCode)
#define ucurr_getPluralName U_ICU_ENTRY_POINT_RENAME(ucurr_getPluralName) #define ucurr_getPluralName U_ICU_ENTRY_POINT_RENAME(ucurr_getPluralName)
#define ucurr_getRoundingIncrement U_ICU_ENTRY_POINT_RENAME(ucurr_getRoundi ngIncrement) #define ucurr_getRoundingIncrement U_ICU_ENTRY_POINT_RENAME(ucurr_getRoundi ngIncrement)
skipping to change at line 916 skipping to change at line 922
#define uenum_reset U_ICU_ENTRY_POINT_RENAME(uenum_reset) #define uenum_reset U_ICU_ENTRY_POINT_RENAME(uenum_reset)
#define uenum_unext U_ICU_ENTRY_POINT_RENAME(uenum_unext) #define uenum_unext U_ICU_ENTRY_POINT_RENAME(uenum_unext)
#define uenum_unextDefault U_ICU_ENTRY_POINT_RENAME(uenum_unextDefault) #define uenum_unextDefault U_ICU_ENTRY_POINT_RENAME(uenum_unextDefault)
#define ufile_close_translit U_ICU_ENTRY_POINT_RENAME(ufile_close_translit) #define ufile_close_translit U_ICU_ENTRY_POINT_RENAME(ufile_close_translit)
#define ufile_fill_uchar_buffer U_ICU_ENTRY_POINT_RENAME(ufile_fill_uchar_b uffer) #define ufile_fill_uchar_buffer U_ICU_ENTRY_POINT_RENAME(ufile_fill_uchar_b uffer)
#define ufile_flush_io U_ICU_ENTRY_POINT_RENAME(ufile_flush_io) #define ufile_flush_io U_ICU_ENTRY_POINT_RENAME(ufile_flush_io)
#define ufile_flush_translit U_ICU_ENTRY_POINT_RENAME(ufile_flush_translit) #define ufile_flush_translit U_ICU_ENTRY_POINT_RENAME(ufile_flush_translit)
#define ufile_getch U_ICU_ENTRY_POINT_RENAME(ufile_getch) #define ufile_getch U_ICU_ENTRY_POINT_RENAME(ufile_getch)
#define ufile_getch32 U_ICU_ENTRY_POINT_RENAME(ufile_getch32) #define ufile_getch32 U_ICU_ENTRY_POINT_RENAME(ufile_getch32)
#define ufmt_64tou U_ICU_ENTRY_POINT_RENAME(ufmt_64tou) #define ufmt_64tou U_ICU_ENTRY_POINT_RENAME(ufmt_64tou)
#define ufmt_close U_ICU_ENTRY_POINT_RENAME(ufmt_close)
#define ufmt_defaultCPToUnicode U_ICU_ENTRY_POINT_RENAME(ufmt_defaultCPToUn icode) #define ufmt_defaultCPToUnicode U_ICU_ENTRY_POINT_RENAME(ufmt_defaultCPToUn icode)
#define ufmt_digitvalue U_ICU_ENTRY_POINT_RENAME(ufmt_digitvalue) #define ufmt_digitvalue U_ICU_ENTRY_POINT_RENAME(ufmt_digitvalue)
#define ufmt_getArrayItemByIndex U_ICU_ENTRY_POINT_RENAME(ufmt_getArrayItem
ByIndex)
#define ufmt_getArrayLength U_ICU_ENTRY_POINT_RENAME(ufmt_getArrayLength)
#define ufmt_getDate U_ICU_ENTRY_POINT_RENAME(ufmt_getDate)
#define ufmt_getDecNumChars U_ICU_ENTRY_POINT_RENAME(ufmt_getDecNumChars)
#define ufmt_getDouble U_ICU_ENTRY_POINT_RENAME(ufmt_getDouble)
#define ufmt_getInt64 U_ICU_ENTRY_POINT_RENAME(ufmt_getInt64)
#define ufmt_getLong U_ICU_ENTRY_POINT_RENAME(ufmt_getLong)
#define ufmt_getObject U_ICU_ENTRY_POINT_RENAME(ufmt_getObject)
#define ufmt_getType U_ICU_ENTRY_POINT_RENAME(ufmt_getType)
#define ufmt_getUChars U_ICU_ENTRY_POINT_RENAME(ufmt_getUChars)
#define ufmt_isNumeric U_ICU_ENTRY_POINT_RENAME(ufmt_isNumeric)
#define ufmt_isdigit U_ICU_ENTRY_POINT_RENAME(ufmt_isdigit) #define ufmt_isdigit U_ICU_ENTRY_POINT_RENAME(ufmt_isdigit)
#define ufmt_open U_ICU_ENTRY_POINT_RENAME(ufmt_open)
#define ufmt_ptou U_ICU_ENTRY_POINT_RENAME(ufmt_ptou) #define ufmt_ptou U_ICU_ENTRY_POINT_RENAME(ufmt_ptou)
#define ufmt_uto64 U_ICU_ENTRY_POINT_RENAME(ufmt_uto64) #define ufmt_uto64 U_ICU_ENTRY_POINT_RENAME(ufmt_uto64)
#define ufmt_utop U_ICU_ENTRY_POINT_RENAME(ufmt_utop) #define ufmt_utop U_ICU_ENTRY_POINT_RENAME(ufmt_utop)
#define ugender_getInstance U_ICU_ENTRY_POINT_RENAME(ugender_getInstance) #define ugender_getInstance U_ICU_ENTRY_POINT_RENAME(ugender_getInstance)
#define ugender_getListGender U_ICU_ENTRY_POINT_RENAME(ugender_getListGende r) #define ugender_getListGender U_ICU_ENTRY_POINT_RENAME(ugender_getListGende r)
#define uhash_close U_ICU_ENTRY_POINT_RENAME(uhash_close) #define uhash_close U_ICU_ENTRY_POINT_RENAME(uhash_close)
#define uhash_compareCaselessUnicodeString U_ICU_ENTRY_POINT_RENAME(uhash_c ompareCaselessUnicodeString) #define uhash_compareCaselessUnicodeString U_ICU_ENTRY_POINT_RENAME(uhash_c ompareCaselessUnicodeString)
#define uhash_compareChars U_ICU_ENTRY_POINT_RENAME(uhash_compareChars) #define uhash_compareChars U_ICU_ENTRY_POINT_RENAME(uhash_compareChars)
#define uhash_compareIChars U_ICU_ENTRY_POINT_RENAME(uhash_compareIChars) #define uhash_compareIChars U_ICU_ENTRY_POINT_RENAME(uhash_compareIChars)
#define uhash_compareLong U_ICU_ENTRY_POINT_RENAME(uhash_compareLong) #define uhash_compareLong U_ICU_ENTRY_POINT_RENAME(uhash_compareLong)
skipping to change at line 1088 skipping to change at line 1107
#define umsg_clone U_ICU_ENTRY_POINT_RENAME(umsg_clone) #define umsg_clone U_ICU_ENTRY_POINT_RENAME(umsg_clone)
#define umsg_close U_ICU_ENTRY_POINT_RENAME(umsg_close) #define umsg_close U_ICU_ENTRY_POINT_RENAME(umsg_close)
#define umsg_format U_ICU_ENTRY_POINT_RENAME(umsg_format) #define umsg_format U_ICU_ENTRY_POINT_RENAME(umsg_format)
#define umsg_getLocale U_ICU_ENTRY_POINT_RENAME(umsg_getLocale) #define umsg_getLocale U_ICU_ENTRY_POINT_RENAME(umsg_getLocale)
#define umsg_open U_ICU_ENTRY_POINT_RENAME(umsg_open) #define umsg_open U_ICU_ENTRY_POINT_RENAME(umsg_open)
#define umsg_parse U_ICU_ENTRY_POINT_RENAME(umsg_parse) #define umsg_parse U_ICU_ENTRY_POINT_RENAME(umsg_parse)
#define umsg_setLocale U_ICU_ENTRY_POINT_RENAME(umsg_setLocale) #define umsg_setLocale U_ICU_ENTRY_POINT_RENAME(umsg_setLocale)
#define umsg_toPattern U_ICU_ENTRY_POINT_RENAME(umsg_toPattern) #define umsg_toPattern U_ICU_ENTRY_POINT_RENAME(umsg_toPattern)
#define umsg_vformat U_ICU_ENTRY_POINT_RENAME(umsg_vformat) #define umsg_vformat U_ICU_ENTRY_POINT_RENAME(umsg_vformat)
#define umsg_vparse U_ICU_ENTRY_POINT_RENAME(umsg_vparse) #define umsg_vparse U_ICU_ENTRY_POINT_RENAME(umsg_vparse)
#define umtx_atomic_dec U_ICU_ENTRY_POINT_RENAME(umtx_atomic_dec)
#define umtx_atomic_inc U_ICU_ENTRY_POINT_RENAME(umtx_atomic_inc)
#define umtx_cleanup U_ICU_ENTRY_POINT_RENAME(umtx_cleanup)
#define umtx_lock U_ICU_ENTRY_POINT_RENAME(umtx_lock) #define umtx_lock U_ICU_ENTRY_POINT_RENAME(umtx_lock)
#define umtx_unlock U_ICU_ENTRY_POINT_RENAME(umtx_unlock) #define umtx_unlock U_ICU_ENTRY_POINT_RENAME(umtx_unlock)
#define uniset_getUnicode32Instance U_ICU_ENTRY_POINT_RENAME(uniset_getUnic ode32Instance) #define uniset_getUnicode32Instance U_ICU_ENTRY_POINT_RENAME(uniset_getUnic ode32Instance)
#define unorm2_append U_ICU_ENTRY_POINT_RENAME(unorm2_append) #define unorm2_append U_ICU_ENTRY_POINT_RENAME(unorm2_append)
#define unorm2_close U_ICU_ENTRY_POINT_RENAME(unorm2_close) #define unorm2_close U_ICU_ENTRY_POINT_RENAME(unorm2_close)
#define unorm2_composePair U_ICU_ENTRY_POINT_RENAME(unorm2_composePair) #define unorm2_composePair U_ICU_ENTRY_POINT_RENAME(unorm2_composePair)
#define unorm2_getCombiningClass U_ICU_ENTRY_POINT_RENAME(unorm2_getCombini ngClass) #define unorm2_getCombiningClass U_ICU_ENTRY_POINT_RENAME(unorm2_getCombini ngClass)
#define unorm2_getDecomposition U_ICU_ENTRY_POINT_RENAME(unorm2_getDecompos ition) #define unorm2_getDecomposition U_ICU_ENTRY_POINT_RENAME(unorm2_getDecompos ition)
#define unorm2_getInstance U_ICU_ENTRY_POINT_RENAME(unorm2_getInstance) #define unorm2_getInstance U_ICU_ENTRY_POINT_RENAME(unorm2_getInstance)
#define unorm2_getNFCInstance U_ICU_ENTRY_POINT_RENAME(unorm2_getNFCInstanc e) #define unorm2_getNFCInstance U_ICU_ENTRY_POINT_RENAME(unorm2_getNFCInstanc e)
skipping to change at line 1139 skipping to change at line 1155
#define unorm_setIter U_ICU_ENTRY_POINT_RENAME(unorm_setIter) #define unorm_setIter U_ICU_ENTRY_POINT_RENAME(unorm_setIter)
#define unum_applyPattern U_ICU_ENTRY_POINT_RENAME(unum_applyPattern) #define unum_applyPattern U_ICU_ENTRY_POINT_RENAME(unum_applyPattern)
#define unum_clone U_ICU_ENTRY_POINT_RENAME(unum_clone) #define unum_clone U_ICU_ENTRY_POINT_RENAME(unum_clone)
#define unum_close U_ICU_ENTRY_POINT_RENAME(unum_close) #define unum_close U_ICU_ENTRY_POINT_RENAME(unum_close)
#define unum_countAvailable U_ICU_ENTRY_POINT_RENAME(unum_countAvailable) #define unum_countAvailable U_ICU_ENTRY_POINT_RENAME(unum_countAvailable)
#define unum_format U_ICU_ENTRY_POINT_RENAME(unum_format) #define unum_format U_ICU_ENTRY_POINT_RENAME(unum_format)
#define unum_formatDecimal U_ICU_ENTRY_POINT_RENAME(unum_formatDecimal) #define unum_formatDecimal U_ICU_ENTRY_POINT_RENAME(unum_formatDecimal)
#define unum_formatDouble U_ICU_ENTRY_POINT_RENAME(unum_formatDouble) #define unum_formatDouble U_ICU_ENTRY_POINT_RENAME(unum_formatDouble)
#define unum_formatDoubleCurrency U_ICU_ENTRY_POINT_RENAME(unum_formatDoubl eCurrency) #define unum_formatDoubleCurrency U_ICU_ENTRY_POINT_RENAME(unum_formatDoubl eCurrency)
#define unum_formatInt64 U_ICU_ENTRY_POINT_RENAME(unum_formatInt64) #define unum_formatInt64 U_ICU_ENTRY_POINT_RENAME(unum_formatInt64)
#define unum_formatUFormattable U_ICU_ENTRY_POINT_RENAME(unum_formatUFormat table)
#define unum_getAttribute U_ICU_ENTRY_POINT_RENAME(unum_getAttribute) #define unum_getAttribute U_ICU_ENTRY_POINT_RENAME(unum_getAttribute)
#define unum_getAvailable U_ICU_ENTRY_POINT_RENAME(unum_getAvailable) #define unum_getAvailable U_ICU_ENTRY_POINT_RENAME(unum_getAvailable)
#define unum_getDoubleAttribute U_ICU_ENTRY_POINT_RENAME(unum_getDoubleAttr ibute) #define unum_getDoubleAttribute U_ICU_ENTRY_POINT_RENAME(unum_getDoubleAttr ibute)
#define unum_getLocaleByType U_ICU_ENTRY_POINT_RENAME(unum_getLocaleByType) #define unum_getLocaleByType U_ICU_ENTRY_POINT_RENAME(unum_getLocaleByType)
#define unum_getSymbol U_ICU_ENTRY_POINT_RENAME(unum_getSymbol) #define unum_getSymbol U_ICU_ENTRY_POINT_RENAME(unum_getSymbol)
#define unum_getTextAttribute U_ICU_ENTRY_POINT_RENAME(unum_getTextAttribut e) #define unum_getTextAttribute U_ICU_ENTRY_POINT_RENAME(unum_getTextAttribut e)
#define unum_open U_ICU_ENTRY_POINT_RENAME(unum_open) #define unum_open U_ICU_ENTRY_POINT_RENAME(unum_open)
#define unum_parse U_ICU_ENTRY_POINT_RENAME(unum_parse) #define unum_parse U_ICU_ENTRY_POINT_RENAME(unum_parse)
#define unum_parseDecimal U_ICU_ENTRY_POINT_RENAME(unum_parseDecimal) #define unum_parseDecimal U_ICU_ENTRY_POINT_RENAME(unum_parseDecimal)
#define unum_parseDouble U_ICU_ENTRY_POINT_RENAME(unum_parseDouble) #define unum_parseDouble U_ICU_ENTRY_POINT_RENAME(unum_parseDouble)
#define unum_parseDoubleCurrency U_ICU_ENTRY_POINT_RENAME(unum_parseDoubleC urrency) #define unum_parseDoubleCurrency U_ICU_ENTRY_POINT_RENAME(unum_parseDoubleC urrency)
#define unum_parseInt64 U_ICU_ENTRY_POINT_RENAME(unum_parseInt64) #define unum_parseInt64 U_ICU_ENTRY_POINT_RENAME(unum_parseInt64)
#define unum_parseToUFormattable U_ICU_ENTRY_POINT_RENAME(unum_parseToUForm attable)
#define unum_setAttribute U_ICU_ENTRY_POINT_RENAME(unum_setAttribute) #define unum_setAttribute U_ICU_ENTRY_POINT_RENAME(unum_setAttribute)
#define unum_setDoubleAttribute U_ICU_ENTRY_POINT_RENAME(unum_setDoubleAttr ibute) #define unum_setDoubleAttribute U_ICU_ENTRY_POINT_RENAME(unum_setDoubleAttr ibute)
#define unum_setSymbol U_ICU_ENTRY_POINT_RENAME(unum_setSymbol) #define unum_setSymbol U_ICU_ENTRY_POINT_RENAME(unum_setSymbol)
#define unum_setTextAttribute U_ICU_ENTRY_POINT_RENAME(unum_setTextAttribut e) #define unum_setTextAttribute U_ICU_ENTRY_POINT_RENAME(unum_setTextAttribut e)
#define unum_toPattern U_ICU_ENTRY_POINT_RENAME(unum_toPattern) #define unum_toPattern U_ICU_ENTRY_POINT_RENAME(unum_toPattern)
#define unumsys_close U_ICU_ENTRY_POINT_RENAME(unumsys_close)
#define unumsys_getDescription U_ICU_ENTRY_POINT_RENAME(unumsys_getDescript
ion)
#define unumsys_getName U_ICU_ENTRY_POINT_RENAME(unumsys_getName)
#define unumsys_getRadix U_ICU_ENTRY_POINT_RENAME(unumsys_getRadix)
#define unumsys_isAlgorithmic U_ICU_ENTRY_POINT_RENAME(unumsys_isAlgorithmi
c)
#define unumsys_open U_ICU_ENTRY_POINT_RENAME(unumsys_open)
#define unumsys_openAvailableNames U_ICU_ENTRY_POINT_RENAME(unumsys_openAva
ilableNames)
#define unumsys_openByName U_ICU_ENTRY_POINT_RENAME(unumsys_openByName)
#define uplrules_close U_ICU_ENTRY_POINT_RENAME(uplrules_close) #define uplrules_close U_ICU_ENTRY_POINT_RENAME(uplrules_close)
#define uplrules_open U_ICU_ENTRY_POINT_RENAME(uplrules_open) #define uplrules_open U_ICU_ENTRY_POINT_RENAME(uplrules_open)
#define uplrules_openForType U_ICU_ENTRY_POINT_RENAME(uplrules_openForType) #define uplrules_openForType U_ICU_ENTRY_POINT_RENAME(uplrules_openForType)
#define uplrules_select U_ICU_ENTRY_POINT_RENAME(uplrules_select) #define uplrules_select U_ICU_ENTRY_POINT_RENAME(uplrules_select)
#define uplug_closeLibrary U_ICU_ENTRY_POINT_RENAME(uplug_closeLibrary) #define uplug_closeLibrary U_ICU_ENTRY_POINT_RENAME(uplug_closeLibrary)
#define uplug_findLibrary U_ICU_ENTRY_POINT_RENAME(uplug_findLibrary) #define uplug_findLibrary U_ICU_ENTRY_POINT_RENAME(uplug_findLibrary)
#define uplug_getConfiguration U_ICU_ENTRY_POINT_RENAME(uplug_getConfigurat ion) #define uplug_getConfiguration U_ICU_ENTRY_POINT_RENAME(uplug_getConfigurat ion)
#define uplug_getContext U_ICU_ENTRY_POINT_RENAME(uplug_getContext) #define uplug_getContext U_ICU_ENTRY_POINT_RENAME(uplug_getContext)
#define uplug_getCurrentLevel U_ICU_ENTRY_POINT_RENAME(uplug_getCurrentLeve l) #define uplug_getCurrentLevel U_ICU_ENTRY_POINT_RENAME(uplug_getCurrentLeve l)
#define uplug_getLibrary U_ICU_ENTRY_POINT_RENAME(uplug_getLibrary) #define uplug_getLibrary U_ICU_ENTRY_POINT_RENAME(uplug_getLibrary)
skipping to change at line 1343 skipping to change at line 1369
#define uprv_min U_ICU_ENTRY_POINT_RENAME(uprv_min) #define uprv_min U_ICU_ENTRY_POINT_RENAME(uprv_min)
#define uprv_modf U_ICU_ENTRY_POINT_RENAME(uprv_modf) #define uprv_modf U_ICU_ENTRY_POINT_RENAME(uprv_modf)
#define uprv_new_collIterate U_ICU_ENTRY_POINT_RENAME(uprv_new_collIterate) #define uprv_new_collIterate U_ICU_ENTRY_POINT_RENAME(uprv_new_collIterate)
#define uprv_parseCurrency U_ICU_ENTRY_POINT_RENAME(uprv_parseCurrency) #define uprv_parseCurrency U_ICU_ENTRY_POINT_RENAME(uprv_parseCurrency)
#define uprv_pathIsAbsolute U_ICU_ENTRY_POINT_RENAME(uprv_pathIsAbsolute) #define uprv_pathIsAbsolute U_ICU_ENTRY_POINT_RENAME(uprv_pathIsAbsolute)
#define uprv_pow U_ICU_ENTRY_POINT_RENAME(uprv_pow) #define uprv_pow U_ICU_ENTRY_POINT_RENAME(uprv_pow)
#define uprv_pow10 U_ICU_ENTRY_POINT_RENAME(uprv_pow10) #define uprv_pow10 U_ICU_ENTRY_POINT_RENAME(uprv_pow10)
#define uprv_realloc U_ICU_ENTRY_POINT_RENAME(uprv_realloc) #define uprv_realloc U_ICU_ENTRY_POINT_RENAME(uprv_realloc)
#define uprv_round U_ICU_ENTRY_POINT_RENAME(uprv_round) #define uprv_round U_ICU_ENTRY_POINT_RENAME(uprv_round)
#define uprv_sortArray U_ICU_ENTRY_POINT_RENAME(uprv_sortArray) #define uprv_sortArray U_ICU_ENTRY_POINT_RENAME(uprv_sortArray)
#define uprv_stableBinarySearch U_ICU_ENTRY_POINT_RENAME(uprv_stableBinaryS earch)
#define uprv_strCompare U_ICU_ENTRY_POINT_RENAME(uprv_strCompare) #define uprv_strCompare U_ICU_ENTRY_POINT_RENAME(uprv_strCompare)
#define uprv_strdup U_ICU_ENTRY_POINT_RENAME(uprv_strdup) #define uprv_strdup U_ICU_ENTRY_POINT_RENAME(uprv_strdup)
#define uprv_stricmp U_ICU_ENTRY_POINT_RENAME(uprv_stricmp) #define uprv_stricmp U_ICU_ENTRY_POINT_RENAME(uprv_stricmp)
#define uprv_strndup U_ICU_ENTRY_POINT_RENAME(uprv_strndup) #define uprv_strndup U_ICU_ENTRY_POINT_RENAME(uprv_strndup)
#define uprv_strnicmp U_ICU_ENTRY_POINT_RENAME(uprv_strnicmp) #define uprv_strnicmp U_ICU_ENTRY_POINT_RENAME(uprv_strnicmp)
#define uprv_syntaxError U_ICU_ENTRY_POINT_RENAME(uprv_syntaxError) #define uprv_syntaxError U_ICU_ENTRY_POINT_RENAME(uprv_syntaxError)
#define uprv_timezone U_ICU_ENTRY_POINT_RENAME(uprv_timezone) #define uprv_timezone U_ICU_ENTRY_POINT_RENAME(uprv_timezone)
#define uprv_toupper U_ICU_ENTRY_POINT_RENAME(uprv_toupper) #define uprv_toupper U_ICU_ENTRY_POINT_RENAME(uprv_toupper)
#define uprv_trunc U_ICU_ENTRY_POINT_RENAME(uprv_trunc) #define uprv_trunc U_ICU_ENTRY_POINT_RENAME(uprv_trunc)
#define uprv_tzname U_ICU_ENTRY_POINT_RENAME(uprv_tzname) #define uprv_tzname U_ICU_ENTRY_POINT_RENAME(uprv_tzname)
skipping to change at line 1440 skipping to change at line 1467
#define uregex_setTimeLimit U_ICU_ENTRY_POINT_RENAME(uregex_setTimeLimit) #define uregex_setTimeLimit U_ICU_ENTRY_POINT_RENAME(uregex_setTimeLimit)
#define uregex_setUText U_ICU_ENTRY_POINT_RENAME(uregex_setUText) #define uregex_setUText U_ICU_ENTRY_POINT_RENAME(uregex_setUText)
#define uregex_split U_ICU_ENTRY_POINT_RENAME(uregex_split) #define uregex_split U_ICU_ENTRY_POINT_RENAME(uregex_split)
#define uregex_splitUText U_ICU_ENTRY_POINT_RENAME(uregex_splitUText) #define uregex_splitUText U_ICU_ENTRY_POINT_RENAME(uregex_splitUText)
#define uregex_start U_ICU_ENTRY_POINT_RENAME(uregex_start) #define uregex_start U_ICU_ENTRY_POINT_RENAME(uregex_start)
#define uregex_start64 U_ICU_ENTRY_POINT_RENAME(uregex_start64) #define uregex_start64 U_ICU_ENTRY_POINT_RENAME(uregex_start64)
#define uregex_ucstr_unescape_charAt U_ICU_ENTRY_POINT_RENAME(uregex_ucstr_ unescape_charAt) #define uregex_ucstr_unescape_charAt U_ICU_ENTRY_POINT_RENAME(uregex_ucstr_ unescape_charAt)
#define uregex_useAnchoringBounds U_ICU_ENTRY_POINT_RENAME(uregex_useAnchor ingBounds) #define uregex_useAnchoringBounds U_ICU_ENTRY_POINT_RENAME(uregex_useAnchor ingBounds)
#define uregex_useTransparentBounds U_ICU_ENTRY_POINT_RENAME(uregex_useTran sparentBounds) #define uregex_useTransparentBounds U_ICU_ENTRY_POINT_RENAME(uregex_useTran sparentBounds)
#define uregex_utext_unescape_charAt U_ICU_ENTRY_POINT_RENAME(uregex_utext_ unescape_charAt) #define uregex_utext_unescape_charAt U_ICU_ENTRY_POINT_RENAME(uregex_utext_ unescape_charAt)
#define uregion_areEqual U_ICU_ENTRY_POINT_RENAME(uregion_areEqual)
#define uregion_contains U_ICU_ENTRY_POINT_RENAME(uregion_contains)
#define uregion_getAvailable U_ICU_ENTRY_POINT_RENAME(uregion_getAvailable)
#define uregion_getContainedRegions U_ICU_ENTRY_POINT_RENAME(uregion_getCon
tainedRegions)
#define uregion_getContainedRegionsOfType U_ICU_ENTRY_POINT_RENAME(uregion_
getContainedRegionsOfType)
#define uregion_getContainingRegion U_ICU_ENTRY_POINT_RENAME(uregion_getCon
tainingRegion)
#define uregion_getContainingRegionOfType U_ICU_ENTRY_POINT_RENAME(uregion_
getContainingRegionOfType)
#define uregion_getNumericCode U_ICU_ENTRY_POINT_RENAME(uregion_getNumericC
ode)
#define uregion_getPreferredValues U_ICU_ENTRY_POINT_RENAME(uregion_getPref
erredValues)
#define uregion_getRegionCode U_ICU_ENTRY_POINT_RENAME(uregion_getRegionCod
e)
#define uregion_getRegionFromCode U_ICU_ENTRY_POINT_RENAME(uregion_getRegio
nFromCode)
#define uregion_getRegionFromNumericCode U_ICU_ENTRY_POINT_RENAME(uregion_g
etRegionFromNumericCode)
#define uregion_getType U_ICU_ENTRY_POINT_RENAME(uregion_getType)
#define ures_close U_ICU_ENTRY_POINT_RENAME(ures_close) #define ures_close U_ICU_ENTRY_POINT_RENAME(ures_close)
#define ures_copyResb U_ICU_ENTRY_POINT_RENAME(ures_copyResb) #define ures_copyResb U_ICU_ENTRY_POINT_RENAME(ures_copyResb)
#define ures_countArrayItems U_ICU_ENTRY_POINT_RENAME(ures_countArrayItems) #define ures_countArrayItems U_ICU_ENTRY_POINT_RENAME(ures_countArrayItems)
#define ures_findResource U_ICU_ENTRY_POINT_RENAME(ures_findResource) #define ures_findResource U_ICU_ENTRY_POINT_RENAME(ures_findResource)
#define ures_findSubResource U_ICU_ENTRY_POINT_RENAME(ures_findSubResource) #define ures_findSubResource U_ICU_ENTRY_POINT_RENAME(ures_findSubResource)
#define ures_getBinary U_ICU_ENTRY_POINT_RENAME(ures_getBinary) #define ures_getBinary U_ICU_ENTRY_POINT_RENAME(ures_getBinary)
#define ures_getByIndex U_ICU_ENTRY_POINT_RENAME(ures_getByIndex) #define ures_getByIndex U_ICU_ENTRY_POINT_RENAME(ures_getByIndex)
#define ures_getByKey U_ICU_ENTRY_POINT_RENAME(ures_getByKey) #define ures_getByKey U_ICU_ENTRY_POINT_RENAME(ures_getByKey)
#define ures_getByKeyWithFallback U_ICU_ENTRY_POINT_RENAME(ures_getByKeyWit hFallback) #define ures_getByKeyWithFallback U_ICU_ENTRY_POINT_RENAME(ures_getByKeyWit hFallback)
#define ures_getFunctionalEquivalent U_ICU_ENTRY_POINT_RENAME(ures_getFunct ionalEquivalent) #define ures_getFunctionalEquivalent U_ICU_ENTRY_POINT_RENAME(ures_getFunct ionalEquivalent)
 End of changes. 18 change blocks. 
5 lines changed or deleted 60 lines changed or added


 uscript.h   uscript.h 
skipping to change at line 254 skipping to change at line 254
/** @stable ICU 3.6 */ /** @stable ICU 3.6 */
USCRIPT_NKO = 87, /* Nkoo */ USCRIPT_NKO = 87, /* Nkoo */
/** @stable ICU 3.6 */ /** @stable ICU 3.6 */
USCRIPT_ORKHON = 88, /* Orkh */ USCRIPT_ORKHON = 88, /* Orkh */
/** @stable ICU 3.6 */ /** @stable ICU 3.6 */
USCRIPT_OLD_PERMIC = 89, /* Perm */ USCRIPT_OLD_PERMIC = 89, /* Perm */
/** @stable ICU 3.6 */ /** @stable ICU 3.6 */
USCRIPT_PHAGS_PA = 90, /* Phag */ USCRIPT_PHAGS_PA = 90, /* Phag */
/** @stable ICU 3.6 */ /** @stable ICU 3.6 */
USCRIPT_PHOENICIAN = 91, /* Phnx */ USCRIPT_PHOENICIAN = 91, /* Phnx */
/** @stable ICU 52 */
USCRIPT_MIAO = 92, /* Plrd */
/** @stable ICU 3.6 */ /** @stable ICU 3.6 */
USCRIPT_PHONETIC_POLLARD = 92, /* Plrd */ USCRIPT_PHONETIC_POLLARD = USCRIPT_MIAO,
/** @stable ICU 3.6 */ /** @stable ICU 3.6 */
USCRIPT_RONGORONGO = 93, /* Roro */ USCRIPT_RONGORONGO = 93, /* Roro */
/** @stable ICU 3.6 */ /** @stable ICU 3.6 */
USCRIPT_SARATI = 94, /* Sara */ USCRIPT_SARATI = 94, /* Sara */
/** @stable ICU 3.6 */ /** @stable ICU 3.6 */
USCRIPT_ESTRANGELO_SYRIAC = 95, /* Syre */ USCRIPT_ESTRANGELO_SYRIAC = 95, /* Syre */
/** @stable ICU 3.6 */ /** @stable ICU 3.6 */
USCRIPT_WESTERN_SYRIAC = 96, /* Syrj */ USCRIPT_WESTERN_SYRIAC = 96, /* Syrj */
/** @stable ICU 3.6 */ /** @stable ICU 3.6 */
USCRIPT_EASTERN_SYRIAC = 97, /* Syrn */ USCRIPT_EASTERN_SYRIAC = 97, /* Syrn */
skipping to change at line 399 skipping to change at line 401
/** @stable ICU 4.8 */ /** @stable ICU 4.8 */
USCRIPT_WOLEAI = 155,/* Wole */ USCRIPT_WOLEAI = 155,/* Wole */
/** @stable ICU 49 */ /** @stable ICU 49 */
USCRIPT_ANATOLIAN_HIEROGLYPHS = 156,/* Hluw */ USCRIPT_ANATOLIAN_HIEROGLYPHS = 156,/* Hluw */
/** @stable ICU 49 */ /** @stable ICU 49 */
USCRIPT_KHOJKI = 157,/* Khoj */ USCRIPT_KHOJKI = 157,/* Khoj */
/** @stable ICU 49 */ /** @stable ICU 49 */
USCRIPT_TIRHUTA = 158,/* Tirh */ USCRIPT_TIRHUTA = 158,/* Tirh */
/** @stable ICU 52 */
USCRIPT_CAUCASIAN_ALBANIAN = 159,/* Aghb */
/** @stable ICU 52 */
USCRIPT_MAHAJANI = 160,/* Mahj */
/* Private use codes from Qaaa - Qabx are not supported */ /* Private use codes from Qaaa - Qabx are not supported */
/** @stable ICU 2.2 */ /** @stable ICU 2.2 */
USCRIPT_CODE_LIMIT = 159 USCRIPT_CODE_LIMIT = 161
} 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
 End of changes. 4 change blocks. 
2 lines changed or deleted 9 lines changed or added


 uspoof.h   uspoof.h 
skipping to change at line 809 skipping to change at line 809
UErrorCode *status); UErrorCode *status);
#if U_SHOW_CPLUSPLUS_API #if U_SHOW_CPLUSPLUS_API
/** /**
* Check the whether two specified strings are visually confusable. * Check the whether two specified strings are visually confusable.
* The types of confusability to be tested - single script, mixed script, * The types of confusability to be tested - single script, mixed script,
* or whole script - are determined by the check options set for the * or whole script - are determined by the check options set for the
* USpoofChecker. * USpoofChecker.
* *
* @param sc The USpoofChecker * @param sc The USpoofChecker
* @param id1 The first of the two identifiers to be compared for * @param s1 The first of the two identifiers to be compared for
* confusability. The strings are in UTF-8 format. * confusability. The strings are in UTF-8 format.
* @param id2 The second of the two identifiers to be compared for * @param s2 The second of the two identifiers to be compared for
* confusability. The strings are in UTF-8 format. * confusability. The strings are in UTF-8 format.
* @param status The error code, set if an error occurred while attempting to * @param status The error code, set if an error occurred while attempting to
* perform the check. * perform the check.
* Confusability of the identifiers is not reported here, * Confusability of the identifiers is not reported here,
* but through this function's return value. * but through this function's return value.
* @return An integer value with bit(s) set corresponding to * @return An integer value with bit(s) set corresponding to
* the type of confusability found, as defined by * the type of confusability found, as defined by
* enum USpoofChecks. Zero is returned if the identifiers * enum USpoofChecks. Zero is returned if the identifiers
* are not confusable. * are not confusable.
* @stable ICU 4.2 * @stable ICU 4.2
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added


 utrace.h   utrace.h 
/* /*
*************************************************************************** **** *************************************************************************** ****
* *
* Copyright (C) 2003-2012, International Business Machines * Copyright (C) 2003-2013, International Business Machines
* Corporation and others. All Rights Reserved. * Corporation and others. All Rights Reserved.
* *
*************************************************************************** **** *************************************************************************** ****
* file name: utrace.h * file name: utrace.h
* encoding: US-ASCII * encoding: US-ASCII
* tab size: 8 (not used) * tab size: 8 (not used)
* indentation:4 * indentation:4
* *
* created on: 2003aug06 * created on: 2003aug06
* created by: Markus W. Scherer * created by: Markus W. Scherer
skipping to change at line 89 skipping to change at line 89
UTRACE_COLLATION_START=0x2000, UTRACE_COLLATION_START=0x2000,
UTRACE_UCOL_OPEN=UTRACE_COLLATION_START, UTRACE_UCOL_OPEN=UTRACE_COLLATION_START,
UTRACE_UCOL_CLOSE, UTRACE_UCOL_CLOSE,
UTRACE_UCOL_STRCOLL, UTRACE_UCOL_STRCOLL,
UTRACE_UCOL_GET_SORTKEY, UTRACE_UCOL_GET_SORTKEY,
UTRACE_UCOL_GETLOCALE, UTRACE_UCOL_GETLOCALE,
UTRACE_UCOL_NEXTSORTKEYPART, UTRACE_UCOL_NEXTSORTKEYPART,
UTRACE_UCOL_STRCOLLITER, UTRACE_UCOL_STRCOLLITER,
UTRACE_UCOL_OPEN_FROM_SHORT_STRING, UTRACE_UCOL_OPEN_FROM_SHORT_STRING,
UTRACE_UCOL_STRCOLLUTF8, /**< @draft ICU 50 */ UTRACE_UCOL_STRCOLLUTF8, /**< @stable ICU 50 */
UTRACE_COLLATION_LIMIT UTRACE_COLLATION_LIMIT
} UTraceFunctionNumber; } UTraceFunctionNumber;
/** /**
* Setter for the trace level. * Setter for the trace level.
* @param traceLevel A UTraceLevel value. * @param traceLevel A UTraceLevel value.
* @stable ICU 2.8 * @stable ICU 2.8
*/ */
U_STABLE void U_EXPORT2 U_STABLE void U_EXPORT2
utrace_setLevel(int32_t traceLevel); utrace_setLevel(int32_t traceLevel);
 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 54 skipping to change at line 54
*/ */
#ifndef UVERNUM_H #ifndef UVERNUM_H
#define UVERNUM_H #define UVERNUM_H
/** The standard copyright notice that gets compiled into each library. /** The standard copyright notice that gets compiled into each library.
* 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_COPYRIGHT_STRING \ #define U_COPYRIGHT_STRING \
" Copyright (C) 2012, International Business Machines Corporation and oth ers. All Rights Reserved. " " Copyright (C) 2013, International Business Machines Corporation and oth ers. All Rights Reserved. "
/** The current ICU major version as an integer. /** The current ICU major 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_MAJOR_NUM 51 #define U_ICU_VERSION_MAJOR_NUM 52
/** 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 2 #define U_ICU_VERSION_MINOR_NUM 1
/** 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 0 #define U_ICU_VERSION_PATCHLEVEL_NUM 0
/** 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
* 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_SUFFIX _51 #define U_ICU_VERSION_SUFFIX _52
/** /**
* \def U_DEF2_ICU_ENTRY_POINT_RENAME * \def U_DEF2_ICU_ENTRY_POINT_RENAME
* @internal * @internal
*/ */
/** /**
* \def U_DEF_ICU_ENTRY_POINT_RENAME * \def U_DEF_ICU_ENTRY_POINT_RENAME
* @internal * @internal
*/ */
/** Glued version suffix function for renamers /** Glued version suffix function for renamers
skipping to change at line 121 skipping to change at line 121
#define U_DEF2_ICU_ENTRY_POINT_RENAME(x,y) U_DEF_ICU_ENTRY_POINT_RENAME(x,y ) #define U_DEF2_ICU_ENTRY_POINT_RENAME(x,y) U_DEF_ICU_ENTRY_POINT_RENAME(x,y )
#define U_ICU_ENTRY_POINT_RENAME(x) U_DEF2_ICU_ENTRY_POINT_RENAME(x,U_IC U_VERSION_SUFFIX) #define U_ICU_ENTRY_POINT_RENAME(x) U_DEF2_ICU_ENTRY_POINT_RENAME(x,U_IC U_VERSION_SUFFIX)
#endif #endif
#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 "51.2" #define U_ICU_VERSION "52.1"
/** 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 "51" #define U_ICU_VERSION_SHORT "52"
#ifndef U_HIDE_INTERNAL_API #ifndef U_HIDE_INTERNAL_API
/** 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 "51.2" #define U_ICU_DATA_VERSION "52.1"
#endif /* U_HIDE_INTERNAL_API */ #endif /* U_HIDE_INTERNAL_API */
/*========================================================================= == /*========================================================================= ==
* 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
*========================================================================= == *========================================================================= ==
*/ */
/** /**
 End of changes. 7 change blocks. 
7 lines changed or deleted 7 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/