diff options
author | Simon Hausmann <simon.hausmann@nokia.com> | 2012-09-14 16:29:47 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@nokia.com> | 2012-09-14 16:29:47 +0200 |
commit | d0424a769059c84ae20beb3c217812792ea6726b (patch) | |
tree | 6f94a5c3db8c52c6694ee56498542a6c35417350 /Source/WTF | |
parent | 88a04ac016f57c2d78e714682445dff2e7db4ade (diff) | |
download | qtwebkit-d0424a769059c84ae20beb3c217812792ea6726b.tar.gz |
Imported WebKit commit 37c5e5041d39a14ea0d429a77ebd352e4bd26516 (http://svn.webkit.org/repository/webkit/trunk@128608)
New snapshot that enables WebKit2 build on Windows (still some bugs) and allows for WebKit to be built with qmake && make
Diffstat (limited to 'Source/WTF')
50 files changed, 12495 insertions, 2411 deletions
diff --git a/Source/WTF/ChangeLog b/Source/WTF/ChangeLog index e07e85b7d..1f6af6bb0 100644 --- a/Source/WTF/ChangeLog +++ b/Source/WTF/ChangeLog @@ -1,3 +1,355 @@ +2012-09-14 Ilya Tikhonovsky <loislo@chromium.org> + + Web Inspector: NMI: remove current traits helper class because it is customizing the instrumentation at a wrong place and is not necessary at the moment. + https://bugs.webkit.org/show_bug.cgi?id=96737 + + Reviewed by Yury Semikhatsky. + + * wtf/MemoryInstrumentation.h: + (MemoryInstrumentation): + WTF::MemoryInstrumentationTraits): removed + (WTF::MemoryInstrumentation::OwningTraits::addInstrumentedObject): direct call inserted + (WTF::MemoryInstrumentation::OwningTraits::addObject):direct call inserted + +2012-09-13 Kenneth Rohde Christiansen <kenneth@webkit.org> + + Evas_Object* is a ref'ed structure, so tread it as such + https://bugs.webkit.org/show_bug.cgi?id=96659 + + Reviewed by Gyuyoung Kim. + + Remove OwnPtr support for Evas_Object* and add support for it + with RefPtr instead (the latter moved from WebCore). + + * wtf/PlatformEfl.cmake: + * wtf/efl/OwnPtrEfl.cpp: + * wtf/efl/RefPtrEfl.cpp: Renamed from Source/WebCore/platform/efl/RefPtrEfl.cpp. + (WTF): + (WTF::refIfNotNull): + (WTF::derefIfNotNull): + * wtf/efl/RefPtrEfl.h: Renamed from Source/WebCore/platform/efl/RefPtrEfl.h. + (WTF): + +2012-09-14 Gyuyoung Kim <gyuyoung.kim@samsung.com> + + Unreviewed, rolling out r128507. + http://trac.webkit.org/changeset/128507 + https://bugs.webkit.org/show_bug.cgi?id=96659 + + Revert. r128507 makes too many crash in EFL layout test bots. + + * wtf/PlatformEfl.cmake: + * wtf/efl/OwnPtrEfl.cpp: + (WTF::deleteOwnedPtr): + (WTF): + +2012-09-13 Kevin Funk <kevin.funk@kdab.com> + + Make compile with both OS(WINCE) and PLATFORM(QT) support + https://bugs.webkit.org/show_bug.cgi?id=95536 + + Reviewed by Simon Hausmann. + + Fixes for Windows CE. + + * WTF.pri: + Also include path for mt19937ar.c + * wtf/unicode/icu/CollatorICU.cpp: + Fix undeclared strdup() on CE7 + * wtf/Platform.h: + +2012-09-13 Byungseon Shin <xingri@gmail.com> + + Fix for WTF fails to compile in thumb mode when llint is enabled. + https://bugs.webkit.org/show_bug.cgi?id=96400 + + Reviewed by Filip Pizlo. + + When using "+m" with Armv7 cross compiler assume offset range between +/- 4095 + (the largest possible offset range). + However, ldrex/strex can only use offset range of 0~1020, so "+m" needed to be changed to "+Q". + Ref. http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54480 + + * wtf/Atomics.h: + (WTF::weakCompareAndSwap): + +2012-09-13 Kenneth Rohde Christiansen <kenneth@webkit.org> + + Evas_Object* is a ref'ed structure, so tread it as such + https://bugs.webkit.org/show_bug.cgi?id=96659 + + Reviewed by Adam Barth. + + Remove OwnPtr support for Evas_Object* and add support for it + with RefPtr instead (the latter moved from WebCore). + + * wtf/PlatformEfl.cmake: + * wtf/efl/OwnPtrEfl.cpp: + * wtf/efl/RefPtrEfl.cpp: Renamed from Source/WebCore/platform/efl/RefPtrEfl.cpp. + (WTF): + (WTF::refIfNotNull): + (WTF::derefIfNotNull): + * wtf/efl/RefPtrEfl.h: Renamed from Source/WebCore/platform/efl/RefPtrEfl.h. + (WTF): + +2012-09-13 Michael Saboff <msaboff@apple.com> + + Added 8 bit path to WidthIterator::advance() + https://bugs.webkit.org/show_bug.cgi?id=96590 + + Reviewed by Geoffrey Garen. + + Added new character constant for Hiragana Letter Small A. + + * wtf/unicode/CharacterNames.h: + (Unicode): + +2012-09-13 Ilya Tikhonovsky <loislo@chromium.org> + + Web Inspector: NMI: instrument KURL directly. + https://bugs.webkit.org/show_bug.cgi?id=96624 + + Reviewed by Yury Semikhatsky. + + I replaced traits based instrumentation of KURL with reportMemoryUsage functions. + CString* were also instrumented. + + Drive by fix: Instrumentation code in QualifiedName was moved to cpp. + + * wtf/text/CString.h: + (CStringBuffer): + (WTF::CStringBuffer::reportMemoryUsage): + (CString): + (WTF::CString::reportMemoryUsage): + +2012-09-12 Ilya Tikhonovsky <loislo@chromium.org> + + Web Inspector: NMI: migrate core instrumentation code to WTF namespace + https://bugs.webkit.org/show_bug.cgi?id=96511 + + Reviewed by Yury Semikhatsky. + + After moving core NMI code to WTF namespace I removed forward declarations + of MemoryObjectInfo and MemoryInstrumentation from WebCore headers and add + forward declaration into wtf/Forward.h + + * wtf/Forward.h: + (WTF): + * wtf/MemoryInstrumentation.h: + +2012-09-12 Dan Bernstein <mitz@apple.com> + + Removed a reference to a file that doesn’t participate in any target. + + * WTF.xcodeproj/project.pbxproj: Removed the reference to + CONTRIBUTORS.pthreads-win32. + +2012-09-11 Michael Saboff <msaboff@apple.com> + + Element::classAttributeChanged should use characters8/16 to find first non-whitespace + https://bugs.webkit.org/show_bug.cgi?id=96446 + + Reviewed by Benjamin Poulain. + + Added bit size related string accessors to AtomicString to support change. + + * wtf/text/AtomicString.h: + (AtomicString): + (WTF::AtomicString::is8Bit): + (WTF::AtomicString::characters8): + (WTF::AtomicString::characters16): + +2012-09-12 Michael Saboff <msaboff@apple.com> + + Build fixed for http://trac.webkit.org/changeset/128243 + + Unreviewed build fix. + + Removed temporarily added function signature. + + * icu/unicode/unistr.h: + (UnicodeString::extract): + +2012-09-12 Michael Saboff <msaboff@apple.com> + + Build fixed for http://trac.webkit.org/changeset/128243 + + Unreviewed build fix. + + Change UnicodeString::extract for gcc based on ICU fix described in + http://bugs.icu-project.org/trac/ticket/8197. + + * icu/unicode/unistr.h: + (UnicodeString::extract): + +2012-09-12 Ilya Tikhonovsky <loislo@chromium.org> + + Web Inspector: NMI move String* instrumentation to wtf. + https://bugs.webkit.org/show_bug.cgi?id=96405 + + Reviewed by Yury Semikhatsky. + + This instrumentation is solving the problem with substrings and removes traits based code which is hard to upstream. + + Tested by webkit_unit_tests. + + * wtf/text/AtomicString.h: + (AtomicString): + (WTF::AtomicString::reportMemoryUsage): + * wtf/text/StringImpl.h: + (StringImpl): + (WTF::StringImpl::reportMemoryUsage): + * wtf/text/WTFString.h: + (String): + (WTF::String::reportMemoryUsage): + +2012-09-12 Sheriff Bot <webkit.review.bot@gmail.com> + + Unreviewed, rolling out r128279. + http://trac.webkit.org/changeset/128279 + https://bugs.webkit.org/show_bug.cgi?id=96487 + + "Snow Leopard compilation broken" (Requested by yurys on + #webkit). + + * wtf/MemoryInstrumentation.h: + (GenericMemoryTypes): + (WebCore): + (WebCore::MemoryInstrumentation::addRootObject): + (WebCore::MemoryObjectInfo::reportObjectInfo): + (WebCore::MemoryClassInfo::MemoryClassInfo): + * wtf/text/AtomicString.h: + (AtomicString): + * wtf/text/StringImpl.h: + * wtf/text/WTFString.h: + +2012-09-12 Yury Semikhatsky <yurys@chromium.org> + + Web Inspector: Persistent handle referenced from ScriptWrappable is double counted + https://bugs.webkit.org/show_bug.cgi?id=96483 + + Reviewed by Alexander Pavlov. + + * wtf/MemoryInstrumentation.h: + (WebCore::MemoryClassInfo::addWeakPointer): this method is expected to be + used on fields that are pointers to objects which are parts of bigger memory + blocks (field of another object, element in an array, object allocated in a + memory arena etc.). We don't want to count such objects' memory separately + from their owners but in order to be able to validates the memory instrumentation + with clang plugin we need to make sure all fields in instrumented objects + are reported. + (MemoryClassInfo): + +2012-09-12 Ilya Tikhonovsky <loislo@chromium.org> + + Web Inspector: NMI move String* instrumentation to wtf. + https://bugs.webkit.org/show_bug.cgi?id=96405 + + Reviewed by Yury Semikhatsky. + + This instrumentation is solving the problem with substrings and removes traits based code which is hard to upstream. + + Tested by webkit_unit_tests. + + * wtf/MemoryInstrumentation.h: + (WebCore): + (WebCore::MemoryInstrumentation::addRootObject): + (WebCore::MemoryObjectInfo::reportObjectInfo): + (WebCore::MemoryClassInfo::MemoryClassInfo): + * wtf/text/AtomicString.h: + (AtomicString): + (WTF::AtomicString::reportMemoryUsage): + * wtf/text/StringImpl.h: + (StringImpl): + (WTF::StringImpl::reportMemoryUsage): + * wtf/text/WTFString.h: + (String): + (WTF::String::reportMemoryUsage): + +2012-09-11 Michael Saboff <msaboff@apple.com> + + Build fixed for http://trac.webkit.org/changeset/128243 + + Unreviewed build fix. + + Added missing include file needed by 96422 for C++ ICU APIs. + + * icu/unicode/bytestream.h: Added. + * icu/unicode/rep.h: Added. + * icu/unicode/std_string.h: Added. + * icu/unicode/strenum.h: Added. + * icu/unicode/stringpiece.h: Added. + * icu/unicode/unistr.h: Added. + * icu/unicode/uobject.h: Added. + +2012-09-11 Michael Saboff <msaboff@apple.com> + + Build fixed for http://trac.webkit.org/changeset/128243 + + Rubber stamped by Stephanie Lewis. + + Added missing include file needed by 96422. + + * icu/unicode/unorm2.h: Added. + +2012-09-11 Michael Saboff <msaboff@apple.com> + + Build fixed for http://trac.webkit.org/changeset/128243 + + Rubber stamped by Stephanie Lewis. + + Added missing include file needed by 96422. + + * icu/unicode/ptypes.h: Added. + +2012-09-11 Michael Saboff <msaboff@apple.com> + + Update ICU header files to more recent version + https://bugs.webkit.org/show_bug.cgi?id=96422 + + Reviewed by Geoff Garen. + + Updated ICU header files to 4.6.1. Modifications made as part of the merge are: + platform.h - Changed ifndef / define / endif for U_HAVE_UINT8_T, U_HAVE_UINT16_T, U_HAVE_UINT32_T, + U_HAVE_UINT64_T, U_IS_BIG_ENDIAN and U_ENABLE_TRACING to match the existing platform.h + putil.h (line 132) - Changes defined(U_WINDOWS) to defined(WIN32) || defined(OS2) to match existing putil.h + ustring.h (line 945) - Wrapped macro argument cs with { (const UChar *)cs } to match existing ustring.h + utypes.h (line 545) - Changed defined(U_WINDOWS) to defined(WIN32) to match existing utypes.h + + * icu/unicode/localpointer.h: Added. + * icu/unicode/parseerr.h: + * icu/unicode/platform.h: + * icu/unicode/putil.h: + * icu/unicode/uchar.h: + * icu/unicode/ucnv.h: + * icu/unicode/ucnv_err.h: + * icu/unicode/ucol.h: + * icu/unicode/uconfig.h: + * icu/unicode/uenum.h: + * icu/unicode/uiter.h: + * icu/unicode/uloc.h: + * icu/unicode/umachine.h: + * icu/unicode/unorm.h: + * icu/unicode/urename.h: + * icu/unicode/uscript.h: + * icu/unicode/uset.h: + * icu/unicode/ustring.h: + * icu/unicode/utf.h: + * icu/unicode/utf16.h: + * icu/unicode/utf8.h: + * icu/unicode/utypes.h: + * icu/unicode/uvernum.h: Added. + * icu/unicode/uversion.h: + +2012-09-11 Pratik Solanki <psolanki@apple.com> + + Add ObjcRuntimeExtras.h to the Xcode project file + https://bugs.webkit.org/show_bug.cgi?id=96419 + + Reviewed by Alexey Proskuryakov. + + * WTF.xcodeproj/project.pbxproj: + 2012-09-11 Adrienne Walker <enne@google.com> Clang doesn't optimize away undefined OwnPtr copy constructor diff --git a/Source/WTF/WTF.pro b/Source/WTF/WTF.pro index 789e49bfa..bc0a8770e 100644 --- a/Source/WTF/WTF.pro +++ b/Source/WTF/WTF.pro @@ -14,6 +14,11 @@ VPATH += $$PWD/wtf INCLUDEPATH += $$PWD/wtf +wince* { + # for mt19937ar.c + INCLUDEPATH += $${ROOT_WEBKIT_DIR}/Source/ThirdParty +} + HEADERS += \ Alignment.h \ AlwaysInline.h \ diff --git a/Source/WTF/WTF.xcodeproj/project.pbxproj b/Source/WTF/WTF.xcodeproj/project.pbxproj index 750b61749..52af7b9ce 100644 --- a/Source/WTF/WTF.xcodeproj/project.pbxproj +++ b/Source/WTF/WTF.xcodeproj/project.pbxproj @@ -17,6 +17,7 @@ 4330F38F15745B0500AAFA8F /* URLString.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4330F38E15745B0500AAFA8F /* URLString.cpp */; }; 4F0321BC156AA8D1006EBAF6 /* BitArray.h in Headers */ = {isa = PBXBuildFile; fileRef = 4F0321BB156AA8D1006EBAF6 /* BitArray.h */; }; 4F1D115415FF11BE0026E908 /* MemoryInstrumentation.h in Headers */ = {isa = PBXBuildFile; fileRef = 4F1D115315FF11BE0026E908 /* MemoryInstrumentation.h */; }; + 7E29C33E15FFD79B00516D61 /* ObjcRuntimeExtras.h in Headers */ = {isa = PBXBuildFile; fileRef = 7E29C33D15FFD79B00516D61 /* ObjcRuntimeExtras.h */; }; 8134013815B092FD001FF0B8 /* Base64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8134013615B092FD001FF0B8 /* Base64.cpp */; }; 8134013915B092FD001FF0B8 /* Base64.h in Headers */ = {isa = PBXBuildFile; fileRef = 8134013715B092FD001FF0B8 /* Base64.h */; }; A876DBD8151816E500DADB95 /* Platform.h in Headers */ = {isa = PBXBuildFile; fileRef = A876DBD7151816E500DADB95 /* Platform.h */; }; @@ -270,6 +271,7 @@ 5D247B7014689C4700E78B76 /* DebugRelease.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = DebugRelease.xcconfig; sourceTree = "<group>"; }; 5D247B7314689C4700E78B76 /* WTF.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = WTF.xcconfig; sourceTree = "<group>"; }; 5D247EB11468B01500E78B76 /* HeaderDetection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = HeaderDetection.h; path = DerivedSources/WTF/HeaderDetection.h; sourceTree = BUILT_PRODUCTS_DIR; }; + 7E29C33D15FFD79B00516D61 /* ObjcRuntimeExtras.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ObjcRuntimeExtras.h; sourceTree = "<group>"; }; 8134013615B092FD001FF0B8 /* Base64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Base64.cpp; sourceTree = "<group>"; }; 8134013715B092FD001FF0B8 /* Base64.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Base64.h; sourceTree = "<group>"; }; A876DBD7151816E500DADB95 /* Platform.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Platform.h; sourceTree = "<group>"; }; @@ -295,7 +297,6 @@ A8A4726B151A825A004123FF /* CheckedBoolean.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CheckedBoolean.h; sourceTree = "<group>"; }; A8A47270151A825A004123FF /* Compiler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Compiler.h; sourceTree = "<group>"; }; A8A47271151A825A004123FF /* Complex.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Complex.h; sourceTree = "<group>"; }; - A8A47272151A825A004123FF /* CONTRIBUTORS.pthreads-win32 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = "CONTRIBUTORS.pthreads-win32"; sourceTree = "<group>"; }; A8A47273151A825A004123FF /* CryptographicallyRandomNumber.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CryptographicallyRandomNumber.cpp; sourceTree = "<group>"; }; A8A47274151A825A004123FF /* CryptographicallyRandomNumber.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CryptographicallyRandomNumber.h; sourceTree = "<group>"; }; A8A47275151A825A004123FF /* CurrentTime.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CurrentTime.cpp; sourceTree = "<group>"; }; @@ -591,7 +592,6 @@ A8A4726B151A825A004123FF /* CheckedBoolean.h */, A8A47270151A825A004123FF /* Compiler.h */, A8A47271151A825A004123FF /* Complex.h */, - A8A47272151A825A004123FF /* CONTRIBUTORS.pthreads-win32 */, A8A47273151A825A004123FF /* CryptographicallyRandomNumber.cpp */, A8A47274151A825A004123FF /* CryptographicallyRandomNumber.h */, A8A47275151A825A004123FF /* CurrentTime.cpp */, @@ -661,6 +661,7 @@ A8A472D4151A825B004123FF /* NullPtr.h */, A8A472D5151A825B004123FF /* NumberOfCores.cpp */, A8A472D6151A825B004123FF /* NumberOfCores.h */, + 7E29C33D15FFD79B00516D61 /* ObjcRuntimeExtras.h */, A8A472D7151A825B004123FF /* OSAllocator.h */, A8A472D8151A825B004123FF /* OSAllocatorPosix.cpp */, A8A472DA151A825B004123FF /* OSRandomSource.cpp */, @@ -982,6 +983,7 @@ A8A473F1151A825B004123FF /* NotFound.h in Headers */, A8A473F3151A825B004123FF /* NullPtr.h in Headers */, A8A473F5151A825B004123FF /* NumberOfCores.h in Headers */, + 7E29C33E15FFD79B00516D61 /* ObjcRuntimeExtras.h in Headers */, A8A473F6151A825B004123FF /* OSAllocator.h in Headers */, A8A473FA151A825B004123FF /* OSRandomSource.h in Headers */, A8A473FB151A825B004123FF /* OwnArrayPtr.h in Headers */, diff --git a/Source/WTF/icu/unicode/bytestream.h b/Source/WTF/icu/unicode/bytestream.h new file mode 100644 index 000000000..fb9e07a25 --- /dev/null +++ b/Source/WTF/icu/unicode/bytestream.h @@ -0,0 +1,252 @@ +// Copyright (C) 2009-2010, International Business Machines +// Corporation and others. All Rights Reserved. +// +// Copyright 2007 Google Inc. All Rights Reserved. +// Author: sanjay@google.com (Sanjay Ghemawat) +// +// Abstract interface that consumes a sequence of bytes (ByteSink). +// +// Used so that we can write a single piece of code that can operate +// on a variety of output string types. +// +// Various implementations of this interface are provided: +// ByteSink: +// CheckedArrayByteSink Write to a flat array, with bounds checking +// StringByteSink Write to an STL string + +// 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 guidelines. +// For example, data types are ICU-ified (size_t,int->int32_t), +// and API comments doxygen-ified, but function names and behavior are +// as in the original, if possible. +// Assertion-style error handling, not available in ICU, was changed to +// parameter "pinning" similar to UnicodeString. +// +// In addition, this is only a partial port of the original Google code, +// limited to what was needed so far. The (nearly) complete original code +// is in the ICU svn repository at icuhtml/trunk/design/strings/contrib +// (see ICU ticket 6765, r25517). + +#ifndef __BYTESTREAM_H__ +#define __BYTESTREAM_H__ + +/** + * \file + * \brief C++ API: Interface for writing bytes, and implementation classes. + */ + +#include "unicode/utypes.h" +#include "unicode/uobject.h" +#include "unicode/std_string.h" + +U_NAMESPACE_BEGIN + +/** + * A ByteSink can be filled with bytes. + * @stable ICU 4.2 + */ +class U_COMMON_API ByteSink : public UMemory { +public: + /** + * Default constructor. + * @stable ICU 4.2 + */ + ByteSink() { } + /** + * Virtual destructor. + * @stable ICU 4.2 + */ + virtual ~ByteSink() { } + + /** + * Append "bytes[0,n-1]" to this. + * @param bytes the pointer to the bytes + * @param n the number of bytes; must be non-negative + * @stable ICU 4.2 + */ + virtual void Append(const char* bytes, int32_t n) = 0; + + /** + * Returns a writable buffer for appending and writes the buffer's capacity to + * *result_capacity. Guarantees *result_capacity>=min_capacity. + * May return a pointer to the caller-owned scratch buffer which must have + * scratch_capacity>=min_capacity. + * The returned buffer is only valid until the next operation + * on this ByteSink. + * + * After writing at most *result_capacity bytes, call Append() with the + * pointer returned from this function and the number of bytes written. + * Many Append() implementations will avoid copying bytes if this function + * returned an internal buffer. + * + * Partial usage example: + * int32_t capacity; + * char* buffer = sink->GetAppendBuffer(..., &capacity); + * ... Write n bytes into buffer, with n <= capacity. + * sink->Append(buffer, n); + * In many implementations, that call to Append will avoid copying bytes. + * + * If the ByteSink allocates or reallocates an internal buffer, it should use + * the desired_capacity_hint if appropriate. + * If a caller cannot provide a reasonable guess at the desired capacity, + * it should pass desired_capacity_hint=0. + * + * If a non-scratch buffer is returned, the caller may only pass + * a prefix to it to Append(). + * That is, it is not correct to pass an interior pointer to Append(). + * + * The default implementation always returns the scratch buffer. + * + * @param min_capacity required minimum capacity of the returned buffer; + * must be non-negative + * @param desired_capacity_hint desired capacity of the returned buffer; + * must be non-negative + * @param scratch default caller-owned buffer + * @param scratch_capacity capacity of the scratch buffer + * @param result_capacity pointer to an integer which will be set to the + * capacity of the returned buffer + * @return a buffer with *result_capacity>=min_capacity + * @stable ICU 4.2 + */ + virtual char* GetAppendBuffer(int32_t min_capacity, + int32_t desired_capacity_hint, + char* scratch, int32_t scratch_capacity, + int32_t* result_capacity); + + /** + * Flush internal buffers. + * Some byte sinks use internal buffers or provide buffering + * and require calling Flush() at the end of the stream. + * The ByteSink should be ready for further Append() calls after Flush(). + * The default implementation of Flush() does nothing. + * @stable ICU 4.2 + */ + virtual void Flush(); + +private: + ByteSink(const ByteSink &); // copy constructor not implemented + ByteSink &operator=(const ByteSink &); // assignment operator not implemented +}; + +// ------------------------------------------------------------- +// Some standard implementations + +/** + * Implementation of ByteSink that writes to a flat byte array, + * with bounds-checking: + * This sink will not write more than capacity bytes to outbuf. + * If more than capacity bytes are Append()ed, then excess bytes are ignored, + * and Overflowed() will return true. + * Overflow does not cause a runtime error. + * @stable ICU 4.2 + */ +class U_COMMON_API CheckedArrayByteSink : public ByteSink { +public: + /** + * Constructs a ByteSink that will write to outbuf[0..capacity-1]. + * @param outbuf buffer to write to + * @param capacity size of the buffer + * @stable ICU 4.2 + */ + CheckedArrayByteSink(char* outbuf, int32_t capacity); + /** + * Returns the sink to its original state, without modifying the buffer. + * Useful for reusing both the buffer and the sink for multiple streams. + * Resets the state to NumberOfBytesWritten()=NumberOfBytesAppended()=0 + * and Overflowed()=FALSE. + * @return *this + * @draft ICU 4.6 + */ + virtual CheckedArrayByteSink& Reset(); + /** + * Append "bytes[0,n-1]" to this. + * @param bytes the pointer to the bytes + * @param n the number of bytes; must be non-negative + * @stable ICU 4.2 + */ + virtual void Append(const char* bytes, int32_t n); + /** + * Returns a writable buffer for appending and writes the buffer's capacity to + * *result_capacity. For details see the base class documentation. + * @param min_capacity required minimum capacity of the returned buffer; + * must be non-negative + * @param desired_capacity_hint desired capacity of the returned buffer; + * must be non-negative + * @param scratch default caller-owned buffer + * @param scratch_capacity capacity of the scratch buffer + * @param result_capacity pointer to an integer which will be set to the + * capacity of the returned buffer + * @return a buffer with *result_capacity>=min_capacity + * @stable ICU 4.2 + */ + virtual char* GetAppendBuffer(int32_t min_capacity, + int32_t desired_capacity_hint, + char* scratch, int32_t scratch_capacity, + int32_t* result_capacity); + /** + * Returns the number of bytes actually written to the sink. + * @return number of bytes written to the buffer + * @stable ICU 4.2 + */ + int32_t NumberOfBytesWritten() const { return size_; } + /** + * Returns true if any bytes were discarded, i.e., if there was an + * attempt to write more than 'capacity' bytes. + * @return TRUE if more than 'capacity' bytes were Append()ed + * @stable ICU 4.2 + */ + UBool Overflowed() const { return overflowed_; } + /** + * Returns the number of bytes appended to the sink. + * If Overflowed() then NumberOfBytesAppended()>NumberOfBytesWritten() + * else they return the same number. + * @return number of bytes written to the buffer + * @draft ICU 4.6 + */ + int32_t NumberOfBytesAppended() const { return appended_; } +private: + char* outbuf_; + const int32_t capacity_; + int32_t size_; + int32_t appended_; + UBool overflowed_; + CheckedArrayByteSink(); ///< default constructor not implemented + CheckedArrayByteSink(const CheckedArrayByteSink &); ///< copy constructor not implemented + CheckedArrayByteSink &operator=(const CheckedArrayByteSink &); ///< assignment operator not implemented +}; + +#if U_HAVE_STD_STRING + +/** + * Implementation of ByteSink that writes to a "string". + * The StringClass is usually instantiated with a std::string. + * @stable ICU 4.2 + */ +template<typename StringClass> +class StringByteSink : public ByteSink { + public: + /** + * Constructs a ByteSink that will append bytes to the dest string. + * @param dest pointer to string object to append to + * @stable ICU 4.2 + */ + StringByteSink(StringClass* dest) : dest_(dest) { } + /** + * Append "bytes[0,n-1]" to this. + * @param data the pointer to the bytes + * @param n the number of bytes; must be non-negative + * @stable ICU 4.2 + */ + virtual void Append(const char* data, int32_t n) { dest_->append(data, n); } + private: + StringClass* dest_; + StringByteSink(); ///< default constructor not implemented + StringByteSink(const StringByteSink &); ///< copy constructor not implemented + StringByteSink &operator=(const StringByteSink &); ///< assignment operator not implemented +}; + +#endif + +U_NAMESPACE_END + +#endif // __BYTESTREAM_H__ diff --git a/Source/WTF/icu/unicode/localpointer.h b/Source/WTF/icu/unicode/localpointer.h new file mode 100644 index 000000000..b76a1f856 --- /dev/null +++ b/Source/WTF/icu/unicode/localpointer.h @@ -0,0 +1,300 @@ +/* +******************************************************************************* +* +* Copyright (C) 2009-2010, International Business Machines +* Corporation and others. All Rights Reserved. +* +******************************************************************************* +* file name: localpointer.h +* encoding: US-ASCII +* tab size: 8 (not used) +* indentation:4 +* +* created on: 2009nov13 +* created by: Markus W. Scherer +*/ + +#ifndef __LOCALPOINTER_H__ +#define __LOCALPOINTER_H__ + +/** + * \file + * \brief C++ API: "Smart pointers" for use with and in ICU4C C++ code. + * + * These classes are inspired by + * - std::auto_ptr + * - boost::scoped_ptr & boost::scoped_array + * - Taligent Safe Pointers (TOnlyPointerTo) + * + * but none of those provide for all of the goals for ICU smart pointers: + * - Smart pointer owns the object and releases it when it goes out of scope. + * - No transfer of ownership via copy/assignment to reduce misuse. Simpler & more robust. + * - ICU-compatible: No exceptions. + * - Need to be able to orphan/release the pointer and its ownership. + * - Need variants for normal C++ object pointers, C++ arrays, and ICU C service objects. + * + * For details see http://site.icu-project.org/design/cpp/scoped_ptr + */ + +#include "unicode/utypes.h" + +#if U_SHOW_CPLUSPLUS_API + +U_NAMESPACE_BEGIN + +/** + * "Smart pointer" base class; do not use directly: use LocalPointer etc. + * + * Base class for smart pointer classes that do not throw exceptions. + * + * Do not use this base class directly, since it does not delete its pointer. + * A subclass must implement methods that delete the pointer: + * Destructor and adoptInstead(). + * + * There is no operator T *() provided because the programmer must decide + * whether to use getAlias() (without transfer of ownership) or orpan() + * (with transfer of ownership and NULLing of the pointer). + * + * @see LocalPointer + * @see LocalArray + * @see U_DEFINE_LOCAL_OPEN_POINTER + * @stable ICU 4.4 + */ +template<typename T> +class LocalPointerBase { +public: + /** + * Constructor takes ownership. + * @param p simple pointer to an object that is adopted + * @stable ICU 4.4 + */ + explicit LocalPointerBase(T *p=NULL) : ptr(p) {} + /** + * Destructor deletes the object it owns. + * Subclass must override: Base class does nothing. + * @stable ICU 4.4 + */ + ~LocalPointerBase() { /* delete ptr; */ } + /** + * NULL check. + * @return TRUE if ==NULL + * @stable ICU 4.4 + */ + UBool isNull() const { return ptr==NULL; } + /** + * NULL check. + * @return TRUE if !=NULL + * @stable ICU 4.4 + */ + UBool isValid() const { return ptr!=NULL; } + /** + * Comparison with a simple pointer, so that existing code + * with ==NULL need not be changed. + * @param other simple pointer for comparison + * @return true if this pointer value equals other + * @stable ICU 4.4 + */ + bool operator==(const T *other) const { return ptr==other; } + /** + * Comparison with a simple pointer, so that existing code + * with !=NULL need not be changed. + * @param other simple pointer for comparison + * @return true if this pointer value differs from other + * @stable ICU 4.4 + */ + bool operator!=(const T *other) const { return ptr!=other; } + /** + * Access without ownership change. + * @return the pointer value + * @stable ICU 4.4 + */ + T *getAlias() const { return ptr; } + /** + * Access without ownership change. + * @return the pointer value as a reference + * @stable ICU 4.4 + */ + T &operator*() const { return *ptr; } + /** + * Access without ownership change. + * @return the pointer value + * @stable ICU 4.4 + */ + T *operator->() const { return ptr; } + /** + * Gives up ownership; the internal pointer becomes NULL. + * @return the pointer value; + * caller becomes responsible for deleting the object + * @stable ICU 4.4 + */ + T *orphan() { + T *p=ptr; + ptr=NULL; + return p; + } + /** + * Deletes the object it owns, + * and adopts (takes ownership of) the one passed in. + * Subclass must override: Base class does not delete the object. + * @param p simple pointer to an object that is adopted + * @stable ICU 4.4 + */ + void adoptInstead(T *p) { + // delete ptr; + ptr=p; + } +protected: + T *ptr; +private: + // No comparison operators with other LocalPointerBases. + bool operator==(const LocalPointerBase &other); + bool operator!=(const LocalPointerBase &other); + // No ownership transfer: No copy constructor, no assignment operator. + LocalPointerBase(const LocalPointerBase &other); + void operator=(const LocalPointerBase &other); + // No heap allocation. Use only on the stack. + static void * U_EXPORT2 operator new(size_t size); + static void * U_EXPORT2 operator new[](size_t size); +#if U_HAVE_PLACEMENT_NEW + static void * U_EXPORT2 operator new(size_t, void *ptr); +#endif +}; + +/** + * "Smart pointer" class, deletes objects via the standard C++ delete operator. + * For most methods see the LocalPointerBase base class. + * + * Usage example: + * \code + * LocalPointer<UnicodeString> s(new UnicodeString((UChar32)0x50005)); + * int32_t length=s->length(); // 2 + * UChar lead=s->charAt(0); // 0xd900 + * if(some condition) { return; } // no need to explicitly delete the pointer + * s.adoptInstead(new UnicodeString((UChar)0xfffc)); + * length=s->length(); // 1 + * // no need to explicitly delete the pointer + * \endcode + * + * @see LocalPointerBase + * @stable ICU 4.4 + */ +template<typename T> +class LocalPointer : public LocalPointerBase<T> { +public: + /** + * Constructor takes ownership. + * @param p simple pointer to an object that is adopted + * @stable ICU 4.4 + */ + explicit LocalPointer(T *p=NULL) : LocalPointerBase<T>(p) {} + /** + * Destructor deletes the object it owns. + * @stable ICU 4.4 + */ + ~LocalPointer() { + delete LocalPointerBase<T>::ptr; + } + /** + * Deletes the object it owns, + * and adopts (takes ownership of) the one passed in. + * @param p simple pointer to an object that is adopted + * @stable ICU 4.4 + */ + void adoptInstead(T *p) { + delete LocalPointerBase<T>::ptr; + LocalPointerBase<T>::ptr=p; + } +}; + +/** + * "Smart pointer" class, deletes objects via the C++ array delete[] operator. + * For most methods see the LocalPointerBase base class. + * Adds operator[] for array item access. + * + * Usage example: + * \code + * LocalArray<UnicodeString> a(new UnicodeString[2]); + * a[0].append((UChar)0x61); + * if(some condition) { return; } // no need to explicitly delete the array + * a.adoptInstead(new UnicodeString[4]); + * a[3].append((UChar)0x62).append((UChar)0x63).reverse(); + * // no need to explicitly delete the array + * \endcode + * + * @see LocalPointerBase + * @stable ICU 4.4 + */ +template<typename T> +class LocalArray : public LocalPointerBase<T> { +public: + /** + * Constructor takes ownership. + * @param p simple pointer to an array of T objects that is adopted + * @stable ICU 4.4 + */ + explicit LocalArray(T *p=NULL) : LocalPointerBase<T>(p) {} + /** + * Destructor deletes the array it owns. + * @stable ICU 4.4 + */ + ~LocalArray() { + delete[] LocalPointerBase<T>::ptr; + } + /** + * Deletes the array it owns, + * and adopts (takes ownership of) the one passed in. + * @param p simple pointer to an array of T objects that is adopted + * @stable ICU 4.4 + */ + void adoptInstead(T *p) { + delete[] LocalPointerBase<T>::ptr; + LocalPointerBase<T>::ptr=p; + } + /** + * Array item access (writable). + * No index bounds check. + * @param i array index + * @return reference to the array item + * @stable ICU 4.4 + */ + T &operator[](ptrdiff_t i) const { return LocalPointerBase<T>::ptr[i]; } +}; + +/** + * \def U_DEFINE_LOCAL_OPEN_POINTER + * "Smart pointer" definition macro, deletes objects via the closeFunction. + * Defines a subclass of LocalPointerBase which works just + * like LocalPointer<Type> except that this subclass will use the closeFunction + * rather than the C++ delete operator. + * + * Requirement: The closeFunction must tolerate a NULL pointer. + * (We could add a NULL check here but it is normally redundant.) + * + * Usage example: + * \code + * LocalUCaseMapPointer csm(ucasemap_open(localeID, options, &errorCode)); + * utf8OutLength=ucasemap_utf8ToLower(csm.getAlias(), + * utf8Out, (int32_t)sizeof(utf8Out), + * utf8In, utf8InLength, &errorCode); + * if(U_FAILURE(errorCode)) { return; } // no need to explicitly delete the UCaseMap + * \endcode + * + * @see LocalPointerBase + * @see LocalPointer + * @stable ICU 4.4 + */ +#define U_DEFINE_LOCAL_OPEN_POINTER(LocalPointerClassName, Type, closeFunction) \ + class LocalPointerClassName : public LocalPointerBase<Type> { \ + public: \ + explicit LocalPointerClassName(Type *p=NULL) : LocalPointerBase<Type>(p) {} \ + ~LocalPointerClassName() { closeFunction(ptr); } \ + void adoptInstead(Type *p) { \ + closeFunction(ptr); \ + ptr=p; \ + } \ + } + +U_NAMESPACE_END + +#endif /* U_SHOW_CPLUSPLUS_API */ +#endif /* __LOCALPOINTER_H__ */ diff --git a/Source/WTF/icu/unicode/parseerr.h b/Source/WTF/icu/unicode/parseerr.h index d1ba39486..44ff00811 100644 --- a/Source/WTF/icu/unicode/parseerr.h +++ b/Source/WTF/icu/unicode/parseerr.h @@ -1,6 +1,6 @@ /* ********************************************************************** -* Copyright (C) 1999-2004, International Business Machines +* Copyright (C) 1999-2005, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************** * Date Name Description @@ -15,6 +15,10 @@ /** + * \file + * \brief C API: Parse Error Information + */ +/** * The capacity of the context strings in UParseError. * @stable ICU 2.0 */ diff --git a/Source/WTF/icu/unicode/platform.h b/Source/WTF/icu/unicode/platform.h index 9595a268a..3de40d256 100644 --- a/Source/WTF/icu/unicode/platform.h +++ b/Source/WTF/icu/unicode/platform.h @@ -1,11 +1,15 @@ /* ****************************************************************************** * -* Copyright (C) 1997-2004, International Business Machines +* Copyright (C) 1997-2010, International Business Machines * Corporation and others. All Rights Reserved. * ****************************************************************************** * +* Note: autoconf creates platform.h from platform.h.in at configure time. +* +****************************************************************************** +* * FILE NAME : platform.h * * Date Name Description @@ -16,23 +20,56 @@ ****************************************************************************** */ -/* Define the platform we're on. */ +#ifndef _PLATFORM_H +#define _PLATFORM_H + +/** + * \file + * \brief Basic types for the platform + */ + +/* This file should be included before uvernum.h. */ +#if defined(UVERNUM_H) +# error Do not include unicode/uvernum.h before #including unicode/platform.h. Instead of unicode/uvernum.h, #include unicode/uversion.h +#endif + +/** + * Determine wheter to enable auto cleanup of libraries. + * @internal + */ +#ifndef UCLN_NO_AUTO_CLEANUP +#define UCLN_NO_AUTO_CLEANUP 1 +#endif + +/* Need platform.h when using CYGWINMSVC to get definitions above. Ignore everything else. */ +#ifndef CYGWINMSVC + +/** Define the platform we're on. */ #ifndef U_DARWIN #define U_DARWIN #endif -/* Define whether inttypes.h is available */ +/** + * \def U_HAVE_DIRENT_H + * Define whether dirent.h is available + * @internal + */ +#ifndef U_HAVE_DIRENT_H +#define U_HAVE_DIRENT_H 1 +#endif + +/** Define whether inttypes.h is available */ #ifndef U_HAVE_INTTYPES_H #define U_HAVE_INTTYPES_H 1 #endif -/* +/** * Define what support for C++ streams is available. - * If U_IOSTREAM_SOURCE is set to 199711, then <iostream> is available + * If U_IOSTREAM_SOURCE is set to 199711, then <iostream> is available * (1997711 is the date the ISO/IEC C++ FDIS was published), and then * one should qualify streams using the std namespace in ICU header * files. - * If U_IOSTREAM_SOURCE is set to 198506, then <iostream.h> is + * If U_IOSTREAM_SOURCE is set to 198506, then <iostream.h> is * available instead (198506 is the date when Stroustrup published * "An Extensible I/O Facility for C++" at the summer USENIX conference). * If U_IOSTREAM_SOURCE is 0, then C++ streams are not available and @@ -44,7 +81,19 @@ #define U_IOSTREAM_SOURCE 199711 #endif -/* Determines whether specific types are available */ +/** + * \def U_HAVE_STD_STRING + * Define whether the standard C++ (STL) <string> header is available. + * For platforms that do not use platform.h and do not define this constant + * in their platform-specific headers, std_string.h defaults + * U_HAVE_STD_STRING to 1. + * @internal + */ +#ifndef U_HAVE_STD_STRING +#define U_HAVE_STD_STRING 1 +#endif + +/** @{ Determines whether specific types are available */ #ifndef U_HAVE_INT8_T #define U_HAVE_INT8_T 1 #endif @@ -77,74 +126,10 @@ #define U_HAVE_UINT64_T 0 #endif -/*===========================================================================*/ -/* Generic data types */ -/*===========================================================================*/ - -#include <sys/types.h> - -/* If your platform does not have the <inttypes.h> header, you may - need to edit the typedefs below. */ -#if U_HAVE_INTTYPES_H - -/* autoconf 2.13 sometimes can't properly find the data types in <inttypes.h> */ -/* os/390 needs <inttypes.h>, but it doesn't have int8_t, and it sometimes */ -/* doesn't have uint8_t depending on the OS version. */ -/* So we have this work around. */ -#ifdef OS390 -/* The features header is needed to get (u)int64_t sometimes. */ -#include <features.h> -#if ! U_HAVE_INT8_T -typedef signed char int8_t; -#endif -#if !defined(__uint8_t) -#define __uint8_t 1 -typedef unsigned char uint8_t; -#endif -#endif /* OS390 */ - -#include <inttypes.h> - -#else /* U_HAVE_INTTYPES_H */ - -#if ! U_HAVE_INT8_T -typedef signed char int8_t; -#endif - -#if ! U_HAVE_UINT8_T -typedef unsigned char uint8_t; -#endif - -#if ! U_HAVE_INT16_T -typedef signed short int16_t; -#endif - -#if ! U_HAVE_UINT16_T -typedef unsigned short uint16_t; -#endif - -#if ! U_HAVE_INT32_T -typedef signed int int32_t; -#endif - -#if ! U_HAVE_UINT32_T -typedef unsigned int uint32_t; -#endif - -#if ! U_HAVE_INT64_T - typedef signed long long int64_t; -/* else we may not have a 64-bit type */ -#endif - -#if ! U_HAVE_UINT64_T - typedef unsigned long long uint64_t; -/* else we may not have a 64-bit type */ -#endif - -#endif +/** @} */ /*===========================================================================*/ -/* Compiler and environment features */ +/** @{ Compiler and environment features */ /*===========================================================================*/ /* Define whether namespace is supported */ @@ -162,7 +147,14 @@ typedef unsigned int uint32_t; #endif /* 1 or 0 to enable or disable threads. If undefined, default is: enable threads. */ +#ifndef ICU_USE_THREADS #define ICU_USE_THREADS 1 +#endif + +/* On strong memory model CPUs (e.g. x86 CPUs), we use a safe & quick double check lock. */ +#if defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__)) +#define UMTX_STRONG_MEMORY_MODEL 1 +#endif #ifndef U_DEBUG #define U_DEBUG 0 @@ -192,41 +184,106 @@ typedef unsigned int uint32_t; #define U_ENABLE_TRACING 1 #endif -/* Define the library suffix in a C syntax. */ -#define U_HAVE_LIB_SUFFIX 0 -#define U_LIB_SUFFIX_C_NAME -#define U_LIB_SUFFIX_C_NAME_STRING "" +/** + * Whether to enable Dynamic loading in ICU + * @internal + */ +#ifndef U_ENABLE_DYLOAD +#define U_ENABLE_DYLOAD 1 +#endif + +/** + * Whether to test Dynamic loading as an OS capabilty + * @internal + */ +#ifndef U_CHECK_DYLOAD +#define U_CHECK_DYLOAD 1 +#endif + + +/** Do we allow ICU users to use the draft APIs by default? */ +#ifndef U_DEFAULT_SHOW_DRAFT +#define U_DEFAULT_SHOW_DRAFT 1 +#endif + +/** @} */ /*===========================================================================*/ -/* Character data types */ +/** @{ Character data types */ /*===========================================================================*/ -#if defined(OS390) || defined(OS400) +#if ((defined(OS390) && (!defined(__CHARSET_LIB) || !__CHARSET_LIB))) || defined(OS400) # define U_CHARSET_FAMILY 1 #endif +/** @} */ + /*===========================================================================*/ -/* Information about wchar support */ +/** @{ Information about wchar support */ /*===========================================================================*/ +#ifndef U_HAVE_WCHAR_H #define U_HAVE_WCHAR_H 1 +#endif + +#ifndef U_SIZEOF_WCHAR_T #define U_SIZEOF_WCHAR_T 4 +#endif +#ifndef U_HAVE_WCSCPY #define U_HAVE_WCSCPY 1 +#endif + +/** @} */ + +/** + * @{ + * \def U_DECLARE_UTF16 + * Do not use this macro. Use the UNICODE_STRING or U_STRING_DECL macros + * instead. + * @internal + * + * \def U_GNUC_UTF16_STRING + * @internal + */ +#ifndef U_GNUC_UTF16_STRING +#define U_GNUC_UTF16_STRING 0 +#endif +#if 1 || defined(U_CHECK_UTF16_STRING) +#if (defined(__xlC__) && defined(__IBM_UTF_LITERAL) && U_SIZEOF_WCHAR_T != 2) \ + || (defined(__HP_aCC) && __HP_aCC >= 035000) \ + || (defined(__HP_cc) && __HP_cc >= 111106) \ + || U_GNUC_UTF16_STRING +#define U_DECLARE_UTF16(string) u ## string +#elif (defined(__SUNPRO_CC) && __SUNPRO_CC >= 0x550) +/* || (defined(__SUNPRO_C) && __SUNPRO_C >= 0x580) */ +/* Sun's C compiler has issues with this notation, and it's unreliable. */ +#define U_DECLARE_UTF16(string) U ## string +#elif U_SIZEOF_WCHAR_T == 2 \ + && (U_CHARSET_FAMILY == 0 || ((defined(OS390) || defined(OS400)) && defined(__UCS2__))) +#define U_DECLARE_UTF16(string) L ## string +#endif +#endif + +/** @} */ /*===========================================================================*/ -/* Information about POSIX support */ +/** @{ Information about POSIX support */ /*===========================================================================*/ -#define U_HAVE_NL_LANGINFO 1 +#ifndef U_HAVE_NL_LANGINFO_CODESET #define U_HAVE_NL_LANGINFO_CODESET 1 +#endif + +#ifndef U_NL_LANGINFO_CODESET #define U_NL_LANGINFO_CODESET CODESET +#endif #if 1 #define U_TZSET tzset #endif #if 0 -#define U_TIMEZONE +#define U_TIMEZONE timezone #endif #if 1 #define U_TZNAME tzname @@ -235,33 +292,110 @@ typedef unsigned int uint32_t; #define U_HAVE_MMAP 1 #define U_HAVE_POPEN 1 +/** @} */ + /*===========================================================================*/ -/* Symbol import-export control */ +/** @{ Symbol import-export control */ /*===========================================================================*/ +#if 1 +#define U_EXPORT __attribute__((visibility("default"))) +#elif (defined(__SUNPRO_CC) && __SUNPRO_CC >= 0x550) \ + || (defined(__SUNPRO_C) && __SUNPRO_C >= 0x550) +#define U_EXPORT __global +/*#elif defined(__HP_aCC) || defined(__HP_cc) +#define U_EXPORT __declspec(dllexport)*/ +#else #define U_EXPORT +#endif + /* U_CALLCONV is releated to U_EXPORT2 */ #define U_EXPORT2 /* cygwin needs to export/import data */ -#ifdef U_CYGWIN +#if defined(U_CYGWIN) && !defined(__GNUC__) #define U_IMPORT __declspec(dllimport) #else #define U_IMPORT #endif +/* @} */ + /*===========================================================================*/ -/* Code alignment and C function inlining */ +/** @{ Code alignment and C function inlining */ /*===========================================================================*/ #ifndef U_INLINE -#define U_INLINE inline +# ifdef __cplusplus +# define U_INLINE inline +# else +# define U_INLINE __inline__ +# endif #endif +#ifndef U_ALIGN_CODE #define U_ALIGN_CODE(n) +#endif + +/** @} */ /*===========================================================================*/ -/* Programs used by ICU code */ +/** @{ GCC built in functions for atomic memory operations */ /*===========================================================================*/ +/** + * \def U_HAVE_GCC_ATOMICS + * @internal + */ +#ifndef U_HAVE_GCC_ATOMICS +#define U_HAVE_GCC_ATOMICS 1 +#endif + +/** @} */ + +/*===========================================================================*/ +/** @{ Programs used by ICU code */ +/*===========================================================================*/ + +/** + * \def U_MAKE + * What program to execute to run 'make' + */ +#ifndef U_MAKE #define U_MAKE "/usr/bin/gnumake" +#endif + +/** @} */ + +#endif /* CYGWINMSVC */ + +/*===========================================================================*/ +/* Custom icu entry point renaming */ +/*===========================================================================*/ + +/** + * Define the library suffix with C syntax. + * @internal + */ +# define U_LIB_SUFFIX_C_NAME +/** + * Define the library suffix as a string with C syntax + * @internal + */ +# define U_LIB_SUFFIX_C_NAME_STRING "" +/** + * 1 if a custom library suffix is set + * @internal + */ +# define U_HAVE_LIB_SUFFIX 0 + +#if U_HAVE_LIB_SUFFIX +# ifndef U_ICU_ENTRY_POINT_RENAME +/* Renaming pattern: u_strcpy_41_suffix */ +# define U_ICU_ENTRY_POINT_RENAME(x) x ## _ ## 46 ## +# define U_DEF_ICUDATA_ENTRY_POINT(major, minor) icudt####major##minor##_dat + +# endif +#endif + +#endif diff --git a/Source/WTF/icu/unicode/ptypes.h b/Source/WTF/icu/unicode/ptypes.h new file mode 100644 index 000000000..1f34d2f84 --- /dev/null +++ b/Source/WTF/icu/unicode/ptypes.h @@ -0,0 +1,92 @@ +/* +****************************************************************************** +* +* Copyright (C) 1997-2010, International Business Machines +* Corporation and others. All Rights Reserved. +* +****************************************************************************** +* +* FILE NAME : ptypes.h +* +* Date Name Description +* 05/13/98 nos Creation (content moved here from ptypes.h). +* 03/02/99 stephen Added AS400 support. +* 03/30/99 stephen Added Linux support. +* 04/13/99 stephen Reworked for autoconf. +* 09/18/08 srl Moved basic types back to ptypes.h from platform.h +****************************************************************************** +*/ + +#ifndef _PTYPES_H +#define _PTYPES_H + +#include <sys/types.h> + +#include "unicode/platform.h" + +/*===========================================================================*/ +/* Generic data types */ +/*===========================================================================*/ + +/* If your platform does not have the <inttypes.h> header, you may + need to edit the typedefs below. */ +#if U_HAVE_INTTYPES_H + +/* autoconf 2.13 sometimes can't properly find the data types in <inttypes.h> */ +/* os/390 needs <inttypes.h>, but it doesn't have int8_t, and it sometimes */ +/* doesn't have uint8_t depending on the OS version. */ +/* So we have this work around. */ +#ifdef OS390 +/* The features header is needed to get (u)int64_t sometimes. */ +#include <features.h> +#if ! U_HAVE_INT8_T +typedef signed char int8_t; +#endif +#if !defined(__uint8_t) +#define __uint8_t 1 +typedef unsigned char uint8_t; +#endif +#endif /* OS390 */ + +#include <inttypes.h> + +#else /* U_HAVE_INTTYPES_H */ + +#if ! U_HAVE_INT8_T +typedef signed char int8_t; +#endif + +#if ! U_HAVE_UINT8_T +typedef unsigned char uint8_t; +#endif + +#if ! U_HAVE_INT16_T +typedef signed short int16_t; +#endif + +#if ! U_HAVE_UINT16_T +typedef unsigned short uint16_t; +#endif + +#if ! U_HAVE_INT32_T +typedef signed int int32_t; +#endif + +#if ! U_HAVE_UINT32_T +typedef unsigned int uint32_t; +#endif + +#if ! U_HAVE_INT64_T + typedef signed long long int64_t; +/* else we may not have a 64-bit type */ +#endif + +#if ! U_HAVE_UINT64_T + typedef unsigned long long uint64_t; +/* else we may not have a 64-bit type */ +#endif + +#endif /* U_HAVE_INTTYPES_H */ + +#endif /* _PTYPES_H */ + diff --git a/Source/WTF/icu/unicode/putil.h b/Source/WTF/icu/unicode/putil.h index 685df530e..71d5d2643 100644 --- a/Source/WTF/icu/unicode/putil.h +++ b/Source/WTF/icu/unicode/putil.h @@ -1,7 +1,7 @@ /* ****************************************************************************** * -* Copyright (C) 1997-2004, International Business Machines +* Copyright (C) 1997-2009, International Business Machines * Corporation and others. All Rights Reserved. * ****************************************************************************** @@ -25,8 +25,12 @@ #define PUTIL_H #include "unicode/utypes.h" + /** + * \file + * \brief C API: Platform Utilities + */ -/* Define this to 1 if your platform supports IEEE 754 floating point, +/** Define this to 1 if your platform supports IEEE 754 floating point, to 0 if it does not. */ #ifndef IEEE_754 # define IEEE_754 1 @@ -54,7 +58,11 @@ * If u_setDataDirectory() has been called, that is it, otherwise * if the ICU_DATA environment variable is set, use that, otherwise * If a data directory was specifed at ICU build time - * (#define ICU_DATA_DIR "path"), use that, + * <code> + * \code + * #define ICU_DATA_DIR "path" + * \endcode + * </code> use that, * otherwise no data directory is available. * * @return the data directory, or an empty string ("") if no data directory has @@ -85,6 +93,7 @@ U_STABLE const char* U_EXPORT2 u_getDataDirectory(void); */ U_STABLE void U_EXPORT2 u_setDataDirectory(const char *directory); +#if !U_CHARSET_IS_UTF8 /** * Please use ucnv_getDefaultName() instead. * Return the default codepage for this platform and locale. @@ -94,6 +103,7 @@ U_STABLE void U_EXPORT2 u_setDataDirectory(const char *directory); * @internal */ U_INTERNAL const char* U_EXPORT2 uprv_getDefaultCodepage(void); +#endif /** * Please use uloc_getDefault() instead. @@ -107,6 +117,7 @@ U_INTERNAL const char* U_EXPORT2 uprv_getDefaultCodepage(void); U_INTERNAL const char* U_EXPORT2 uprv_getDefaultLocaleID(void); /** + * @{ * Filesystem file and path separator characters. * Example: '/' and ':' on Unix, '\\' and ';' on Windows. * @stable ICU 2.0 @@ -134,6 +145,8 @@ U_INTERNAL const char* U_EXPORT2 uprv_getDefaultLocaleID(void); # define U_PATH_SEP_STRING ":" #endif +/** @} */ + /** * Convert char characters to UChar characters. * This utility function is useful only for "invariant characters" diff --git a/Source/WTF/icu/unicode/rep.h b/Source/WTF/icu/unicode/rep.h new file mode 100644 index 000000000..3fab6fa12 --- /dev/null +++ b/Source/WTF/icu/unicode/rep.h @@ -0,0 +1,259 @@ +/* +************************************************************************** +* Copyright (C) 1999-2005, International Business Machines Corporation and +* others. All Rights Reserved. +************************************************************************** +* Date Name Description +* 11/17/99 aliu Creation. Ported from java. Modified to +* match current UnicodeString API. Forced +* to use name "handleReplaceBetween" because +* of existing methods in UnicodeString. +************************************************************************** +*/ + +#ifndef REP_H +#define REP_H + +#include "unicode/uobject.h" + +/** + * \file + * \brief C++ API: Replaceable String + */ + +U_NAMESPACE_BEGIN + +class UnicodeString; + +/** + * <code>Replaceable</code> is an abstract base class representing a + * string of characters that supports the replacement of a range of + * itself with a new string of characters. It is used by APIs that + * change a piece of text while retaining metadata. Metadata is data + * other than the Unicode characters returned by char32At(). One + * example of metadata is style attributes; another is an edit + * history, marking each character with an author and revision number. + * + * <p>An implicit aspect of the <code>Replaceable</code> API is that + * during a replace operation, new characters take on the metadata of + * the old characters. For example, if the string "the <b>bold</b> + * font" has range (4, 8) replaced with "strong", then it becomes "the + * <b>strong</b> font". + * + * <p><code>Replaceable</code> specifies ranges using a start + * offset and a limit offset. The range of characters thus specified + * includes the characters at offset start..limit-1. That is, the + * start offset is inclusive, and the limit offset is exclusive. + * + * <p><code>Replaceable</code> also includes API to access characters + * in the string: <code>length()</code>, <code>charAt()</code>, + * <code>char32At()</code>, and <code>extractBetween()</code>. + * + * <p>For a subclass to support metadata, typical behavior of + * <code>replace()</code> is the following: + * <ul> + * <li>Set the metadata of the new text to the metadata of the first + * character replaced</li> + * <li>If no characters are replaced, use the metadata of the + * previous character</li> + * <li>If there is no previous character (i.e. start == 0), use the + * following character</li> + * <li>If there is no following character (i.e. the replaceable was + * empty), use default metadata.<br> + * <li>If the code point U+FFFF is seen, it should be interpreted as + * a special marker having no metadata<li> + * </li> + * </ul> + * If this is not the behavior, the subclass should document any differences. + * @author Alan Liu + * @stable ICU 2.0 + */ +class U_COMMON_API Replaceable : public UObject { + +public: + /** + * Destructor. + * @stable ICU 2.0 + */ + virtual ~Replaceable(); + + /** + * Returns the number of 16-bit code units in the text. + * @return number of 16-bit code units in text + * @stable ICU 1.8 + */ + inline int32_t length() const; + + /** + * Returns the 16-bit code unit at the given offset into the text. + * @param offset an integer between 0 and <code>length()</code>-1 + * inclusive + * @return 16-bit code unit of text at given offset + * @stable ICU 1.8 + */ + inline UChar charAt(int32_t offset) const; + + /** + * Returns the 32-bit code point at the given 16-bit offset into + * the text. This assumes the text is stored as 16-bit code units + * with surrogate pairs intermixed. If the offset of a leading or + * trailing code unit of a surrogate pair is given, return the + * code point of the surrogate pair. + * + * @param offset an integer between 0 and <code>length()</code>-1 + * inclusive + * @return 32-bit code point of text at given offset + * @stable ICU 1.8 + */ + inline UChar32 char32At(int32_t offset) const; + + /** + * Copies characters in the range [<tt>start</tt>, <tt>limit</tt>) + * into the UnicodeString <tt>target</tt>. + * @param start offset of first character which will be copied + * @param limit offset immediately following the last character to + * be copied + * @param target UnicodeString into which to copy characters. + * @return A reference to <TT>target</TT> + * @stable ICU 2.1 + */ + virtual void extractBetween(int32_t start, + int32_t limit, + UnicodeString& target) const = 0; + + /** + * Replaces a substring of this object with the given text. If the + * characters being replaced have metadata, the new characters + * that replace them should be given the same metadata. + * + * <p>Subclasses must ensure that if the text between start and + * limit is equal to the replacement text, that replace has no + * effect. That is, any metadata + * should be unaffected. In addition, subclasses are encouraged to + * check for initial and trailing identical characters, and make a + * smaller replacement if possible. This will preserve as much + * metadata as possible. + * @param start the beginning index, inclusive; <code>0 <= start + * <= limit</code>. + * @param limit the ending index, exclusive; <code>start <= limit + * <= length()</code>. + * @param text the text to replace characters <code>start</code> + * to <code>limit - 1</code> + * @stable ICU 2.0 + */ + virtual void handleReplaceBetween(int32_t start, + int32_t limit, + const UnicodeString& text) = 0; + // Note: All other methods in this class take the names of + // existing UnicodeString methods. This method is the exception. + // It is named differently because all replace methods of + // UnicodeString return a UnicodeString&. The 'between' is + // required in order to conform to the UnicodeString naming + // convention; API taking start/length are named <operation>, and + // those taking start/limit are named <operationBetween>. The + // 'handle' is added because 'replaceBetween' and + // 'doReplaceBetween' are already taken. + + /** + * Copies a substring of this object, retaining metadata. + * This method is used to duplicate or reorder substrings. + * The destination index must not overlap the source range. + * + * @param start the beginning index, inclusive; <code>0 <= start <= + * limit</code>. + * @param limit the ending index, exclusive; <code>start <= limit <= + * length()</code>. + * @param dest the destination index. The characters from + * <code>start..limit-1</code> will be copied to <code>dest</code>. + * Implementations of this method may assume that <code>dest <= start || + * dest >= limit</code>. + * @stable ICU 2.0 + */ + virtual void copy(int32_t start, int32_t limit, int32_t dest) = 0; + + /** + * Returns true if this object contains metadata. If a + * Replaceable object has metadata, calls to the Replaceable API + * must be made so as to preserve metadata. If it does not, calls + * to the Replaceable API may be optimized to improve performance. + * The default implementation returns true. + * @return true if this object contains metadata + * @stable ICU 2.2 + */ + virtual UBool hasMetaData() const; + + /** + * Clone this object, an instance of a subclass of Replaceable. + * Clones can be used concurrently in multiple threads. + * If a subclass does not implement clone(), or if an error occurs, + * then NULL is returned. + * The clone functions in all subclasses return a pointer to a Replaceable + * because some compilers do not support covariant (same-as-this) + * return types; cast to the appropriate subclass if necessary. + * The caller must delete the clone. + * + * @return a clone of this object + * + * @see getDynamicClassID + * @stable ICU 2.6 + */ + virtual Replaceable *clone() const; + +protected: + + /** + * Default constructor. + * @stable ICU 2.4 + */ + Replaceable(); + + /* + * Assignment operator not declared. The compiler will provide one + * which does nothing since this class does not contain any data members. + * API/code coverage may show the assignment operator as present and + * untested - ignore. + * Subclasses need this assignment operator if they use compiler-provided + * assignment operators of their own. An alternative to not declaring one + * here would be to declare and empty-implement a protected or public one. + Replaceable &Replaceable::operator=(const Replaceable &); + */ + + /** + * Virtual version of length(). + * @stable ICU 2.4 + */ + virtual int32_t getLength() const = 0; + + /** + * Virtual version of charAt(). + * @stable ICU 2.4 + */ + virtual UChar getCharAt(int32_t offset) const = 0; + + /** + * Virtual version of char32At(). + * @stable ICU 2.4 + */ + virtual UChar32 getChar32At(int32_t offset) const = 0; +}; + +inline int32_t +Replaceable::length() const { + return getLength(); +} + +inline UChar +Replaceable::charAt(int32_t offset) const { + return getCharAt(offset); +} + +inline UChar32 +Replaceable::char32At(int32_t offset) const { + return getChar32At(offset); +} + +// There is no rep.cpp, see unistr.cpp for Replaceable function implementations. + +U_NAMESPACE_END + +#endif diff --git a/Source/WTF/icu/unicode/std_string.h b/Source/WTF/icu/unicode/std_string.h new file mode 100644 index 000000000..dd43b745a --- /dev/null +++ b/Source/WTF/icu/unicode/std_string.h @@ -0,0 +1,78 @@ +/* +******************************************************************************* +* +* Copyright (C) 2009-2010, International Business Machines +* Corporation and others. All Rights Reserved. +* +******************************************************************************* +* file name: std_string.h +* encoding: US-ASCII +* tab size: 8 (not used) +* indentation:4 +* +* created on: 2009feb19 +* created by: Markus W. Scherer +*/ + +#ifndef __STD_STRING_H__ +#define __STD_STRING_H__ + +/** + * \file + * \brief C++ API: Central ICU header for including the C++ standard <string> + * header and for related definitions. + */ + +#include "unicode/utypes.h" + +/** + * \def U_HAVE_STD_STRING + * Define whether the standard C++ (STL) <string> header is available. + * @internal + */ +#ifndef U_HAVE_STD_STRING +#define U_HAVE_STD_STRING 1 +#endif + +#if U_HAVE_STD_STRING + +#include <string> + +/** + * \def U_STD_NS + * Define the namespace to use for standard C++ (STL) classes. + * Either std or empty. + * @draft ICU 4.2 + */ + +/** + * \def U_STD_NSQ + * Define the namespace qualifier to use for standard C++ (STL) classes. + * Either std:: or empty. + * For example, + * U_STD_NSQ string StringFromUnicodeString(const UnicodeString &unistr); + * @draft ICU 4.2 + */ + +/** + * \def U_STD_NS_USE + * This is used to specify that the rest of the code uses the + * standard (STL) namespace. + * Either "using namespace std;" or empty. + * @draft ICU 4.2 + */ +#ifndef U_STD_NSQ +# if U_HAVE_NAMESPACE +# define U_STD_NS std +# define U_STD_NSQ U_STD_NS:: +# define U_STD_NS_USE using namespace U_STD_NS; +# else +# define U_STD_NS +# define U_STD_NSQ +# define U_STD_NS_USE +# endif +#endif + +#endif // U_HAVE_STD_STRING + +#endif // __STD_STRING_H__ diff --git a/Source/WTF/icu/unicode/strenum.h b/Source/WTF/icu/unicode/strenum.h new file mode 100644 index 000000000..ce42195a4 --- /dev/null +++ b/Source/WTF/icu/unicode/strenum.h @@ -0,0 +1,271 @@ +/* +******************************************************************************* +* +* Copyright (C) 2002-2007, International Business Machines +* Corporation and others. All Rights Reserved. +* +******************************************************************************* +*/ + +#ifndef STRENUM_H +#define STRENUM_H + +#include "unicode/uobject.h" +#include "unicode/unistr.h" + +/** + * \file + * \brief C++ API: String Enumeration + */ + +U_NAMESPACE_BEGIN + +/** + * Base class for 'pure' C++ implementations of uenum api. Adds a + * method that returns the next UnicodeString since in C++ this can + * be a common storage format for strings. + * + * <p>The model is that the enumeration is over strings maintained by + * a 'service.' At any point, the service might change, invalidating + * the enumerator (though this is expected to be rare). The iterator + * returns an error if this has occurred. Lack of the error is no + * guarantee that the service didn't change immediately after the + * call, so the returned string still might not be 'valid' on + * subsequent use.</p> + * + * <p>Strings may take the form of const char*, const UChar*, or const + * UnicodeString*. The type you get is determine by the variant of + * 'next' that you call. In general the StringEnumeration is + * optimized for one of these types, but all StringEnumerations can + * return all types. Returned strings are each terminated with a NUL. + * Depending on the service data, they might also include embedded NUL + * characters, so API is provided to optionally return the true + * length, counting the embedded NULs but not counting the terminating + * NUL.</p> + * + * <p>The pointers returned by next, unext, and snext become invalid + * upon any subsequent call to the enumeration's destructor, next, + * unext, snext, or reset.</p> + * + * ICU 2.8 adds some default implementations and helper functions + * for subclasses. + * + * @stable ICU 2.4 + */ +class U_COMMON_API StringEnumeration : public UObject { +public: + /** + * Destructor. + * @stable ICU 2.4 + */ + virtual ~StringEnumeration(); + + /** + * Clone this object, an instance of a subclass of StringEnumeration. + * Clones can be used concurrently in multiple threads. + * If a subclass does not implement clone(), or if an error occurs, + * then NULL is returned. + * The clone functions in all subclasses return a base class pointer + * because some compilers do not support covariant (same-as-this) + * return types; cast to the appropriate subclass if necessary. + * The caller must delete the clone. + * + * @return a clone of this object + * + * @see getDynamicClassID + * @stable ICU 2.8 + */ + virtual StringEnumeration *clone() const; + + /** + * <p>Return the number of elements that the iterator traverses. If + * the iterator is out of sync with its service, status is set to + * U_ENUM_OUT_OF_SYNC_ERROR, and the return value is zero.</p> + * + * <p>The return value will not change except possibly as a result of + * a subsequent call to reset, or if the iterator becomes out of sync.</p> + * + * <p>This is a convenience function. It can end up being very + * expensive as all the items might have to be pre-fetched + * (depending on the storage format of the data being + * traversed).</p> + * + * @param status the error code. + * @return number of elements in the iterator. + * + * @stable ICU 2.4 */ + virtual int32_t count(UErrorCode& status) const = 0; + + /** + * <p>Returns the next element as a NUL-terminated char*. If there + * are no more elements, returns NULL. If the resultLength pointer + * is not NULL, the length of the string (not counting the + * terminating NUL) is returned at that address. If an error + * status is returned, the value at resultLength is undefined.</p> + * + * <p>The returned pointer is owned by this iterator and must not be + * deleted by the caller. The pointer is valid until the next call + * to next, unext, snext, reset, or the enumerator's destructor.</p> + * + * <p>If the iterator is out of sync with its service, status is set + * to U_ENUM_OUT_OF_SYNC_ERROR and NULL is returned.</p> + * + * <p>If the native service string is a UChar* string, it is + * converted to char* with the invariant converter. If the + * conversion fails (because a character cannot be converted) then + * status is set to U_INVARIANT_CONVERSION_ERROR and the return + * value is undefined (though not NULL).</p> + * + * Starting with ICU 2.8, the default implementation calls snext() + * and handles the conversion. + * + * @param status the error code. + * @param resultLength a pointer to receive the length, can be NULL. + * @return a pointer to the string, or NULL. + * + * @stable ICU 2.4 + */ + virtual const char* next(int32_t *resultLength, UErrorCode& status); + + /** + * <p>Returns the next element as a NUL-terminated UChar*. If there + * are no more elements, returns NULL. If the resultLength pointer + * is not NULL, the length of the string (not counting the + * terminating NUL) is returned at that address. If an error + * status is returned, the value at resultLength is undefined.</p> + * + * <p>The returned pointer is owned by this iterator and must not be + * deleted by the caller. The pointer is valid until the next call + * to next, unext, snext, reset, or the enumerator's destructor.</p> + * + * <p>If the iterator is out of sync with its service, status is set + * to U_ENUM_OUT_OF_SYNC_ERROR and NULL is returned.</p> + * + * Starting with ICU 2.8, the default implementation calls snext() + * and handles the conversion. + * + * @param status the error code. + * @param resultLength a ponter to receive the length, can be NULL. + * @return a pointer to the string, or NULL. + * + * @stable ICU 2.4 + */ + virtual const UChar* unext(int32_t *resultLength, UErrorCode& status); + + /** + * <p>Returns the next element a UnicodeString*. If there are no + * more elements, returns NULL.</p> + * + * <p>The returned pointer is owned by this iterator and must not be + * deleted by the caller. The pointer is valid until the next call + * to next, unext, snext, reset, or the enumerator's destructor.</p> + * + * <p>If the iterator is out of sync with its service, status is set + * to U_ENUM_OUT_OF_SYNC_ERROR and NULL is returned.</p> + * + * @param status the error code. + * @return a pointer to the string, or NULL. + * + * @stable ICU 2.4 + */ + virtual const UnicodeString* snext(UErrorCode& status) = 0; + + /** + * <p>Resets the iterator. This re-establishes sync with the + * service and rewinds the iterator to start at the first + * element.</p> + * + * <p>Previous pointers returned by next, unext, or snext become + * invalid, and the value returned by count might change.</p> + * + * @param status the error code. + * + * @stable ICU 2.4 + */ + virtual void reset(UErrorCode& status) = 0; + + /** + * Compares this enumeration to other to check if both are equal + * + * @param that The other string enumeration to compare this object to + * @return TRUE if the enumerations are equal. FALSE if not. + * @stable ICU 3.6 + */ + virtual UBool operator==(const StringEnumeration& that)const; + /** + * Compares this enumeration to other to check if both are not equal + * + * @param that The other string enumeration to compare this object to + * @return TRUE if the enumerations are equal. FALSE if not. + * @stable ICU 3.6 + */ + virtual UBool operator!=(const StringEnumeration& that)const; + +protected: + /** + * UnicodeString field for use with default implementations and subclasses. + * @stable ICU 2.8 + */ + UnicodeString unistr; + /** + * char * default buffer for use with default implementations and subclasses. + * @stable ICU 2.8 + */ + char charsBuffer[32]; + /** + * char * buffer for use with default implementations and subclasses. + * Allocated in constructor and in ensureCharsCapacity(). + * @stable ICU 2.8 + */ + char *chars; + /** + * Capacity of chars, for use with default implementations and subclasses. + * @stable ICU 2.8 + */ + int32_t charsCapacity; + + /** + * Default constructor for use with default implementations and subclasses. + * @stable ICU 2.8 + */ + StringEnumeration(); + + /** + * Ensures that chars is at least as large as the requested capacity. + * For use with default implementations and subclasses. + * + * @param capacity Requested capacity. + * @param status ICU in/out error code. + * @stable ICU 2.8 + */ + void ensureCharsCapacity(int32_t capacity, UErrorCode &status); + + /** + * Converts s to Unicode and sets unistr to the result. + * For use with default implementations and subclasses, + * especially for implementations of snext() in terms of next(). + * This is provided with a helper function instead of a default implementation + * of snext() to avoid potential infinite loops between next() and snext(). + * + * For example: + * \code + * const UnicodeString* snext(UErrorCode& status) { + * int32_t resultLength=0; + * const char *s=next(&resultLength, status); + * return setChars(s, resultLength, status); + * } + * \endcode + * + * @param s String to be converted to Unicode. + * @param length Length of the string. + * @param status ICU in/out error code. + * @return A pointer to unistr. + * @stable ICU 2.8 + */ + UnicodeString *setChars(const char *s, int32_t length, UErrorCode &status); +}; + +U_NAMESPACE_END + +/* STRENUM_H */ +#endif diff --git a/Source/WTF/icu/unicode/stringpiece.h b/Source/WTF/icu/unicode/stringpiece.h new file mode 100644 index 000000000..79d5a050e --- /dev/null +++ b/Source/WTF/icu/unicode/stringpiece.h @@ -0,0 +1,224 @@ +// Copyright (C) 2010, International Business Machines +// Corporation and others. All Rights Reserved. +// +// Copyright 2001 and onwards Google Inc. +// Author: Sanjay Ghemawat + +// 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 guidelines. +// For example, data types are ICU-ified (size_t,int->int32_t), +// and API comments doxygen-ified, but function names and behavior are +// as in the original, if possible. +// Assertion-style error handling, not available in ICU, was changed to +// parameter "pinning" similar to UnicodeString. +// +// In addition, this is only a partial port of the original Google code, +// limited to what was needed so far. The (nearly) complete original code +// is in the ICU svn repository at icuhtml/trunk/design/strings/contrib +// (see ICU ticket 6765, r25517). + +#ifndef __STRINGPIECE_H__ +#define __STRINGPIECE_H__ + +/** + * \file + * \brief C++ API: StringPiece: Read-only byte string wrapper class. + */ + +#include "unicode/utypes.h" +#include "unicode/uobject.h" +#include "unicode/std_string.h" + +// Arghh! I wish C++ literals were "string". + +U_NAMESPACE_BEGIN + +/** + * A string-like object that points to a sized piece of memory. + * + * We provide non-explicit singleton constructors so users can pass + * in a "const char*" or a "string" wherever a "StringPiece" is + * expected. + * + * Functions or methods may use const StringPiece& parameters to accept either + * a "const char*" or a "string" value that will be implicitly converted to + * a StringPiece. + * + * Systematic usage of StringPiece is encouraged as it will reduce unnecessary + * conversions from "const char*" to "string" and back again. + * + * @stable ICU 4.2 + */ +class U_COMMON_API StringPiece : public UMemory { + private: + const char* ptr_; + int32_t length_; + + public: + /** + * Default constructor, creates an empty StringPiece. + * @stable ICU 4.2 + */ + StringPiece() : ptr_(NULL), length_(0) { } + /** + * Constructs from a NUL-terminated const char * pointer. + * @param str a NUL-terminated const char * pointer + * @stable ICU 4.2 + */ + StringPiece(const char* str); +#if U_HAVE_STD_STRING + /** + * Constructs from a std::string. + * @stable ICU 4.2 + */ + StringPiece(const U_STD_NSQ string& str) + : ptr_(str.data()), length_(static_cast<int32_t>(str.size())) { } +#endif + /** + * Constructs from a const char * pointer and a specified length. + * @param offset a const char * pointer (need not be terminated) + * @param len the length of the string; must be non-negative + * @stable ICU 4.2 + */ + StringPiece(const char* offset, int32_t len) : ptr_(offset), length_(len) { } + /** + * Substring of another StringPiece. + * @param x the other StringPiece + * @param pos start position in x; must be non-negative and <= x.length(). + * @stable ICU 4.2 + */ + StringPiece(const StringPiece& x, int32_t pos); + /** + * Substring of another StringPiece. + * @param x the other StringPiece + * @param pos start position in x; must be non-negative and <= x.length(). + * @param len length of the substring; + * must be non-negative and will be pinned to at most x.length() - pos. + * @stable ICU 4.2 + */ + StringPiece(const StringPiece& x, int32_t pos, int32_t len); + + /** + * Returns the string pointer. May be NULL if it is empty. + * + * data() may return a pointer to a buffer with embedded NULs, and the + * returned buffer may or may not be null terminated. Therefore it is + * typically a mistake to pass data() to a routine that expects a NUL + * terminated string. + * @return the string pointer + * @stable ICU 4.2 + */ + const char* data() const { return ptr_; } + /** + * Returns the string length. Same as length(). + * @return the string length + * @stable ICU 4.2 + */ + int32_t size() const { return length_; } + /** + * Returns the string length. Same as size(). + * @return the string length + * @stable ICU 4.2 + */ + int32_t length() const { return length_; } + /** + * Returns whether the string is empty. + * @return TRUE if the string is empty + * @stable ICU 4.2 + */ + UBool empty() const { return length_ == 0; } + + /** + * Sets to an empty string. + * @stable ICU 4.2 + */ + void clear() { ptr_ = NULL; length_ = 0; } + + /** + * Reset the stringpiece to refer to new data. + * @param data pointer the new string data. Need not be nul terminated. + * @param len the length of the new data + * @internal + */ + void set(const char* data, int32_t len) { ptr_ = data; length_ = len; } + + /** + * Reset the stringpiece to refer to new data. + * @param str a pointer to a NUL-terminated string. + * @internal + */ + void set(const char* str); + + /** + * Removes the first n string units. + * @param n prefix length, must be non-negative and <=length() + * @stable ICU 4.2 + */ + void remove_prefix(int32_t n) { + if (n >= 0) { + if (n > length_) { + n = length_; + } + ptr_ += n; + length_ -= n; + } + } + + /** + * Removes the last n string units. + * @param n suffix length, must be non-negative and <=length() + * @stable ICU 4.2 + */ + void remove_suffix(int32_t n) { + if (n >= 0) { + if (n <= length_) { + length_ -= n; + } else { + length_ = 0; + } + } + } + + /** + * Maximum integer, used as a default value for substring methods. + * @stable ICU 4.2 + */ + static const int32_t npos = 0x7fffffff; + + /** + * Returns a substring of this StringPiece. + * @param pos start position; must be non-negative and <= length(). + * @param len length of the substring; + * must be non-negative and will be pinned to at most length() - pos. + * @return the substring StringPiece + * @stable ICU 4.2 + */ + StringPiece substr(int32_t pos, int32_t len = npos) const { + return StringPiece(*this, pos, len); + } +}; + +/** + * Global operator == for StringPiece + * @param x The first StringPiece to compare. + * @param y The second StringPiece to compare. + * @return TRUE if the string data is equal + * @internal + */ +U_EXPORT UBool U_EXPORT2 +operator==(const StringPiece& x, const StringPiece& y); + +/** + * Global operator != for StringPiece + * @param x The first StringPiece to compare. + * @param y The second StringPiece to compare. + * @return TRUE if the string data is not equal + * @internal + */ +inline UBool operator!=(const StringPiece& x, const StringPiece& y) { + return !(x == y); +} + +U_NAMESPACE_END + +#endif // __STRINGPIECE_H__ diff --git a/Source/WTF/icu/unicode/uchar.h b/Source/WTF/icu/unicode/uchar.h index 7fd490c81..93aa66320 100644 --- a/Source/WTF/icu/unicode/uchar.h +++ b/Source/WTF/icu/unicode/uchar.h @@ -1,6 +1,6 @@ /* ********************************************************************** -* Copyright (C) 1997-2004, International Business Machines +* Copyright (C) 1997-2010, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************** * @@ -39,7 +39,7 @@ U_CDECL_BEGIN * @see u_getUnicodeVersion * @stable ICU 2.0 */ -#define U_UNICODE_VERSION "4.0.1" +#define U_UNICODE_VERSION "6.0" /** * \file @@ -56,12 +56,12 @@ U_CDECL_BEGIN * * For more information see * "About the Unicode Character Database" (http://www.unicode.org/ucd/) - * and the ICU User Guide chapter on Properties (http://oss.software.ibm.com/icu/userguide/properties.html). + * and the ICU User Guide chapter on Properties (http://icu-project.org/userguide/properties.html). * * Many functions are designed to match java.lang.Character functions. * See the individual function documentation, - * and see the JDK 1.4.1 java.lang.Character documentation - * at http://java.sun.com/j2se/1.4.1/docs/api/java/lang/Character.html + * and see the JDK 1.4 java.lang.Character documentation + * at http://java.sun.com/j2se/1.4/docs/api/java/lang/Character.html * * There are also functions that provide easy migration from C/POSIX functions * like isblank(). Their use is generally discouraged because the C/POSIX @@ -77,12 +77,33 @@ U_CDECL_BEGIN * (In ICU, BreakIterator is the most sophisticated API for word boundaries.) * Another example: There is no "istitle()" class for titlecase characters. * - * A summary of the behavior of some C/POSIX character classification implementations - * for Unicode is available at http://oss.software.ibm.com/cvs/icu/~checkout~/icuhtml/design/posix_classes.html - * - * <strong>Important</strong>: - * The behavior of the ICU C/POSIX-style character classification - * functions is subject to change according to discussion of the above summary. + * ICU 3.4 and later provides API access for all twelve C/POSIX character classes. + * ICU implements them according to the Standard Recommendations in + * Annex C: Compatibility Properties of UTS #18 Unicode Regular Expressions + * (http://www.unicode.org/reports/tr18/#Compatibility_Properties). + * + * API access for C/POSIX character classes is as follows: + * - alpha: u_isUAlphabetic(c) or u_hasBinaryProperty(c, UCHAR_ALPHABETIC) + * - lower: u_isULowercase(c) or u_hasBinaryProperty(c, UCHAR_LOWERCASE) + * - upper: u_isUUppercase(c) or u_hasBinaryProperty(c, UCHAR_UPPERCASE) + * - punct: u_ispunct(c) + * - digit: u_isdigit(c) or u_charType(c)==U_DECIMAL_DIGIT_NUMBER + * - xdigit: u_isxdigit(c) or u_hasBinaryProperty(c, UCHAR_POSIX_XDIGIT) + * - alnum: u_hasBinaryProperty(c, UCHAR_POSIX_ALNUM) + * - space: u_isUWhiteSpace(c) or u_hasBinaryProperty(c, UCHAR_WHITE_SPACE) + * - blank: u_isblank(c) or u_hasBinaryProperty(c, UCHAR_POSIX_BLANK) + * - cntrl: u_charType(c)==U_CONTROL_CHAR + * - graph: u_hasBinaryProperty(c, UCHAR_POSIX_GRAPH) + * - print: u_hasBinaryProperty(c, UCHAR_POSIX_PRINT) + * + * Note: Some of the u_isxyz() functions in uchar.h predate, and do not match, + * the Standard Recommendations in UTS #18. Instead, they match Java + * functions according to their API documentation. + * + * \htmlonly + * The C/POSIX character classes are also available in UnicodeSet patterns, + * using patterns like [:graph:] or \p{graph}. + * \endhtmlonly * * Note: There are several ICU whitespace functions. * Comparison: @@ -166,200 +187,229 @@ typedef enum UProperty { /** First constant for binary Unicode properties. @stable ICU 2.1 */ UCHAR_BINARY_START=UCHAR_ALPHABETIC, /** Binary property ASCII_Hex_Digit. 0-9 A-F a-f @stable ICU 2.1 */ - UCHAR_ASCII_HEX_DIGIT, + UCHAR_ASCII_HEX_DIGIT=1, /** Binary property Bidi_Control. Format controls which have specific functions in the Bidi Algorithm. @stable ICU 2.1 */ - UCHAR_BIDI_CONTROL, + UCHAR_BIDI_CONTROL=2, /** Binary property Bidi_Mirrored. Characters that may change display in RTL text. Same as u_isMirrored. See Bidi Algorithm, UTR 9. @stable ICU 2.1 */ - UCHAR_BIDI_MIRRORED, + UCHAR_BIDI_MIRRORED=3, /** Binary property Dash. Variations of dashes. @stable ICU 2.1 */ - UCHAR_DASH, + UCHAR_DASH=4, /** Binary property Default_Ignorable_Code_Point (new in Unicode 3.2). Ignorable in most processing. <2060..206F, FFF0..FFFB, E0000..E0FFF>+Other_Default_Ignorable_Code_Point+(Cf+Cc+Cs-White_Space) @stable ICU 2.1 */ - UCHAR_DEFAULT_IGNORABLE_CODE_POINT, + UCHAR_DEFAULT_IGNORABLE_CODE_POINT=5, /** Binary property Deprecated (new in Unicode 3.2). The usage of deprecated characters is strongly discouraged. @stable ICU 2.1 */ - UCHAR_DEPRECATED, + UCHAR_DEPRECATED=6, /** Binary property Diacritic. Characters that linguistically modify the meaning of another character to which they apply. @stable ICU 2.1 */ - UCHAR_DIACRITIC, + UCHAR_DIACRITIC=7, /** Binary property Extender. Extend the value or shape of a preceding alphabetic character, e.g., length and iteration marks. @stable ICU 2.1 */ - UCHAR_EXTENDER, + UCHAR_EXTENDER=8, /** Binary property Full_Composition_Exclusion. CompositionExclusions.txt+Singleton Decompositions+ Non-Starter Decompositions. @stable ICU 2.1 */ - UCHAR_FULL_COMPOSITION_EXCLUSION, + UCHAR_FULL_COMPOSITION_EXCLUSION=9, /** Binary property Grapheme_Base (new in Unicode 3.2). For programmatic determination of grapheme cluster boundaries. [0..10FFFF]-Cc-Cf-Cs-Co-Cn-Zl-Zp-Grapheme_Link-Grapheme_Extend-CGJ @stable ICU 2.1 */ - UCHAR_GRAPHEME_BASE, + UCHAR_GRAPHEME_BASE=10, /** Binary property Grapheme_Extend (new in Unicode 3.2). For programmatic determination of grapheme cluster boundaries. Me+Mn+Mc+Other_Grapheme_Extend-Grapheme_Link-CGJ @stable ICU 2.1 */ - UCHAR_GRAPHEME_EXTEND, + UCHAR_GRAPHEME_EXTEND=11, /** Binary property Grapheme_Link (new in Unicode 3.2). For programmatic determination of grapheme cluster boundaries. @stable ICU 2.1 */ - UCHAR_GRAPHEME_LINK, + UCHAR_GRAPHEME_LINK=12, /** Binary property Hex_Digit. Characters commonly used for hexadecimal numbers. @stable ICU 2.1 */ - UCHAR_HEX_DIGIT, + UCHAR_HEX_DIGIT=13, /** Binary property Hyphen. Dashes used to mark connections between pieces of words, plus the Katakana middle dot. @stable ICU 2.1 */ - UCHAR_HYPHEN, + UCHAR_HYPHEN=14, /** Binary property ID_Continue. Characters that can continue an identifier. DerivedCoreProperties.txt also says "NOTE: Cf characters should be filtered out." ID_Start+Mn+Mc+Nd+Pc @stable ICU 2.1 */ - UCHAR_ID_CONTINUE, + UCHAR_ID_CONTINUE=15, /** Binary property ID_Start. Characters that can start an identifier. Lu+Ll+Lt+Lm+Lo+Nl @stable ICU 2.1 */ - UCHAR_ID_START, + UCHAR_ID_START=16, /** Binary property Ideographic. CJKV ideographs. @stable ICU 2.1 */ - UCHAR_IDEOGRAPHIC, + UCHAR_IDEOGRAPHIC=17, /** Binary property IDS_Binary_Operator (new in Unicode 3.2). For programmatic determination of Ideographic Description Sequences. @stable ICU 2.1 */ - UCHAR_IDS_BINARY_OPERATOR, + UCHAR_IDS_BINARY_OPERATOR=18, /** Binary property IDS_Trinary_Operator (new in Unicode 3.2). For programmatic determination of Ideographic Description Sequences. @stable ICU 2.1 */ - UCHAR_IDS_TRINARY_OPERATOR, + UCHAR_IDS_TRINARY_OPERATOR=19, /** Binary property Join_Control. Format controls for cursive joining and ligation. @stable ICU 2.1 */ - UCHAR_JOIN_CONTROL, + UCHAR_JOIN_CONTROL=20, /** Binary property Logical_Order_Exception (new in Unicode 3.2). Characters that do not use logical order and require special handling in most processing. @stable ICU 2.1 */ - UCHAR_LOGICAL_ORDER_EXCEPTION, + UCHAR_LOGICAL_ORDER_EXCEPTION=21, /** Binary property Lowercase. Same as u_isULowercase, different from u_islower. Ll+Other_Lowercase @stable ICU 2.1 */ - UCHAR_LOWERCASE, + UCHAR_LOWERCASE=22, /** Binary property Math. Sm+Other_Math @stable ICU 2.1 */ - UCHAR_MATH, + UCHAR_MATH=23, /** Binary property Noncharacter_Code_Point. Code points that are explicitly defined as illegal for the encoding of characters. @stable ICU 2.1 */ - UCHAR_NONCHARACTER_CODE_POINT, + UCHAR_NONCHARACTER_CODE_POINT=24, /** Binary property Quotation_Mark. @stable ICU 2.1 */ - UCHAR_QUOTATION_MARK, + UCHAR_QUOTATION_MARK=25, /** Binary property Radical (new in Unicode 3.2). For programmatic determination of Ideographic Description Sequences. @stable ICU 2.1 */ - UCHAR_RADICAL, + UCHAR_RADICAL=26, /** Binary property Soft_Dotted (new in Unicode 3.2). Characters with a "soft dot", like i or j. An accent placed on these characters causes the dot to disappear. @stable ICU 2.1 */ - UCHAR_SOFT_DOTTED, + UCHAR_SOFT_DOTTED=27, /** Binary property Terminal_Punctuation. Punctuation characters that generally mark the end of textual units. @stable ICU 2.1 */ - UCHAR_TERMINAL_PUNCTUATION, + UCHAR_TERMINAL_PUNCTUATION=28, /** Binary property Unified_Ideograph (new in Unicode 3.2). For programmatic determination of Ideographic Description Sequences. @stable ICU 2.1 */ - UCHAR_UNIFIED_IDEOGRAPH, + UCHAR_UNIFIED_IDEOGRAPH=29, /** Binary property Uppercase. Same as u_isUUppercase, different from u_isupper. Lu+Other_Uppercase @stable ICU 2.1 */ - UCHAR_UPPERCASE, + UCHAR_UPPERCASE=30, /** Binary property White_Space. Same as u_isUWhiteSpace, different from u_isspace and u_isWhitespace. Space characters+TAB+CR+LF-ZWSP-ZWNBSP @stable ICU 2.1 */ - UCHAR_WHITE_SPACE, + UCHAR_WHITE_SPACE=31, /** Binary property XID_Continue. ID_Continue modified to allow closure under normalization forms NFKC and NFKD. @stable ICU 2.1 */ - UCHAR_XID_CONTINUE, + UCHAR_XID_CONTINUE=32, /** Binary property XID_Start. ID_Start modified to allow closure under normalization forms NFKC and NFKD. @stable ICU 2.1 */ - UCHAR_XID_START, + UCHAR_XID_START=33, /** Binary property Case_Sensitive. Either the source of a case mapping or _in_ the target of a case mapping. Not the same as the general category Cased_Letter. @stable ICU 2.6 */ - UCHAR_CASE_SENSITIVE, + UCHAR_CASE_SENSITIVE=34, /** Binary property STerm (new in Unicode 4.0.1). Sentence Terminal. Used in UAX #29: Text Boundaries (http://www.unicode.org/reports/tr29/) - @draft ICU 3.0 */ - UCHAR_S_TERM, + @stable ICU 3.0 */ + UCHAR_S_TERM=35, /** Binary property Variation_Selector (new in Unicode 4.0.1). Indicates all those characters that qualify as Variation Selectors. For details on the behavior of these characters, see StandardizedVariants.html and 15.6 Variation Selectors. - @draft ICU 3.0 */ - UCHAR_VARIATION_SELECTOR, + @stable ICU 3.0 */ + UCHAR_VARIATION_SELECTOR=36, /** Binary property NFD_Inert. ICU-specific property for characters that are inert under NFD, i.e., they do not interact with adjacent characters. - Used for example in normalizing transforms in incremental mode - to find the boundary of safely normalizable text despite possible - text additions. - - There is one such property per normalization form. - These properties are computed as follows - an inert character is: - a) unassigned, or ALL of the following: - b) of combining class 0. - c) not decomposed by this normalization form. - AND if NFC or NFKC, - d) can never compose with a previous character. - e) can never compose with a following character. - f) can never change if another character is added. - Example: a-breve might satisfy all but f, but if you - add an ogonek it changes to a-ogonek + breve - - See also com.ibm.text.UCD.NFSkippable in the ICU4J repository, - and icu/source/common/unormimp.h . - @draft ICU 3.0 */ - UCHAR_NFD_INERT, + See the documentation for the Normalizer2 class and the + Normalizer2::isInert() method. + @stable ICU 3.0 */ + UCHAR_NFD_INERT=37, /** Binary property NFKD_Inert. ICU-specific property for characters that are inert under NFKD, i.e., they do not interact with adjacent characters. - Used for example in normalizing transforms in incremental mode - to find the boundary of safely normalizable text despite possible - text additions. - @see UCHAR_NFD_INERT - @draft ICU 3.0 */ - UCHAR_NFKD_INERT, + See the documentation for the Normalizer2 class and the + Normalizer2::isInert() method. + @stable ICU 3.0 */ + UCHAR_NFKD_INERT=38, /** Binary property NFC_Inert. ICU-specific property for characters that are inert under NFC, i.e., they do not interact with adjacent characters. - Used for example in normalizing transforms in incremental mode - to find the boundary of safely normalizable text despite possible - text additions. - @see UCHAR_NFD_INERT - @draft ICU 3.0 */ - UCHAR_NFC_INERT, + See the documentation for the Normalizer2 class and the + Normalizer2::isInert() method. + @stable ICU 3.0 */ + UCHAR_NFC_INERT=39, /** Binary property NFKC_Inert. ICU-specific property for characters that are inert under NFKC, i.e., they do not interact with adjacent characters. - Used for example in normalizing transforms in incremental mode - to find the boundary of safely normalizable text despite possible - text additions. - @see UCHAR_NFD_INERT - @draft ICU 3.0 */ - UCHAR_NFKC_INERT, + See the documentation for the Normalizer2 class and the + Normalizer2::isInert() method. + @stable ICU 3.0 */ + UCHAR_NFKC_INERT=40, /** Binary Property Segment_Starter. ICU-specific property for characters that are starters in terms of Unicode normalization and combining character sequences. They have ccc=0 and do not occur in non-initial position of the canonical decomposition of any character - (like " in NFD(a-umlaut) and a Jamo T in an NFD(Hangul LVT)). + (like a-umlaut in NFD and a Jamo T in an NFD(Hangul LVT)). ICU uses this property for segmenting a string for generating a set of canonically equivalent strings, e.g. for canonical closure while processing collation tailoring rules. - @draft ICU 3.0 */ - UCHAR_SEGMENT_STARTER, + @stable ICU 3.0 */ + UCHAR_SEGMENT_STARTER=41, + /** Binary property Pattern_Syntax (new in Unicode 4.1). + See UAX #31 Identifier and Pattern Syntax + (http://www.unicode.org/reports/tr31/) + @stable ICU 3.4 */ + UCHAR_PATTERN_SYNTAX=42, + /** Binary property Pattern_White_Space (new in Unicode 4.1). + See UAX #31 Identifier and Pattern Syntax + (http://www.unicode.org/reports/tr31/) + @stable ICU 3.4 */ + UCHAR_PATTERN_WHITE_SPACE=43, + /** Binary property alnum (a C/POSIX character class). + Implemented according to the UTS #18 Annex C Standard Recommendation. + See the uchar.h file documentation. + @stable ICU 3.4 */ + UCHAR_POSIX_ALNUM=44, + /** Binary property blank (a C/POSIX character class). + Implemented according to the UTS #18 Annex C Standard Recommendation. + See the uchar.h file documentation. + @stable ICU 3.4 */ + UCHAR_POSIX_BLANK=45, + /** Binary property graph (a C/POSIX character class). + Implemented according to the UTS #18 Annex C Standard Recommendation. + See the uchar.h file documentation. + @stable ICU 3.4 */ + UCHAR_POSIX_GRAPH=46, + /** Binary property print (a C/POSIX character class). + Implemented according to the UTS #18 Annex C Standard Recommendation. + See the uchar.h file documentation. + @stable ICU 3.4 */ + UCHAR_POSIX_PRINT=47, + /** Binary property xdigit (a C/POSIX character class). + Implemented according to the UTS #18 Annex C Standard Recommendation. + See the uchar.h file documentation. + @stable ICU 3.4 */ + UCHAR_POSIX_XDIGIT=48, + /** Binary property Cased. For Lowercase, Uppercase and Titlecase characters. @stable ICU 4.4 */ + UCHAR_CASED=49, + /** Binary property Case_Ignorable. Used in context-sensitive case mappings. @stable ICU 4.4 */ + UCHAR_CASE_IGNORABLE=50, + /** Binary property Changes_When_Lowercased. @stable ICU 4.4 */ + UCHAR_CHANGES_WHEN_LOWERCASED=51, + /** Binary property Changes_When_Uppercased. @stable ICU 4.4 */ + UCHAR_CHANGES_WHEN_UPPERCASED=52, + /** Binary property Changes_When_Titlecased. @stable ICU 4.4 */ + UCHAR_CHANGES_WHEN_TITLECASED=53, + /** Binary property Changes_When_Casefolded. @stable ICU 4.4 */ + UCHAR_CHANGES_WHEN_CASEFOLDED=54, + /** Binary property Changes_When_Casemapped. @stable ICU 4.4 */ + UCHAR_CHANGES_WHEN_CASEMAPPED=55, + /** Binary property Changes_When_NFKC_Casefolded. @stable ICU 4.4 */ + UCHAR_CHANGES_WHEN_NFKC_CASEFOLDED=56, /** One more than the last constant for binary Unicode properties. @stable ICU 2.1 */ - UCHAR_BINARY_LIMIT, + UCHAR_BINARY_LIMIT=57, /** Enumerated property Bidi_Class. Same as u_charDirection, returns UCharDirection values. @stable ICU 2.2 */ @@ -368,66 +418,81 @@ typedef enum UProperty { UCHAR_INT_START=UCHAR_BIDI_CLASS, /** Enumerated property Block. Same as ublock_getCode, returns UBlockCode values. @stable ICU 2.2 */ - UCHAR_BLOCK, + UCHAR_BLOCK=0x1001, /** Enumerated property Canonical_Combining_Class. Same as u_getCombiningClass, returns 8-bit numeric values. @stable ICU 2.2 */ - UCHAR_CANONICAL_COMBINING_CLASS, + UCHAR_CANONICAL_COMBINING_CLASS=0x1002, /** Enumerated property Decomposition_Type. Returns UDecompositionType values. @stable ICU 2.2 */ - UCHAR_DECOMPOSITION_TYPE, + UCHAR_DECOMPOSITION_TYPE=0x1003, /** Enumerated property East_Asian_Width. See http://www.unicode.org/reports/tr11/ Returns UEastAsianWidth values. @stable ICU 2.2 */ - UCHAR_EAST_ASIAN_WIDTH, + UCHAR_EAST_ASIAN_WIDTH=0x1004, /** Enumerated property General_Category. Same as u_charType, returns UCharCategory values. @stable ICU 2.2 */ - UCHAR_GENERAL_CATEGORY, + UCHAR_GENERAL_CATEGORY=0x1005, /** Enumerated property Joining_Group. Returns UJoiningGroup values. @stable ICU 2.2 */ - UCHAR_JOINING_GROUP, + UCHAR_JOINING_GROUP=0x1006, /** Enumerated property Joining_Type. Returns UJoiningType values. @stable ICU 2.2 */ - UCHAR_JOINING_TYPE, + UCHAR_JOINING_TYPE=0x1007, /** Enumerated property Line_Break. Returns ULineBreak values. @stable ICU 2.2 */ - UCHAR_LINE_BREAK, + UCHAR_LINE_BREAK=0x1008, /** Enumerated property Numeric_Type. Returns UNumericType values. @stable ICU 2.2 */ - UCHAR_NUMERIC_TYPE, + UCHAR_NUMERIC_TYPE=0x1009, /** Enumerated property Script. Same as uscript_getScript, returns UScriptCode values. @stable ICU 2.2 */ - UCHAR_SCRIPT, + UCHAR_SCRIPT=0x100A, /** Enumerated property Hangul_Syllable_Type, new in Unicode 4. Returns UHangulSyllableType values. @stable ICU 2.6 */ - UCHAR_HANGUL_SYLLABLE_TYPE, + UCHAR_HANGUL_SYLLABLE_TYPE=0x100B, /** Enumerated property NFD_Quick_Check. - Returns UNormalizationCheckResult values. @draft ICU 3.0 */ - UCHAR_NFD_QUICK_CHECK, + Returns UNormalizationCheckResult values. @stable ICU 3.0 */ + UCHAR_NFD_QUICK_CHECK=0x100C, /** Enumerated property NFKD_Quick_Check. - Returns UNormalizationCheckResult values. @draft ICU 3.0 */ - UCHAR_NFKD_QUICK_CHECK, + Returns UNormalizationCheckResult values. @stable ICU 3.0 */ + UCHAR_NFKD_QUICK_CHECK=0x100D, /** Enumerated property NFC_Quick_Check. - Returns UNormalizationCheckResult values. @draft ICU 3.0 */ - UCHAR_NFC_QUICK_CHECK, + Returns UNormalizationCheckResult values. @stable ICU 3.0 */ + UCHAR_NFC_QUICK_CHECK=0x100E, /** Enumerated property NFKC_Quick_Check. - Returns UNormalizationCheckResult values. @draft ICU 3.0 */ - UCHAR_NFKC_QUICK_CHECK, + Returns UNormalizationCheckResult values. @stable ICU 3.0 */ + UCHAR_NFKC_QUICK_CHECK=0x100F, /** Enumerated property Lead_Canonical_Combining_Class. ICU-specific property for the ccc of the first code point of the decomposition, or lccc(c)=ccc(NFD(c)[0]). Useful for checking for canonically ordered text; see UNORM_FCD and http://www.unicode.org/notes/tn5/#FCD . - Returns 8-bit numeric values like UCHAR_CANONICAL_COMBINING_CLASS. @draft ICU 3.0 */ - UCHAR_LEAD_CANONICAL_COMBINING_CLASS, + Returns 8-bit numeric values like UCHAR_CANONICAL_COMBINING_CLASS. @stable ICU 3.0 */ + UCHAR_LEAD_CANONICAL_COMBINING_CLASS=0x1010, /** Enumerated property Trail_Canonical_Combining_Class. ICU-specific property for the ccc of the last code point of the decomposition, or tccc(c)=ccc(NFD(c)[last]). Useful for checking for canonically ordered text; see UNORM_FCD and http://www.unicode.org/notes/tn5/#FCD . - Returns 8-bit numeric values like UCHAR_CANONICAL_COMBINING_CLASS. @draft ICU 3.0 */ - UCHAR_TRAIL_CANONICAL_COMBINING_CLASS, + Returns 8-bit numeric values like UCHAR_CANONICAL_COMBINING_CLASS. @stable ICU 3.0 */ + UCHAR_TRAIL_CANONICAL_COMBINING_CLASS=0x1011, + /** Enumerated property Grapheme_Cluster_Break (new in Unicode 4.1). + Used in UAX #29: Text Boundaries + (http://www.unicode.org/reports/tr29/) + Returns UGraphemeClusterBreak values. @stable ICU 3.4 */ + UCHAR_GRAPHEME_CLUSTER_BREAK=0x1012, + /** Enumerated property Sentence_Break (new in Unicode 4.1). + Used in UAX #29: Text Boundaries + (http://www.unicode.org/reports/tr29/) + Returns USentenceBreak values. @stable ICU 3.4 */ + UCHAR_SENTENCE_BREAK=0x1013, + /** Enumerated property Word_Break (new in Unicode 4.1). + Used in UAX #29: Text Boundaries + (http://www.unicode.org/reports/tr29/) + Returns UWordBreakValues values. @stable ICU 3.4 */ + UCHAR_WORD_BREAK=0x1014, /** One more than the last constant for enumerated/integer Unicode properties. @stable ICU 2.2 */ - UCHAR_INT_LIMIT, + UCHAR_INT_LIMIT=0x1015, /** Bitmask property General_Category_Mask. This is the General_Category property returned as a bit mask. @@ -441,7 +506,7 @@ typedef enum UProperty { /** First constant for bit-mask Unicode properties. @stable ICU 2.4 */ UCHAR_MASK_START=UCHAR_GENERAL_CATEGORY_MASK, /** One more than the last constant for bit-mask Unicode properties. @stable ICU 2.4 */ - UCHAR_MASK_LIMIT, + UCHAR_MASK_LIMIT=0x2001, /** Double property Numeric_Value. Corresponds to u_getNumericValue. @stable ICU 2.4 */ @@ -449,7 +514,7 @@ typedef enum UProperty { /** First constant for double Unicode properties. @stable ICU 2.4 */ UCHAR_DOUBLE_START=UCHAR_NUMERIC_VALUE, /** One more than the last constant for double Unicode properties. @stable ICU 2.4 */ - UCHAR_DOUBLE_LIMIT, + UCHAR_DOUBLE_LIMIT=0x3001, /** String property Age. Corresponds to u_charAge. @stable ICU 2.4 */ @@ -458,42 +523,56 @@ typedef enum UProperty { UCHAR_STRING_START=UCHAR_AGE, /** String property Bidi_Mirroring_Glyph. Corresponds to u_charMirror. @stable ICU 2.4 */ - UCHAR_BIDI_MIRRORING_GLYPH, + UCHAR_BIDI_MIRRORING_GLYPH=0x4001, /** String property Case_Folding. Corresponds to u_strFoldCase in ustring.h. @stable ICU 2.4 */ - UCHAR_CASE_FOLDING, + UCHAR_CASE_FOLDING=0x4002, /** String property ISO_Comment. Corresponds to u_getISOComment. @stable ICU 2.4 */ - UCHAR_ISO_COMMENT, + UCHAR_ISO_COMMENT=0x4003, /** String property Lowercase_Mapping. Corresponds to u_strToLower in ustring.h. @stable ICU 2.4 */ - UCHAR_LOWERCASE_MAPPING, + UCHAR_LOWERCASE_MAPPING=0x4004, /** String property Name. Corresponds to u_charName. @stable ICU 2.4 */ - UCHAR_NAME, + UCHAR_NAME=0x4005, /** String property Simple_Case_Folding. Corresponds to u_foldCase. @stable ICU 2.4 */ - UCHAR_SIMPLE_CASE_FOLDING, + UCHAR_SIMPLE_CASE_FOLDING=0x4006, /** String property Simple_Lowercase_Mapping. Corresponds to u_tolower. @stable ICU 2.4 */ - UCHAR_SIMPLE_LOWERCASE_MAPPING, + UCHAR_SIMPLE_LOWERCASE_MAPPING=0x4007, /** String property Simple_Titlecase_Mapping. Corresponds to u_totitle. @stable ICU 2.4 */ - UCHAR_SIMPLE_TITLECASE_MAPPING, + UCHAR_SIMPLE_TITLECASE_MAPPING=0x4008, /** String property Simple_Uppercase_Mapping. Corresponds to u_toupper. @stable ICU 2.4 */ - UCHAR_SIMPLE_UPPERCASE_MAPPING, + UCHAR_SIMPLE_UPPERCASE_MAPPING=0x4009, /** String property Titlecase_Mapping. Corresponds to u_strToTitle in ustring.h. @stable ICU 2.4 */ - UCHAR_TITLECASE_MAPPING, + UCHAR_TITLECASE_MAPPING=0x400A, /** String property Unicode_1_Name. Corresponds to u_charName. @stable ICU 2.4 */ - UCHAR_UNICODE_1_NAME, + UCHAR_UNICODE_1_NAME=0x400B, /** String property Uppercase_Mapping. Corresponds to u_strToUpper in ustring.h. @stable ICU 2.4 */ - UCHAR_UPPERCASE_MAPPING, + UCHAR_UPPERCASE_MAPPING=0x400C, /** One more than the last constant for string Unicode properties. @stable ICU 2.4 */ - UCHAR_STRING_LIMIT, + UCHAR_STRING_LIMIT=0x400D, + + /** Provisional property Script_Extensions (new in Unicode 6.0). + As a provisional property, it may be modified or removed + in future versions of the Unicode Standard, and thus in ICU. + Some characters are commonly used in multiple scripts. + For more information, see UAX #24: http://www.unicode.org/reports/tr24/. + Corresponds to uscript_hasScript and uscript_getScriptExtensions in uscript.h. + @draft ICU 4.6 */ + UCHAR_SCRIPT_EXTENSIONS=0x7000, + /** First constant for Unicode properties with unusual value types. @draft ICU 4.6 */ + UCHAR_OTHER_PROPERTY_START=UCHAR_SCRIPT_EXTENSIONS, + /** One more than the last constant for Unicode properties with unusual value types. + * @draft ICU 4.6 */ + UCHAR_OTHER_PROPERTY_LIMIT=0x7001, /** Represents a nonexistent or invalid property or property value. @stable ICU 2.4 */ UCHAR_INVALID_CODE = -1 @@ -1057,7 +1136,7 @@ enum UBlockCode { * @stable ICU 2.2 */ UBLOCK_CYRILLIC_SUPPLEMENTARY = 97, - /** @draft ICU 3.0 */ + /** @stable ICU 3.0 */ UBLOCK_CYRILLIC_SUPPLEMENT = UBLOCK_CYRILLIC_SUPPLEMENTARY, /*[0500]*/ /** @stable ICU 2.2 */ UBLOCK_TAGALOG = 98, /*[1700]*/ @@ -1119,8 +1198,191 @@ enum UBlockCode { /** @stable ICU 2.6 */ UBLOCK_VARIATION_SELECTORS_SUPPLEMENT = 125, /*[E0100]*/ - /** @stable ICU 2.0 */ - UBLOCK_COUNT, + /* New blocks in Unicode 4.1 */ + + /** @stable ICU 3.4 */ + UBLOCK_ANCIENT_GREEK_MUSICAL_NOTATION = 126, /*[1D200]*/ + /** @stable ICU 3.4 */ + UBLOCK_ANCIENT_GREEK_NUMBERS = 127, /*[10140]*/ + /** @stable ICU 3.4 */ + UBLOCK_ARABIC_SUPPLEMENT = 128, /*[0750]*/ + /** @stable ICU 3.4 */ + UBLOCK_BUGINESE = 129, /*[1A00]*/ + /** @stable ICU 3.4 */ + UBLOCK_CJK_STROKES = 130, /*[31C0]*/ + /** @stable ICU 3.4 */ + UBLOCK_COMBINING_DIACRITICAL_MARKS_SUPPLEMENT = 131, /*[1DC0]*/ + /** @stable ICU 3.4 */ + UBLOCK_COPTIC = 132, /*[2C80]*/ + /** @stable ICU 3.4 */ + UBLOCK_ETHIOPIC_EXTENDED = 133, /*[2D80]*/ + /** @stable ICU 3.4 */ + UBLOCK_ETHIOPIC_SUPPLEMENT = 134, /*[1380]*/ + /** @stable ICU 3.4 */ + UBLOCK_GEORGIAN_SUPPLEMENT = 135, /*[2D00]*/ + /** @stable ICU 3.4 */ + UBLOCK_GLAGOLITIC = 136, /*[2C00]*/ + /** @stable ICU 3.4 */ + UBLOCK_KHAROSHTHI = 137, /*[10A00]*/ + /** @stable ICU 3.4 */ + UBLOCK_MODIFIER_TONE_LETTERS = 138, /*[A700]*/ + /** @stable ICU 3.4 */ + UBLOCK_NEW_TAI_LUE = 139, /*[1980]*/ + /** @stable ICU 3.4 */ + UBLOCK_OLD_PERSIAN = 140, /*[103A0]*/ + /** @stable ICU 3.4 */ + UBLOCK_PHONETIC_EXTENSIONS_SUPPLEMENT = 141, /*[1D80]*/ + /** @stable ICU 3.4 */ + UBLOCK_SUPPLEMENTAL_PUNCTUATION = 142, /*[2E00]*/ + /** @stable ICU 3.4 */ + UBLOCK_SYLOTI_NAGRI = 143, /*[A800]*/ + /** @stable ICU 3.4 */ + UBLOCK_TIFINAGH = 144, /*[2D30]*/ + /** @stable ICU 3.4 */ + UBLOCK_VERTICAL_FORMS = 145, /*[FE10]*/ + + /* New blocks in Unicode 5.0 */ + + /** @stable ICU 3.6 */ + UBLOCK_NKO = 146, /*[07C0]*/ + /** @stable ICU 3.6 */ + UBLOCK_BALINESE = 147, /*[1B00]*/ + /** @stable ICU 3.6 */ + UBLOCK_LATIN_EXTENDED_C = 148, /*[2C60]*/ + /** @stable ICU 3.6 */ + UBLOCK_LATIN_EXTENDED_D = 149, /*[A720]*/ + /** @stable ICU 3.6 */ + UBLOCK_PHAGS_PA = 150, /*[A840]*/ + /** @stable ICU 3.6 */ + UBLOCK_PHOENICIAN = 151, /*[10900]*/ + /** @stable ICU 3.6 */ + UBLOCK_CUNEIFORM = 152, /*[12000]*/ + /** @stable ICU 3.6 */ + UBLOCK_CUNEIFORM_NUMBERS_AND_PUNCTUATION = 153, /*[12400]*/ + /** @stable ICU 3.6 */ + UBLOCK_COUNTING_ROD_NUMERALS = 154, /*[1D360]*/ + + /* New blocks in Unicode 5.1 */ + + /** @stable ICU 4.0 */ + UBLOCK_SUNDANESE = 155, /*[1B80]*/ + /** @stable ICU 4.0 */ + UBLOCK_LEPCHA = 156, /*[1C00]*/ + /** @stable ICU 4.0 */ + UBLOCK_OL_CHIKI = 157, /*[1C50]*/ + /** @stable ICU 4.0 */ + UBLOCK_CYRILLIC_EXTENDED_A = 158, /*[2DE0]*/ + /** @stable ICU 4.0 */ + UBLOCK_VAI = 159, /*[A500]*/ + /** @stable ICU 4.0 */ + UBLOCK_CYRILLIC_EXTENDED_B = 160, /*[A640]*/ + /** @stable ICU 4.0 */ + UBLOCK_SAURASHTRA = 161, /*[A880]*/ + /** @stable ICU 4.0 */ + UBLOCK_KAYAH_LI = 162, /*[A900]*/ + /** @stable ICU 4.0 */ + UBLOCK_REJANG = 163, /*[A930]*/ + /** @stable ICU 4.0 */ + UBLOCK_CHAM = 164, /*[AA00]*/ + /** @stable ICU 4.0 */ + UBLOCK_ANCIENT_SYMBOLS = 165, /*[10190]*/ + /** @stable ICU 4.0 */ + UBLOCK_PHAISTOS_DISC = 166, /*[101D0]*/ + /** @stable ICU 4.0 */ + UBLOCK_LYCIAN = 167, /*[10280]*/ + /** @stable ICU 4.0 */ + UBLOCK_CARIAN = 168, /*[102A0]*/ + /** @stable ICU 4.0 */ + UBLOCK_LYDIAN = 169, /*[10920]*/ + /** @stable ICU 4.0 */ + UBLOCK_MAHJONG_TILES = 170, /*[1F000]*/ + /** @stable ICU 4.0 */ + UBLOCK_DOMINO_TILES = 171, /*[1F030]*/ + + /* New blocks in Unicode 5.2 */ + + /** @stable ICU 4.4 */ + UBLOCK_SAMARITAN = 172, /*[0800]*/ + /** @stable ICU 4.4 */ + UBLOCK_UNIFIED_CANADIAN_ABORIGINAL_SYLLABICS_EXTENDED = 173, /*[18B0]*/ + /** @stable ICU 4.4 */ + UBLOCK_TAI_THAM = 174, /*[1A20]*/ + /** @stable ICU 4.4 */ + UBLOCK_VEDIC_EXTENSIONS = 175, /*[1CD0]*/ + /** @stable ICU 4.4 */ + UBLOCK_LISU = 176, /*[A4D0]*/ + /** @stable ICU 4.4 */ + UBLOCK_BAMUM = 177, /*[A6A0]*/ + /** @stable ICU 4.4 */ + UBLOCK_COMMON_INDIC_NUMBER_FORMS = 178, /*[A830]*/ + /** @stable ICU 4.4 */ + UBLOCK_DEVANAGARI_EXTENDED = 179, /*[A8E0]*/ + /** @stable ICU 4.4 */ + UBLOCK_HANGUL_JAMO_EXTENDED_A = 180, /*[A960]*/ + /** @stable ICU 4.4 */ + UBLOCK_JAVANESE = 181, /*[A980]*/ + /** @stable ICU 4.4 */ + UBLOCK_MYANMAR_EXTENDED_A = 182, /*[AA60]*/ + /** @stable ICU 4.4 */ + UBLOCK_TAI_VIET = 183, /*[AA80]*/ + /** @stable ICU 4.4 */ + UBLOCK_MEETEI_MAYEK = 184, /*[ABC0]*/ + /** @stable ICU 4.4 */ + UBLOCK_HANGUL_JAMO_EXTENDED_B = 185, /*[D7B0]*/ + /** @stable ICU 4.4 */ + UBLOCK_IMPERIAL_ARAMAIC = 186, /*[10840]*/ + /** @stable ICU 4.4 */ + UBLOCK_OLD_SOUTH_ARABIAN = 187, /*[10A60]*/ + /** @stable ICU 4.4 */ + UBLOCK_AVESTAN = 188, /*[10B00]*/ + /** @stable ICU 4.4 */ + UBLOCK_INSCRIPTIONAL_PARTHIAN = 189, /*[10B40]*/ + /** @stable ICU 4.4 */ + UBLOCK_INSCRIPTIONAL_PAHLAVI = 190, /*[10B60]*/ + /** @stable ICU 4.4 */ + UBLOCK_OLD_TURKIC = 191, /*[10C00]*/ + /** @stable ICU 4.4 */ + UBLOCK_RUMI_NUMERAL_SYMBOLS = 192, /*[10E60]*/ + /** @stable ICU 4.4 */ + UBLOCK_KAITHI = 193, /*[11080]*/ + /** @stable ICU 4.4 */ + UBLOCK_EGYPTIAN_HIEROGLYPHS = 194, /*[13000]*/ + /** @stable ICU 4.4 */ + UBLOCK_ENCLOSED_ALPHANUMERIC_SUPPLEMENT = 195, /*[1F100]*/ + /** @stable ICU 4.4 */ + UBLOCK_ENCLOSED_IDEOGRAPHIC_SUPPLEMENT = 196, /*[1F200]*/ + /** @stable ICU 4.4 */ + UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_C = 197, /*[2A700]*/ + + /* New blocks in Unicode 6.0 */ + + /** @stable ICU 4.6 */ + UBLOCK_MANDAIC = 198, /*[0840]*/ + /** @stable ICU 4.6 */ + UBLOCK_BATAK = 199, /*[1BC0]*/ + /** @stable ICU 4.6 */ + UBLOCK_ETHIOPIC_EXTENDED_A = 200, /*[AB00]*/ + /** @stable ICU 4.6 */ + UBLOCK_BRAHMI = 201, /*[11000]*/ + /** @stable ICU 4.6 */ + UBLOCK_BAMUM_SUPPLEMENT = 202, /*[16800]*/ + /** @stable ICU 4.6 */ + UBLOCK_KANA_SUPPLEMENT = 203, /*[1B000]*/ + /** @stable ICU 4.6 */ + UBLOCK_PLAYING_CARDS = 204, /*[1F0A0]*/ + /** @stable ICU 4.6 */ + UBLOCK_MISCELLANEOUS_SYMBOLS_AND_PICTOGRAPHS = 205, /*[1F300]*/ + /** @stable ICU 4.6 */ + UBLOCK_EMOTICONS = 206, /*[1F600]*/ + /** @stable ICU 4.6 */ + UBLOCK_TRANSPORT_AND_MAP_SYMBOLS = 207, /*[1F680]*/ + /** @stable ICU 4.6 */ + UBLOCK_ALCHEMICAL_SYMBOLS = 208, /*[1F700]*/ + /** @stable ICU 4.6 */ + UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_D = 209, /*[2B740]*/ + + /** @stable ICU 2.0 */ + UBLOCK_COUNT = 210, /** @stable ICU 2.0 */ UBLOCK_INVALID_CODE=-1 @@ -1165,6 +1427,7 @@ typedef enum UCharNameChoice { U_UNICODE_CHAR_NAME, U_UNICODE_10_CHAR_NAME, U_EXTENDED_CHAR_NAME, + U_CHAR_NAME_ALIAS, /**< Corrected name from NameAliases.txt. @stable ICU 4.4 */ U_CHAR_NAME_CHOICE_COUNT } UCharNameChoice; @@ -1252,7 +1515,8 @@ typedef enum UJoiningGroup { U_JG_GAF, U_JG_GAMAL, U_JG_HAH, - U_JG_HAMZA_ON_HEH_GOAL, + U_JG_TEH_MARBUTA_GOAL, /**< @stable ICU 4.6 */ + U_JG_HAMZA_ON_HEH_GOAL=U_JG_TEH_MARBUTA_GOAL, U_JG_HE, U_JG_HEH, U_JG_HEH_GOAL, @@ -1292,50 +1556,130 @@ typedef enum UJoiningGroup { U_JG_FE, /**< @stable ICU 2.6 */ U_JG_KHAPH, /**< @stable ICU 2.6 */ U_JG_ZHAIN, /**< @stable ICU 2.6 */ + U_JG_BURUSHASKI_YEH_BARREE, /**< @stable ICU 4.0 */ + U_JG_FARSI_YEH, /**< @stable ICU 4.4 */ + U_JG_NYA, /**< @stable ICU 4.4 */ U_JG_COUNT } UJoiningGroup; /** + * Grapheme Cluster Break constants. + * + * @see UCHAR_GRAPHEME_CLUSTER_BREAK + * @stable ICU 3.4 + */ +typedef enum UGraphemeClusterBreak { + U_GCB_OTHER = 0, /*[XX]*/ /*See note !!*/ + U_GCB_CONTROL = 1, /*[CN]*/ + U_GCB_CR = 2, /*[CR]*/ + U_GCB_EXTEND = 3, /*[EX]*/ + U_GCB_L = 4, /*[L]*/ + U_GCB_LF = 5, /*[LF]*/ + U_GCB_LV = 6, /*[LV]*/ + U_GCB_LVT = 7, /*[LVT]*/ + U_GCB_T = 8, /*[T]*/ + U_GCB_V = 9, /*[V]*/ + U_GCB_SPACING_MARK = 10, /*[SM]*/ /* from here on: new in Unicode 5.1/ICU 4.0 */ + U_GCB_PREPEND = 11, /*[PP]*/ + U_GCB_COUNT = 12 +} UGraphemeClusterBreak; + +/** + * Word Break constants. + * (UWordBreak is a pre-existing enum type in ubrk.h for word break status tags.) + * + * @see UCHAR_WORD_BREAK + * @stable ICU 3.4 + */ +typedef enum UWordBreakValues { + U_WB_OTHER = 0, /*[XX]*/ /*See note !!*/ + U_WB_ALETTER = 1, /*[LE]*/ + U_WB_FORMAT = 2, /*[FO]*/ + U_WB_KATAKANA = 3, /*[KA]*/ + U_WB_MIDLETTER = 4, /*[ML]*/ + U_WB_MIDNUM = 5, /*[MN]*/ + U_WB_NUMERIC = 6, /*[NU]*/ + U_WB_EXTENDNUMLET = 7, /*[EX]*/ + U_WB_CR = 8, /*[CR]*/ /* from here on: new in Unicode 5.1/ICU 4.0 */ + U_WB_EXTEND = 9, /*[Extend]*/ + U_WB_LF = 10, /*[LF]*/ + U_WB_MIDNUMLET =11, /*[MB]*/ + U_WB_NEWLINE =12, /*[NL]*/ + U_WB_COUNT = 13 +} UWordBreakValues; + +/** + * Sentence Break constants. + * + * @see UCHAR_SENTENCE_BREAK + * @stable ICU 3.4 + */ +typedef enum USentenceBreak { + U_SB_OTHER = 0, /*[XX]*/ /*See note !!*/ + U_SB_ATERM = 1, /*[AT]*/ + U_SB_CLOSE = 2, /*[CL]*/ + U_SB_FORMAT = 3, /*[FO]*/ + U_SB_LOWER = 4, /*[LO]*/ + U_SB_NUMERIC = 5, /*[NU]*/ + U_SB_OLETTER = 6, /*[LE]*/ + U_SB_SEP = 7, /*[SE]*/ + U_SB_SP = 8, /*[SP]*/ + U_SB_STERM = 9, /*[ST]*/ + U_SB_UPPER = 10, /*[UP]*/ + U_SB_CR = 11, /*[CR]*/ /* from here on: new in Unicode 5.1/ICU 4.0 */ + U_SB_EXTEND = 12, /*[EX]*/ + U_SB_LF = 13, /*[LF]*/ + U_SB_SCONTINUE = 14, /*[SC]*/ + U_SB_COUNT = 15 +} USentenceBreak; + +/** * Line Break constants. * * @see UCHAR_LINE_BREAK * @stable ICU 2.2 */ typedef enum ULineBreak { - U_LB_UNKNOWN, /*[XX]*/ /*See note !!*/ - U_LB_AMBIGUOUS, /*[AI]*/ - U_LB_ALPHABETIC, /*[AL]*/ - U_LB_BREAK_BOTH, /*[B2]*/ - U_LB_BREAK_AFTER, /*[BA]*/ - U_LB_BREAK_BEFORE, /*[BB]*/ - U_LB_MANDATORY_BREAK, /*[BK]*/ - U_LB_CONTINGENT_BREAK, /*[CB]*/ - U_LB_CLOSE_PUNCTUATION, /*[CL]*/ - U_LB_COMBINING_MARK, /*[CM]*/ - U_LB_CARRIAGE_RETURN, /*[CR]*/ - U_LB_EXCLAMATION, /*[EX]*/ - U_LB_GLUE, /*[GL]*/ - U_LB_HYPHEN, /*[HY]*/ - U_LB_IDEOGRAPHIC, /*[ID]*/ - U_LB_INSEPERABLE, - /** Renamed from the misspelled "inseperable" in Unicode 4.0.1/ICU 3.0 @draft ICU 3.0 */ + U_LB_UNKNOWN = 0, /*[XX]*/ /*See note !!*/ + U_LB_AMBIGUOUS = 1, /*[AI]*/ + U_LB_ALPHABETIC = 2, /*[AL]*/ + U_LB_BREAK_BOTH = 3, /*[B2]*/ + U_LB_BREAK_AFTER = 4, /*[BA]*/ + U_LB_BREAK_BEFORE = 5, /*[BB]*/ + U_LB_MANDATORY_BREAK = 6, /*[BK]*/ + U_LB_CONTINGENT_BREAK = 7, /*[CB]*/ + U_LB_CLOSE_PUNCTUATION = 8, /*[CL]*/ + U_LB_COMBINING_MARK = 9, /*[CM]*/ + U_LB_CARRIAGE_RETURN = 10, /*[CR]*/ + U_LB_EXCLAMATION = 11, /*[EX]*/ + U_LB_GLUE = 12, /*[GL]*/ + U_LB_HYPHEN = 13, /*[HY]*/ + U_LB_IDEOGRAPHIC = 14, /*[ID]*/ + U_LB_INSEPERABLE = 15, + /** Renamed from the misspelled "inseperable" in Unicode 4.0.1/ICU 3.0 @stable ICU 3.0 */ U_LB_INSEPARABLE=U_LB_INSEPERABLE,/*[IN]*/ - U_LB_INFIX_NUMERIC, /*[IS]*/ - U_LB_LINE_FEED, /*[LF]*/ - U_LB_NONSTARTER, /*[NS]*/ - U_LB_NUMERIC, /*[NU]*/ - U_LB_OPEN_PUNCTUATION, /*[OP]*/ - U_LB_POSTFIX_NUMERIC, /*[PO]*/ - U_LB_PREFIX_NUMERIC, /*[PR]*/ - U_LB_QUOTATION, /*[QU]*/ - U_LB_COMPLEX_CONTEXT, /*[SA]*/ - U_LB_SURROGATE, /*[SG]*/ - U_LB_SPACE, /*[SP]*/ - U_LB_BREAK_SYMBOLS, /*[SY]*/ - U_LB_ZWSPACE, /*[ZW]*/ - U_LB_NEXT_LINE, /*[NL]*/ /* from here on: new in Unicode 4/ICU 2.6 */ - U_LB_WORD_JOINER, /*[WJ]*/ - U_LB_COUNT + U_LB_INFIX_NUMERIC = 16, /*[IS]*/ + U_LB_LINE_FEED = 17, /*[LF]*/ + U_LB_NONSTARTER = 18, /*[NS]*/ + U_LB_NUMERIC = 19, /*[NU]*/ + U_LB_OPEN_PUNCTUATION = 20, /*[OP]*/ + U_LB_POSTFIX_NUMERIC = 21, /*[PO]*/ + U_LB_PREFIX_NUMERIC = 22, /*[PR]*/ + U_LB_QUOTATION = 23, /*[QU]*/ + U_LB_COMPLEX_CONTEXT = 24, /*[SA]*/ + U_LB_SURROGATE = 25, /*[SG]*/ + U_LB_SPACE = 26, /*[SP]*/ + U_LB_BREAK_SYMBOLS = 27, /*[SY]*/ + U_LB_ZWSPACE = 28, /*[ZW]*/ + U_LB_NEXT_LINE = 29, /*[NL]*/ /* from here on: new in Unicode 4/ICU 2.6 */ + U_LB_WORD_JOINER = 30, /*[WJ]*/ + U_LB_H2 = 31, /*[H2]*/ /* from here on: new in Unicode 4.1/ICU 3.4 */ + U_LB_H3 = 32, /*[H3]*/ + U_LB_JL = 33, /*[JL]*/ + U_LB_JT = 34, /*[JT]*/ + U_LB_JV = 35, /*[JV]*/ + U_LB_CLOSE_PARENTHESIS = 36, /*[CP]*/ /* new in Unicode 5.2/ICU 4.4 */ + U_LB_COUNT = 37 } ULineBreak; /** @@ -1606,7 +1950,6 @@ u_getNumericValue(UChar32 c); * @see UCHAR_LOWERCASE * @see u_isupper * @see u_istitle - * @see u_islower * @stable ICU 2.0 */ U_STABLE UBool U_EXPORT2 @@ -1878,8 +2221,8 @@ u_isJavaSpaceChar(UChar32 c); * A character is considered to be a Java whitespace character if and only * if it satisfies one of the following criteria: * - * - It is a Unicode separator (categories "Z"), but is not - * a no-break space (U+00A0 NBSP or U+2007 Figure Space or U+202F Narrow NBSP). + * - It is a Unicode Separator character (categories "Z" = "Zs" or "Zl" or "Zp"), but is not + * also a non-breaking space (U+00A0 NBSP or U+2007 Figure Space or U+202F Narrow NBSP). * - It is U+0009 HORIZONTAL TABULATION. * - It is U+000A LINE FEED. * - It is U+000B VERTICAL TABULATION. @@ -1889,9 +2232,15 @@ u_isJavaSpaceChar(UChar32 c); * - It is U+001D GROUP SEPARATOR. * - It is U+001E RECORD SEPARATOR. * - It is U+001F UNIT SEPARATOR. - * - It is U+0085 NEXT LINE. * - * Same as java.lang.Character.isWhitespace() except that Java omits U+0085. + * This API tries to sync with the semantics of Java's + * java.lang.Character.isWhitespace(), but it may not return + * the exact same results because of the Unicode version + * difference. + * + * Note: Unicode 4.0.1 changed U+200B ZERO WIDTH SPACE from a Space Separator (Zs) + * to a Format Control (Cf). Since then, isWhitespace(0x200b) returns false. + * See http://www.unicode.org/versions/Unicode4.0.1/ * * Note: There are several ICU whitespace functions; please see the uchar.h * file documentation for a detailed comparison. @@ -2209,6 +2558,9 @@ u_charName(UChar32 code, UCharNameChoice nameChoice, * The ISO 10646 comment is an informative field in the Unicode Character * Database (UnicodeData.txt field 11) and is from the ISO 10646 names list. * + * Note: Unicode 5.2 removes all ISO comment data, resulting in empty strings + * returned for all characters. + * * @param c The character (code point) for which to get the ISO comment. * It must be <code>0<=c<=0x10ffff</code>. * @param dest Destination address for copying the comment. @@ -2273,7 +2625,7 @@ u_charFromName(UCharNameChoice nameChoice, * @see u_enumCharNames * @stable ICU 1.7 */ -typedef UBool UEnumCharNamesFn(void *context, +typedef UBool U_CALLCONV UEnumCharNamesFn(void *context, UChar32 code, UCharNameChoice nameChoice, const char *name, @@ -2439,7 +2791,7 @@ u_getPropertyValueName(UProperty property, * * @return a value integer or UCHAR_INVALID_CODE if the given name * does not match any value of the given property, or if the - * property is invalid. Note: U CHAR_GENERAL_CATEGORY values + * property is invalid. Note: UCHAR_GENERAL_CATEGORY_MASK values * are not values of UCharCategory, but rather mask values * produced by U_GET_GC_MASK(). This allows grouped * categories such as [:L:] to be represented. @@ -2501,11 +2853,9 @@ u_isIDPart(UChar32 c); * according to Java. * True for characters with general category "Cf" (format controls) as well as * non-whitespace ISO controls - * (U+0000..U+0008, U+000E..U+001B, U+007F..U+0084, U+0086..U+009F). + * (U+0000..U+0008, U+000E..U+001B, U+007F..U+009F). * - * Same as java.lang.Character.isIdentifierIgnorable() - * except that Java also returns TRUE for U+0085 Next Line - * (it omits U+0085 from whitespace ISO controls). + * Same as java.lang.Character.isIdentifierIgnorable(). * * Note that Unicode just recommends to ignore Cf (format controls). * @@ -2568,10 +2918,14 @@ u_isJavaIDPart(UChar32 c); * Same as java.lang.Character.toLowerCase(). * * This function only returns the simple, single-code point case mapping. - * Full case mappings may result in zero, one or more code points and depend - * on context or language etc. + * Full case mappings should be used whenever possible because they produce + * better results by working on whole strings. + * They take into account the string context and the language and can map + * to a result string with a different length as appropriate. * Full case mappings are applied by the string case mapping functions, * see ustring.h and the UnicodeString class. + * See also the User Guide chapter on C/POSIX migration: + * http://icu-project.org/userguide/posix.html#case_mappings * * @param c the code point to be mapped * @return the Simple_Lowercase_Mapping of the code point, if any; @@ -2589,10 +2943,14 @@ u_tolower(UChar32 c); * Same as java.lang.Character.toUpperCase(). * * This function only returns the simple, single-code point case mapping. - * Full case mappings may result in zero, one or more code points and depend - * on context or language etc. + * Full case mappings should be used whenever possible because they produce + * better results by working on whole strings. + * They take into account the string context and the language and can map + * to a result string with a different length as appropriate. * Full case mappings are applied by the string case mapping functions, * see ustring.h and the UnicodeString class. + * See also the User Guide chapter on C/POSIX migration: + * http://icu-project.org/userguide/posix.html#case_mappings * * @param c the code point to be mapped * @return the Simple_Uppercase_Mapping of the code point, if any; @@ -2610,10 +2968,14 @@ u_toupper(UChar32 c); * Same as java.lang.Character.toTitleCase(). * * This function only returns the simple, single-code point case mapping. - * Full case mappings may result in zero, one or more code points and depend - * on context or language etc. + * Full case mappings should be used whenever possible because they produce + * better results by working on whole strings. + * They take into account the string context and the language and can map + * to a result string with a different length as appropriate. * Full case mappings are applied by the string case mapping functions, * see ustring.h and the UnicodeString class. + * See also the User Guide chapter on C/POSIX migration: + * http://icu-project.org/userguide/posix.html#case_mappings * * @param c the code point to be mapped * @return the Simple_Titlecase_Mapping of the code point, if any; @@ -2651,10 +3013,14 @@ u_totitle(UChar32 c); * itself is returned. * * This function only returns the simple, single-code point case mapping. - * Full case mappings may result in zero, one or more code points and depend - * on context or language etc. + * Full case mappings should be used whenever possible because they produce + * better results by working on whole strings. + * They take into account the string context and the language and can map + * to a result string with a different length as appropriate. * Full case mappings are applied by the string case mapping functions, * see ustring.h and the UnicodeString class. + * See also the User Guide chapter on C/POSIX migration: + * http://icu-project.org/userguide/posix.html#case_mappings * * @param c the code point to be mapped * @param options Either U_FOLD_CASE_DEFAULT or U_FOLD_CASE_EXCLUDE_SPECIAL_I @@ -2768,6 +3134,7 @@ u_charAge(UChar32 c, UVersionInfo versionArray); U_STABLE void U_EXPORT2 u_getUnicodeVersion(UVersionInfo versionArray); +#if !UCONFIG_NO_NORMALIZATION /** * Get the FC_NFKC_Closure property string for a character. * See Unicode Standard Annex #15 for details, search for "FC_NFKC_Closure" @@ -2792,6 +3159,9 @@ u_getUnicodeVersion(UVersionInfo versionArray); U_STABLE int32_t U_EXPORT2 u_getFC_NFKC_Closure(UChar32 c, UChar *dest, int32_t destCapacity, UErrorCode *pErrorCode); +#endif + + U_CDECL_END #endif /*_UCHAR*/ diff --git a/Source/WTF/icu/unicode/ucnv.h b/Source/WTF/icu/unicode/ucnv.h index a042f7abd..98da8ff69 100644 --- a/Source/WTF/icu/unicode/ucnv.h +++ b/Source/WTF/icu/unicode/ucnv.h @@ -1,6 +1,6 @@ /* ********************************************************************** -* Copyright (C) 1999-2004, International Business Machines +* Copyright (C) 1999-2010, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************** * ucnv.h: @@ -35,12 +35,12 @@ * * <p>When a converter encounters an illegal, irregular, invalid or unmappable character * its default behavior is to use a substitution character to replace the - * bad byte sequence. This behavior can be changed by using {@link ucnv_getFromUCallBack() } - * or {@link ucnv_getToUCallBack() } on the converter. The header ucnv_err.h defines + * bad byte sequence. This behavior can be changed by using {@link ucnv_setFromUCallBack() } + * or {@link ucnv_setToUCallBack() } on the converter. The header ucnv_err.h defines * many other callback actions that can be used instead of a character substitution.</p> * * <p>More information about this API can be found in our - * <a href="http://oss.software.ibm.com/icu/userguide/conversion.html">User's + * <a href="http://icu-project.org/userguide/conversion.html">User's * Guide</a>.</p> */ @@ -49,6 +49,7 @@ #include "unicode/ucnv_err.h" #include "unicode/uenum.h" +#include "unicode/localpointer.h" #ifndef __USET_H__ @@ -151,6 +152,9 @@ typedef enum { * @param codeUnits Points to 'length' bytes of the concerned codepage sequence * @param length Size (in bytes) of the concerned codepage sequence * @param reason Defines the reason the callback was invoked + * @param pErrorCode ICU error code in/out parameter. + * For converter callback functions, set to a conversion error + * before the call, and the callback may reset it to U_ZERO_ERROR. * @see ucnv_setToUCallBack * @see UConverterToUnicodeArgs * @stable ICU 2.0 @@ -161,7 +165,7 @@ typedef void (U_EXPORT2 *UConverterToUCallback) ( const char *codeUnits, int32_t length, UConverterCallbackReason reason, - UErrorCode *); + UErrorCode *pErrorCode); /** * Function pointer for error callback in the unicode to codepage direction. @@ -172,6 +176,9 @@ typedef void (U_EXPORT2 *UConverterToUCallback) ( * @param length Size (in bytes) of the concerned codepage sequence * @param codePoint Single UChar32 (UTF-32) containing the concerend Unicode codepoint. * @param reason Defines the reason the callback was invoked + * @param pErrorCode ICU error code in/out parameter. + * For converter callback functions, set to a conversion error + * before the call, and the callback may reset it to U_ZERO_ERROR. * @see ucnv_setFromUCallBack * @stable ICU 2.0 */ @@ -182,7 +189,7 @@ typedef void (U_EXPORT2 *UConverterFromUCallback) ( int32_t length, UChar32 codePoint, UConverterCallbackReason reason, - UErrorCode *); + UErrorCode *pErrorCode); U_CDECL_END @@ -226,7 +233,10 @@ U_CDECL_END /** * Converter option for specifying a version selector (0..9) for some converters. - * For example, ucnv_open("UTF-7,version=1", &errorCode); + * For example, + * \code + * ucnv_open("UTF-7,version=1", &errorCode); + * \endcode * See convrtrs.txt. * * @see ucnv_open @@ -247,11 +257,13 @@ U_CDECL_END #define UCNV_SWAP_LFNL_OPTION_STRING ",swaplfnl" /** - * Do a fuzzy compare of a two converter/alias names. The comparison - * is case-insensitive. It also ignores the characters '-', '_', and - * ' ' (dash, underscore, and space). Thus the strings "UTF-8", - * "utf_8", and "Utf 8" are exactly equivalent. - * + * Do a fuzzy compare of two converter/alias names. + * The comparison is case-insensitive, ignores leading zeroes if they are not + * followed by further digits, and ignores all but letters and digits. + * Thus the strings "UTF-8", "utf_8", "u*T@f08" and "Utf 8" are exactly equivalent. + * See section 1.4, Charset Alias Matching in Unicode Technical Standard #22 + * at http://www.unicode.org/reports/tr22/ + * * @param name1 a converter name or alias, zero-terminated * @param name2 a converter name or alias, zero-terminated * @return 0 if the names match, or a negative value if the name1 @@ -264,11 +276,12 @@ ucnv_compareNames(const char *name1, const char *name2); /** - * Creates a UConverter object with the names specified as a C string. + * Creates a UConverter object with the name of a coded character set specified as a C string. * The actual name will be resolved with the alias file * using a case-insensitive string comparison that ignores - * the delimiters '-', '_', and ' ' (dash, underscore, and space). - * E.g., the names "UTF8", "utf-8", and "Utf 8" are all equivalent. + * leading zeroes and all non-alphanumeric characters. + * E.g., the names "UTF8", "utf-8", "u*T@f08" and "Utf 8" are all equivalent. + * (See also ucnv_compareNames().) * If <code>NULL</code> is passed for the converter name, it will create one with the * getDefaultName return value. * @@ -287,15 +300,27 @@ ucnv_compareNames(const char *name1, const char *name2); * * <p>The conversion behavior and names can vary between platforms. ICU may * convert some characters differently from other platforms. Details on this topic - * are in the <a href="http://oss.software.ibm.com/icu/userguide/conversion.html">User's - * Guide</a>.</p> - * - * @param converterName Name of the uconv table, may have options appended + * are in the <a href="http://icu-project.org/userguide/conversion.html">User's + * Guide</a>. Aliases starting with a "cp" prefix have no specific meaning + * other than its an alias starting with the letters "cp". Please do not + * associate any meaning to these aliases.</p> + * + * @param converterName Name of the coded character set table. + * This may have options appended to the string. + * IANA alias character set names, IBM CCSIDs starting with "ibm-", + * Windows codepage numbers starting with "windows-" are frequently + * used for this parameter. See ucnv_getAvailableName and + * ucnv_getAlias for a complete list that is available. + * If this parameter is NULL, the default converter will be used. * @param err outgoing error status <TT>U_MEMORY_ALLOCATION_ERROR, U_FILE_ACCESS_ERROR</TT> * @return the created Unicode converter object, or <TT>NULL</TT> if an error occured * @see ucnv_openU * @see ucnv_openCCSID + * @see ucnv_getAvailableName + * @see ucnv_getAlias + * @see ucnv_getDefaultName * @see ucnv_close + * @see ucnv_compareNames * @stable ICU 2.0 */ U_STABLE UConverter* U_EXPORT2 @@ -307,13 +332,16 @@ ucnv_open(const char *converterName, UErrorCode *err); * The name should be limited to the ASCII-7 alphanumerics range. * The actual name will be resolved with the alias file * using a case-insensitive string comparison that ignores - * the delimiters '-', '_', and ' ' (dash, underscore, and space). - * E.g., the names "UTF8", "utf-8", and "Utf 8" are all equivalent. + * leading zeroes and all non-alphanumeric characters. + * E.g., the names "UTF8", "utf-8", "u*T@f08" and "Utf 8" are all equivalent. + * (See also ucnv_compareNames().) * If <TT>NULL</TT> is passed for the converter name, it will create * one with the ucnv_getDefaultName() return value. * If the alias is ambiguous, then the preferred converter is used * and the status is set to U_AMBIGUOUS_ALIAS_WARNING. - * @param name : name of the uconv table in a zero terminated + * + * <p>See ucnv_open for the complete details</p> + * @param name Name of the UConverter table in a zero terminated * Unicode string * @param err outgoing error status <TT>U_MEMORY_ALLOCATION_ERROR, * U_FILE_ACCESS_ERROR</TT> @@ -322,7 +350,7 @@ ucnv_open(const char *converterName, UErrorCode *err); * @see ucnv_open * @see ucnv_openCCSID * @see ucnv_close - * @see ucnv_getDefaultName + * @see ucnv_compareNames * @stable ICU 2.0 */ U_STABLE UConverter* U_EXPORT2 @@ -404,7 +432,7 @@ ucnv_openCCSID(int32_t codepage, * <p>The packageName and converterName must point to an ICU udata object, as defined by * <code> udata_open( packageName, "cnv", converterName, err) </code> or equivalent. * Typically, packageName will refer to a (.dat) file, or to a package registered with - * udata_setAppData().</p> + * udata_setAppData(). Using a full file or directory pathname for packageName is deprecated.</p> * * <p>The name will NOT be looked up in the alias mechanism, nor will the converter be * stored in the converter cache or the alias table. The only way to open further converters @@ -432,18 +460,39 @@ U_STABLE UConverter* U_EXPORT2 ucnv_openPackage(const char *packageName, const char *converterName, UErrorCode *err); /** - * Thread safe cloning operation + * Thread safe converter cloning operation. + * For most efficient operation, pass in a stackBuffer (and a *pBufferSize) + * with at least U_CNV_SAFECLONE_BUFFERSIZE bytes of space. + * If the buffer size is sufficient, then the clone will use the stack buffer; + * otherwise, it will be allocated, and *pBufferSize will indicate + * the actual size. (This should not occur with U_CNV_SAFECLONE_BUFFERSIZE.) + * + * You must ucnv_close() the clone in any case. + * + * If *pBufferSize==0, (regardless of whether stackBuffer==NULL or not) + * then *pBufferSize will be changed to a sufficient size + * for cloning this converter, + * without actually cloning the converter ("pure pre-flighting"). + * + * If *pBufferSize is greater than zero but not large enough for a stack-based + * clone, then the converter is cloned using newly allocated memory + * and *pBufferSize is changed to the necessary size. + * + * If the converter clone fits into the stack buffer but the stack buffer is not + * sufficiently aligned for the clone, then the clone will use an + * adjusted pointer and use an accordingly smaller buffer size. + * * @param cnv converter to be cloned * @param stackBuffer user allocated space for the new clone. If NULL 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 enough to avoid memory allocations. - * @param pBufferSize pointer to size of allocated space. - * If *pBufferSize == 0, a sufficient size for use in cloning will - * be returned ('pre-flighting') - * If *pBufferSize is not enough for a stack-based safe clone, - * new memory will be allocated. + * @param pBufferSize pointer to size of allocated space. pBufferSize must not be NULL. * @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 necessary. + * An informational status value, U_SAFECLONE_ALLOCATED_WARNING, + * is used if any allocations were necessary. + * However, it is better to check if *pBufferSize grew for checking for + * allocations because warning codes can be overridden by subsequent + * function calls. * @return pointer to the new clone * @stable ICU 2.0 */ @@ -475,9 +524,30 @@ ucnv_safeClone(const UConverter *cnv, U_STABLE void U_EXPORT2 ucnv_close(UConverter * converter); +#if U_SHOW_CPLUSPLUS_API + +U_NAMESPACE_BEGIN + +/** + * \class LocalUConverterPointer + * "Smart pointer" class, closes a UConverter via ucnv_close(). + * For most methods see the LocalPointerBase base class. + * + * @see LocalPointerBase + * @see LocalPointer + * @stable ICU 4.4 + */ +U_DEFINE_LOCAL_OPEN_POINTER(LocalUConverterPointer, UConverter, ucnv_close); + +U_NAMESPACE_END + +#endif + /** * Fills in the output parameter, subChars, with the substitution characters * as multiple bytes. + * If ucnv_setSubstString() set a Unicode string because the converter is + * stateful, then subChars will be an empty string. * * @param converter the Unicode converter * @param subChars the subsitution characters @@ -486,6 +556,7 @@ ucnv_close(UConverter * converter); * @param err the outgoing error status code. * If the substitution character array is too small, an * <TT>U_INDEX_OUTOFBOUNDS_ERROR</TT> will be returned. + * @see ucnv_setSubstString * @see ucnv_setSubstChars * @stable ICU 2.0 */ @@ -498,12 +569,19 @@ ucnv_getSubstChars(const UConverter *converter, /** * Sets the substitution chars when converting from unicode to a codepage. The * substitution is specified as a string of 1-4 bytes, and may contain - * <TT>NULL</TT> byte. + * <TT>NULL</TT> bytes. + * The subChars must represent a single character. The caller needs to know the + * byte sequence of a valid character in the converter's charset. + * For some converters, for example some ISO 2022 variants, only single-byte + * substitution characters may be supported. + * The newer ucnv_setSubstString() function relaxes these limitations. + * * @param converter the Unicode converter * @param subChars the substitution character byte sequence we want set * @param len the number of bytes in subChars * @param err the error status code. <TT>U_INDEX_OUTOFBOUNDS_ERROR </TT> if * len is bigger than the maximum number of bytes allowed in subchars + * @see ucnv_setSubstString * @see ucnv_getSubstChars * @stable ICU 2.0 */ @@ -514,6 +592,39 @@ ucnv_setSubstChars(UConverter *converter, UErrorCode *err); /** + * Set a substitution string for converting from Unicode to a charset. + * The caller need not know the charset byte sequence for each charset. + * + * Unlike ucnv_setSubstChars() which is designed to set a charset byte sequence + * for a single character, this function takes a Unicode string with + * zero, one or more characters, and immediately verifies that the string can be + * converted to the charset. + * If not, or if the result is too long (more than 32 bytes as of ICU 3.6), + * then the function returns with an error accordingly. + * + * Also unlike ucnv_setSubstChars(), this function works for stateful charsets + * by converting on the fly at the point of substitution rather than setting + * a fixed byte sequence. + * + * @param cnv The UConverter object. + * @param s The Unicode string. + * @param length The number of UChars in s, or -1 for a NUL-terminated string. + * @param err Pointer to a standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * + * @see ucnv_setSubstChars + * @see ucnv_getSubstChars + * @stable ICU 3.6 + */ +U_STABLE void U_EXPORT2 +ucnv_setSubstString(UConverter *cnv, + const UChar *s, + int32_t length, + UErrorCode *err); + +/** * Fills in the output parameter, errBytes, with the error characters from the * last failing conversion. * @@ -634,8 +745,6 @@ ucnv_resetFromUnicode(UConverter *converter); U_STABLE int8_t U_EXPORT2 ucnv_getMaxCharSize(const UConverter *converter); -#ifndef U_HIDE_DRAFT_API - /** * Calculates the size of a buffer for conversion from Unicode to a charset. * The calculated size is guaranteed to be sufficient for this conversion. @@ -653,13 +762,11 @@ ucnv_getMaxCharSize(const UConverter *converter); * converting length UChars with the converter that returned the maxCharSize. * * @see ucnv_getMaxCharSize - * @draft ICU 2.8 + * @stable ICU 2.8 */ #define UCNV_GET_MAX_BYTES_FOR_STRING(length, maxCharSize) \ (((int32_t)(length)+10)*(int32_t)(maxCharSize)) -#endif /*U_HIDE_DRAFT_API*/ - /** * Returns the minimum byte length for characters in this codepage. * This is usually either 1 or 2. @@ -786,6 +893,8 @@ ucnv_getStarters(const UConverter* converter, typedef enum UConverterUnicodeSet { /** Select the set of roundtrippable Unicode code points. @stable ICU 2.6 */ UCNV_ROUNDTRIP_SET, + /** Select the set of Unicode code points with roundtrip or fallback mappings. @stable ICU 4.0 */ + UCNV_ROUNDTRIP_AND_FALLBACK_SET, /** Number of UConverterUnicodeSet selectors. @stable ICU 2.6 */ UCNV_SET_COUNT } UConverterUnicodeSet; @@ -794,11 +903,16 @@ typedef enum UConverterUnicodeSet { /** * Returns the set of Unicode code points that can be converted by an ICU converter. * - * The current implementation returns only one kind of set (UCNV_ROUNDTRIP_SET): + * Returns one of several kinds of set: + * + * 1. UCNV_ROUNDTRIP_SET + * * The set of all Unicode code points that can be roundtrip-converted - * (converted without any data loss) with the converter. + * (converted without any data loss) with the converter (ucnv_fromUnicode()). * This set will not include code points that have fallback mappings * or are only the result of reverse fallback mappings. + * This set will also not include PUA code points with fallbacks, although + * ucnv_fromUnicode() will always uses those mappings despite ucnv_setFallback(). * See UTR #22 "Character Mapping Markup Language" * at http://www.unicode.org/reports/tr22/ * @@ -809,6 +923,12 @@ typedef enum UConverterUnicodeSet { * by comparing its roundtrip set with the set of ExemplarCharacters from * ICU's locale data or other sources * + * 2. UCNV_ROUNDTRIP_AND_FALLBACK_SET + * + * The set of all Unicode code points that can be converted with the converter (ucnv_fromUnicode()) + * when fallbacks are turned on (see ucnv_setFallback()). + * This set includes all code points with roundtrips and fallbacks (but not reverse fallbacks). + * * In the future, there may be more UConverterUnicodeSet choices to select * sets with different properties. * @@ -1192,6 +1312,12 @@ ucnv_getNextUChar(UConverter * converter, * Internally, two conversions - ucnv_toUnicode() and ucnv_fromUnicode() - * are used, "pivoting" through 16-bit Unicode. * + * Important: For streaming conversion (multiple function calls for successive + * parts of a text stream), the caller must provide a pivot buffer explicitly, + * and must preserve the pivot buffer and associated pointers from one + * call to another. (The buffer may be moved if its contents and the relative + * pointer positions are preserved.) + * * There is a similar function, ucnv_convert(), * which has the following limitations: * - it takes charset names, not converter objects, so that @@ -1203,7 +1329,7 @@ ucnv_getNextUChar(UConverter * converter, * * By contrast, ucnv_convertEx() * - takes UConverter parameters instead of charset names - * - fully exposes the pivot buffer for complete error handling + * - fully exposes the pivot buffer for streaming conversion and complete error handling * * ucnv_convertEx() also provides further convenience: * - an option to reset the converters at the beginning @@ -1217,6 +1343,7 @@ ucnv_getNextUChar(UConverter * converter, * or set U_STRING_NOT_TERMINATED_WARNING if the output exactly fills * the target buffer * - the pivot buffer can be provided internally; + * possible only for whole-string conversion, not streaming conversion; * in this case, the caller will not be able to get details about where an * error occurred * (if pivotStart==NULL, see below) @@ -1255,10 +1382,13 @@ ucnv_getNextUChar(UConverter * converter, * return 0; * } * + * if(length<0) { + * length=strlen(s); + * } * target=u8; - * ucnv_convertEx(cnv, utf8Cnv, + * ucnv_convertEx(utf8Cnv, cnv, * &target, u8+capacity, - * &s, length>=0 ? s+length : NULL, + * &s, s+length, * NULL, NULL, NULL, NULL, * TRUE, TRUE, * pErrorCode); @@ -1675,11 +1805,15 @@ U_STABLE const char * U_EXPORT2 ucnv_getCanonicalName(const char *alias, const char *standard, UErrorCode *pErrorCode); /** - * returns the current default converter name. + * Returns the current default converter name. If you want to open + * a default converter, you do not need to use this function. + * It is faster if you pass a NULL argument to ucnv_open the + * default converter. * - * @return returns the current default converter name; - * if a default converter name cannot be determined, - * then <code>NULL</code> is returned. + * If U_CHARSET_IS_UTF8 is defined to 1 in utypes.h then this function + * always returns "UTF-8". + * + * @return returns the current default converter name. * Storage owned by the library * @see ucnv_setDefaultName * @stable ICU 2.0 @@ -1688,11 +1822,19 @@ U_STABLE const char * U_EXPORT2 ucnv_getDefaultName(void); /** - * sets the current default converter name. Caller must own the storage for 'name' - * and preserve it indefinitely. - * @param name the converter name to be the default (must exist). + * This function is not thread safe. DO NOT call this function when ANY ICU + * function is being used from more than one thread! This function sets the + * current default converter name. If this function needs to be called, it + * should be called during application initialization. Most of the time, the + * results from ucnv_getDefaultName() or ucnv_open with a NULL string argument + * is sufficient for your application. + * + * If U_CHARSET_IS_UTF8 is defined to 1 in utypes.h then this function + * does nothing. + * + * @param name the converter name to be the default (must be known by ICU). * @see ucnv_getDefaultName - * @system SYSTEM API + * @system * @stable ICU 2.0 */ U_STABLE void U_EXPORT2 @@ -1730,20 +1872,31 @@ U_STABLE UBool U_EXPORT2 ucnv_isAmbiguous(const UConverter *cnv); /** - * Sets the converter to use fallback mapping or not. + * Sets the converter to use fallback mappings or not. + * Regardless of this flag, the converter will always use + * fallbacks from Unicode Private Use code points, as well as + * reverse fallbacks (to Unicode). + * For details see ".ucm File Format" + * in the Conversion Data chapter of the ICU User Guide: + * http://www.icu-project.org/userguide/conversion-data.html#ucmformat + * * @param cnv The converter to set the fallback mapping usage on. * @param usesFallback TRUE if the user wants the converter to take advantage of the fallback * mapping, FALSE otherwise. * @stable ICU 2.0 + * @see ucnv_usesFallback */ U_STABLE void U_EXPORT2 ucnv_setFallback(UConverter *cnv, UBool usesFallback); /** * Determines if the converter uses fallback mappings or not. + * This flag has restrictions, see ucnv_setFallback(). + * * @param cnv The converter to be tested * @return TRUE if the converter uses fallback, FALSE otherwise. * @stable ICU 2.0 + * @see ucnv_setFallback */ U_STABLE UBool U_EXPORT2 ucnv_usesFallback(const UConverter *cnv); @@ -1769,7 +1922,7 @@ ucnv_usesFallback(const UConverter *cnv); * UErrorCode err = U_ZERO_ERROR; * char input[] = { '\xEF','\xBB', '\xBF','\x41','\x42','\x43' }; * int32_t signatureLength = 0; - * char *encoding = ucnv_detectUnicodeSignatures(input,sizeof(input),&signatureLength,&err); + * char *encoding = ucnv_detectUnicodeSignature(input,sizeof(input),&signatureLength,&err); * UConverter *conv = NULL; * UChar output[100]; * UChar *target = output, *out; @@ -1799,9 +1952,8 @@ ucnv_usesFallback(const UConverter *cnv); * @param signatureLength A pointer to int32_t to receive the number of bytes that make up the signature * of the detected UTF. 0 if not detected. * Can be a NULL pointer. - * @param pErrorCode A pointer to receive information about any errors that may occur during detection. - * Must be a valid pointer to an error code value, which must not indicate a failure - * before the function call. + * @param pErrorCode ICU error code in/out parameter. + * Must fulfill U_SUCCESS before the function call. * @return The name of the encoding detected. NULL if encoding is not detected. * @stable ICU 2.4 */ @@ -1811,6 +1963,34 @@ ucnv_detectUnicodeSignature(const char* source, int32_t *signatureLength, UErrorCode *pErrorCode); +/** + * Returns the number of UChars held in the converter's internal state + * because more input is needed for completing the conversion. This function is + * useful for mapping semantics of ICU's converter interface to those of iconv, + * and this information is not needed for normal conversion. + * @param cnv The converter in which the input is held + * @param status ICU error code in/out parameter. + * Must fulfill U_SUCCESS before the function call. + * @return The number of UChars in the state. -1 if an error is encountered. + * @stable ICU 3.4 + */ +U_STABLE int32_t U_EXPORT2 +ucnv_fromUCountPending(const UConverter* cnv, UErrorCode* status); + +/** + * Returns the number of chars held in the converter's internal state + * because more input is needed for completing the conversion. This function is + * useful for mapping semantics of ICU's converter interface to those of iconv, + * and this information is not needed for normal conversion. + * @param cnv The converter in which the input is held as internal state + * @param status ICU error code in/out parameter. + * Must fulfill U_SUCCESS before the function call. + * @return The number of chars in the state. -1 if an error is encountered. + * @stable ICU 3.4 + */ +U_STABLE int32_t U_EXPORT2 +ucnv_toUCountPending(const UConverter* cnv, UErrorCode* status); + #endif #endif diff --git a/Source/WTF/icu/unicode/ucnv_err.h b/Source/WTF/icu/unicode/ucnv_err.h index 2a6104c7e..e092e95f8 100644 --- a/Source/WTF/icu/unicode/ucnv_err.h +++ b/Source/WTF/icu/unicode/ucnv_err.h @@ -1,6 +1,6 @@ /* ********************************************************************** -* Copyright (C) 1999-2004, International Business Machines +* Copyright (C) 1999-2009, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************** * @@ -122,23 +122,30 @@ typedef struct UConverter UConverter; */ #define UCNV_ESCAPE_C "C" /** - * FROM_U_CALLBACK_ESCAPE context option to escape the code unit according to XML Decimal escape (&#DDDD;) - * TO_U_CALLBACK_ESCAPE context option to escape the character value accoding to XML Decimal escape (&#DDDD;) + * FROM_U_CALLBACK_ESCAPE context option to escape the code unit according to XML Decimal escape \htmlonly(&#DDDD;)\endhtmlonly + * TO_U_CALLBACK_ESCAPE context option to escape the character value accoding to XML Decimal escape \htmlonly(&#DDDD;)\endhtmlonly * @stable ICU 2.0 */ #define UCNV_ESCAPE_XML_DEC "D" /** - * FROM_U_CALLBACK_ESCAPE context option to escape the code unit according to XML Hex escape (&#xXXXX;) - * TO_U_CALLBACK_ESCAPE context option to escape the character value accoding to XML Hex escape (&#xXXXX;) + * FROM_U_CALLBACK_ESCAPE context option to escape the code unit according to XML Hex escape \htmlonly(&#xXXXX;)\endhtmlonly + * TO_U_CALLBACK_ESCAPE context option to escape the character value accoding to XML Hex escape \htmlonly(&#xXXXX;)\endhtmlonly * @stable ICU 2.0 */ #define UCNV_ESCAPE_XML_HEX "X" /** - * FROM_U_CALLBACK_ESCAPE context option to escape teh code unit according to Unicode (U+XXXXX) + * FROM_U_CALLBACK_ESCAPE context option to escape the code unit according to Unicode (U+XXXXX) * @stable ICU 2.0 */ #define UCNV_ESCAPE_UNICODE "U" +/** + * FROM_U_CALLBACK_ESCAPE context option to escape the code unit according to CSS2 conventions (\\HH..H<space>, that is, + * a backslash, 1..6 hex digits, and a space) + * @stable ICU 4.0 + */ +#define UCNV_ESCAPE_CSS2 "S" + /** * The process condition code to be used with the callbacks. * Codes which are greater than UCNV_IRREGULAR should be @@ -340,17 +347,17 @@ U_STABLE void U_EXPORT2 UCNV_FROM_U_CALLBACK_SUBSTITUTE ( * Note that codeUnit(32bit int eg: unit of a surrogate pair) is represented as * \\U00023456</li> * <li>UCNV_ESCAPE_XML_DEC: Substitues the ILLEGAL SEQUENCE with the decimal - * representation in the format &#DDDDDDDD;, e.g. "&#65534;&#172;&#51454;"). + * representation in the format \htmlonly&#DDDDDDDD;, e.g. "&#65534;&#172;&#51454;")\endhtmlonly. * In the Event the converter doesn't support the characters {&,#}[0-9], * it will substitute the illegal sequence with the substitution characters. * Note that codeUnit(32bit int eg: unit of a surrogate pair) is represented as * &#144470; and Zero padding is ignored.</li> * <li>UCNV_ESCAPE_XML_HEX:Substitues the ILLEGAL SEQUENCE with the decimal - * representation in the format &#xXXXX, e.g. "&#xFFFE;&#x00AC;&#xC8FE;"). + * representation in the format \htmlonly&#xXXXX; e.g. "&#xFFFE;&#x00AC;&#xC8FE;")\endhtmlonly. * In the Event the converter doesn't support the characters {&,#,x}[0-9], * it will substitute the illegal sequence with the substitution characters. * Note that codeUnit(32bit int eg: unit of a surrogate pair) is represented as - * &#x23456;</li> + * \htmlonly&#x23456;\endhtmlonly</li> * </ul> * @param fromUArgs Information about the conversion in progress * @param codeUnits Points to 'length' UChars of the concerned Unicode sequence diff --git a/Source/WTF/icu/unicode/ucol.h b/Source/WTF/icu/unicode/ucol.h index cbfb1c3dc..4a4cd606e 100644 --- a/Source/WTF/icu/unicode/ucol.h +++ b/Source/WTF/icu/unicode/ucol.h @@ -1,6 +1,6 @@ /* ******************************************************************************* -* Copyright (c) 1996-2005, International Business Machines Corporation and others. +* Copyright (c) 1996-2010, International Business Machines Corporation and others. * All Rights Reserved. ******************************************************************************* */ @@ -13,6 +13,7 @@ #if !UCONFIG_NO_COLLATION #include "unicode/unorm.h" +#include "unicode/localpointer.h" #include "unicode/parseerr.h" #include "unicode/uloc.h" #include "unicode/uset.h" @@ -29,11 +30,11 @@ * <em>Important: </em>The ICU collation service has been reimplemented * in order to achieve better performance and UCA compliance. * For details, see the - * <a href="http://icu.sourceforge.net/cvs/icu/~checkout~/icuhtml/design/collation/ICU_collation_design.htm"> + * <a href="http://source.icu-project.org/repos/icu/icuhtml/trunk/design/collation/ICU_collation_design.htm"> * collation design document</a>. * <p> * For more information about the collation service see - * <a href="http://icu.sourceforge.net/icu/userguide/Collate_Intro.html">the users guide</a>. + * <a href="http://icu-project.org/userguide/Collate_Intro.html">the users guide</a>. * <p> * Collation service provides correct sorting orders for most locales supported in ICU. * If specific data for a locale is not available, the orders eventually falls back @@ -41,7 +42,7 @@ * <p> * Sort ordering may be customized by providing your own set of rules. For more on * this subject see the - * <a href="http://icu.sourceforge.net/icu/userguide/Collate_Customization.html"> + * <a href="http://icu-project.org/userguide/Collate_Customization.html"> * Collation customization</a> section of the users guide. * <p> * @see UCollationResult @@ -50,15 +51,6 @@ * @see UCollationElements */ -/** A collation element iterator. -* For usage in C programs. -*/ -struct collIterate; -/** structure representing collation element iterator instance - * @stable ICU 2.0 - */ -typedef struct collIterate collIterate; - /** A collator. * For usage in C programs. */ @@ -140,6 +132,20 @@ typedef enum { } UColAttributeValue; +/** Enum containing the codes for reordering segments of the collation table that are not script + * codes. These reordering codes are to be used in conjunction with the script codes. + * @internal + */ +typedef enum { + UCOL_REORDER_CODE_SPACE = 0x1000, + UCOL_REORDER_CODE_FIRST = UCOL_REORDER_CODE_SPACE, + UCOL_REORDER_CODE_PUNCTUATION = 0x1001, + UCOL_REORDER_CODE_SYMBOL = 0x1002, + UCOL_REORDER_CODE_CURRENCY = 0x1003, + UCOL_REORDER_CODE_DIGIT = 0x1004, + UCOL_REORDER_CODE_LIMIT = 0x1005 +} UColReorderCode; + /** * Base letter represents a primary difference. Set comparison * level to UCOL_PRIMARY to ignore secondary and tertiary differences. @@ -149,7 +155,7 @@ typedef enum { * Diacritical differences on the same base letter represent a secondary * difference. Set comparison level to UCOL_SECONDARY to ignore tertiary * differences. Use this to set the strength of a Collator object. - * Example of secondary difference, "ä" >> "a". + * Example of secondary difference, "ä" >> "a". * * Uppercase and lowercase versions of the same character represents a * tertiary difference. Set comparison level to UCOL_TERTIARY to include @@ -159,7 +165,7 @@ typedef enum { * * Two characters are considered "identical" when they have the same * unicode spellings. UCOL_IDENTICAL. - * For example, "ä" == "ä". + * For example, "ä" == "ä". * * UCollationStrength is also used to determine the strength of sort keys * generated from UCollator objects @@ -173,12 +179,12 @@ typedef UColAttributeValue UCollationStrength; * @stable ICU 2.0 */ typedef enum { - /** Attribute for direction of secondary weights - used in French.\ + /** Attribute for direction of secondary weights - used in French. * Acceptable values are UCOL_ON, which results in secondary weights * being considered backwards and UCOL_OFF which treats secondary * weights in the order they appear.*/ UCOL_FRENCH_COLLATION, - /** Attribute for handling variable elements.\ + /** Attribute for handling variable elements. * Acceptable values are UCOL_NON_IGNORABLE (default) * which treats all the codepoints with non-ignorable * primary weights in the same way, @@ -187,7 +193,7 @@ typedef enum { * to be ignored on primary level and moved to the quaternary * level.*/ UCOL_ALTERNATE_HANDLING, - /** Controls the ordering of upper and lower case letters.\ + /** Controls the ordering of upper and lower case letters. * Acceptable values are UCOL_OFF (default), which orders * upper and lower case letters in accordance to their tertiary * weights, UCOL_UPPER_FIRST which forces upper case letters to @@ -195,45 +201,45 @@ typedef enum { * the opposite. */ UCOL_CASE_FIRST, /** Controls whether an extra case level (positioned before the third - * level) is generated or not.\ Acceptable values are UCOL_OFF (default), + * level) is generated or not. Acceptable values are UCOL_OFF (default), * when case level is not generated, and UCOL_ON which causes the case - * level to be generated.\ Contents of the case level are affected by - * the value of UCOL_CASE_FIRST attribute.\ A simple way to ignore + * level to be generated. Contents of the case level are affected by + * the value of UCOL_CASE_FIRST attribute. A simple way to ignore * accent differences in a string is to set the strength to UCOL_PRIMARY * and enable case level. */ UCOL_CASE_LEVEL, /** Controls whether the normalization check and necessary normalizations - * are performed.\ When set to UCOL_OFF (default) no normalization check - * is performed.\ The correctness of the result is guaranteed only if the - * input data is in so-called FCD form (see users manual for more info).\ - * When set to UCOL_ON, an incremental check is performed to see whether the input data - * is in the FCD form.\ If the data is not in the FCD form, incremental - * NFD normalization is performed. */ + * are performed. When set to UCOL_OFF (default) no normalization check + * is performed. The correctness of the result is guaranteed only if the + * input data is in so-called FCD form (see users manual for more info). + * When set to UCOL_ON, an incremental check is performed to see whether + * the input data is in the FCD form. If the data is not in the FCD form, + * incremental NFD normalization is performed. */ UCOL_NORMALIZATION_MODE, /** An alias for UCOL_NORMALIZATION_MODE attribute */ UCOL_DECOMPOSITION_MODE = UCOL_NORMALIZATION_MODE, - /** The strength attribute.\ Can be either UCOL_PRIMARY, UCOL_SECONDARY, - * UCOL_TERTIARY, UCOL_QUATERNARY or UCOL_IDENTICAL.\ The usual strength - * for most locales (except Japanese) is tertiary.\ Quaternary strength + /** The strength attribute. Can be either UCOL_PRIMARY, UCOL_SECONDARY, + * UCOL_TERTIARY, UCOL_QUATERNARY or UCOL_IDENTICAL. The usual strength + * for most locales (except Japanese) is tertiary. Quaternary strength * is useful when combined with shifted setting for alternate handling * attribute and for JIS x 4061 collation, when it is used to distinguish * 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 - * 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. */ UCOL_STRENGTH, - /** when turned on, this attribute - * positions Hiragana before all - * non-ignorables on quaternary level - * This is a sneaky way to produce JIS - * sort order */ + /** When turned on, this attribute positions Hiragana before all + * non-ignorables on quaternary level This is a sneaky way to produce JIS + * sort order */ UCOL_HIRAGANA_QUATERNARY_MODE, - /** when turned on, this attribute - * generates a collation key - * for the numeric value of substrings - * of digits. This is a way to get '100' - * to sort AFTER '2'.*/ + /** When turned on, this attribute generates a collation key + * for the numeric value of substrings of digits. + * 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 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 + * separate digit substring associated with a separate collation element. */ UCOL_NUMERIC_COLLATION, UCOL_ATTRIBUTE_COUNT } UColAttribute; @@ -286,7 +292,7 @@ ucol_open(const char *loc, UErrorCode *status); * occurred during parsing. This argument can currently be set * to NULL, but at users own risk. Please provide a real structure. * @param status A pointer to an UErrorCode to receive any errors - * @return A pointer to a UCollator.\ It is not guaranteed that NULL be returned in case + * @return A pointer to a UCollator. It is not guaranteed that NULL be returned in case * of error - please use status argument to check for errors. * @see ucol_open * @see ucol_safeClone @@ -305,7 +311,7 @@ ucol_openRules( const UChar *rules, * Open a collator defined by a short form string. * The structure and the syntax of the string is defined in the "Naming collators" * section of the users guide: - * http://icu.sourceforge.net/icu/userguide/Collate_Concepts.html#Naming_Collators + * http://icu-project.org/userguide/Collate_Concepts.html#Naming_Collators * Attributes are overriden by the subsequent attributes. So, for "S2_S3", final * strength will be 3. 3066bis locale overrides individual locale parts. * The call to this function is equivalent to a call to ucol_open, followed by a @@ -332,10 +338,10 @@ ucol_openRules( const UChar *rules, * @see ucol_setVariableTop * @see ucol_getShortDefinitionString * @see ucol_normalizeShortDefinitionString - * @draft ICU 3.0 + * @stable ICU 3.0 * */ -U_CAPI UCollator* U_EXPORT2 +U_STABLE UCollator* U_EXPORT2 ucol_openFromShortString( const char *definition, UBool forceDefaults, UParseError *parseError, @@ -352,18 +358,33 @@ ucol_openFromShortString( const char *definition, * @param status to hold the error code * @return the size of the contraction set * - * @draft ICU 3.0 + * @deprecated ICU 3.4, use ucol_getContractionsAndExpansions instead */ -U_CAPI int32_t U_EXPORT2 +U_DEPRECATED int32_t U_EXPORT2 ucol_getContractions( const UCollator *coll, USet *conts, UErrorCode *status); +/** + * Get a set containing the expansions defined by the collator. The set includes + * both the UCA expansions and the expansions defined by the tailoring + * @param coll collator + * @param contractions if not NULL, the set to hold the contractions + * @param expansions if not NULL, the set to hold the expansions + * @param addPrefixes add the prefix contextual elements to contractions + * @param status to hold the error code + * + * @stable ICU 3.4 + */ +U_STABLE void U_EXPORT2 +ucol_getContractionsAndExpansions( const UCollator *coll, + USet *contractions, USet *expansions, + UBool addPrefixes, UErrorCode *status); /** * Close a UCollator. - * Once closed, a UCollator should not be used.\ Every open collator should - * be closed.\ Otherwise, a memory leak will result. + * Once closed, a UCollator should not be used. Every open collator should + * be closed. Otherwise, a memory leak will result. * @param coll The UCollator to close. * @see ucol_open * @see ucol_openRules @@ -373,6 +394,25 @@ ucol_getContractions( const UCollator *coll, U_STABLE void U_EXPORT2 ucol_close(UCollator *coll); +#if U_SHOW_CPLUSPLUS_API + +U_NAMESPACE_BEGIN + +/** + * \class LocalUCollatorPointer + * "Smart pointer" class, closes a UCollator via ucol_close(). + * For most methods see the LocalPointerBase base class. + * + * @see LocalPointerBase + * @see LocalPointer + * @stable ICU 4.4 + */ +U_DEFINE_LOCAL_OPEN_POINTER(LocalUCollatorPointer, UCollator, ucol_close); + +U_NAMESPACE_END + +#endif + /** * Compare two strings. * The strings will be compared using the options already specified. @@ -496,6 +536,37 @@ ucol_setStrength(UCollator *coll, UCollationStrength strength); /** + * Get the current reordering of scripts (if one has been set). + * @param coll The UCollator to query. + * @param dest The array to fill with the script ordering. + * @param destCapacity The length of dest. If it is 0, then dest may be NULL and the function will only return the length of the result without writing any of the result string (pre-flighting). + * @param pErrorCode Must be a valid pointer to an error code value, which must not indicate a failure before the function call. + * @return The length of the array of the script ordering. + * @see ucol_setReorderCodes + * @internal + */ +U_INTERNAL int32_t U_EXPORT2 +ucol_getReorderCodes(const UCollator* coll, + int32_t* dest, + int32_t destCapacity, + UErrorCode *pErrorCode); + +/** + * Set the ordering of scripts for this collator. + * @param coll The UCollator to set. + * @param reorderCodes An array of script codes in the new order. + * @param reorderCodesLength The length of reorderCodes. + * @param pErrorCode Must be a valid pointer to an error code value, which must not indicate a failure before the function call. + * @see ucol_getReorderCodes + * @internal + */ +U_INTERNAL void U_EXPORT2 +ucol_setReorderCodes(UCollator* coll, + const int32_t* reorderCodes, + int32_t reorderCodesLength, + UErrorCode *pErrorCode); + +/** * Get the display name for a UCollator. * The display name is suitable for presentation to a user. * @param objLoc The locale of the collator in question. @@ -518,13 +589,13 @@ ucol_getDisplayName( const char *objLoc, * Get a locale for which collation rules are available. * A UCollator in a locale returned by this function will perform the correct * collation for the locale. - * @param index The index of the desired locale. + * @param localeIndex The index of the desired locale. * @return A locale for which collation rules are available, or 0 if none. * @see ucol_countAvailable * @stable ICU 2.0 */ U_STABLE const char* U_EXPORT2 -ucol_getAvailable(int32_t index); +ucol_getAvailable(int32_t localeIndex); /** * Determine how many locales have collation rules available. @@ -544,9 +615,9 @@ ucol_countAvailable(void); * @param status input-output error code * @return a string enumeration over locale strings. The caller is * responsible for closing the result. - * @draft ICU 3.0 + * @stable ICU 3.0 */ -U_DRAFT UEnumeration* U_EXPORT2 +U_STABLE UEnumeration* U_EXPORT2 ucol_openAvailableLocales(UErrorCode *status); #endif @@ -557,9 +628,9 @@ ucol_openAvailableLocales(UErrorCode *status); * @param status input-output error code * @return a string enumeration over locale strings. The caller is * responsible for closing the result. - * @draft ICU 3.0 + * @stable ICU 3.0 */ -U_DRAFT UEnumeration* U_EXPORT2 +U_STABLE UEnumeration* U_EXPORT2 ucol_getKeywords(UErrorCode *status); /** @@ -571,12 +642,34 @@ ucol_getKeywords(UErrorCode *status); * @param status input-output error code * @return a string enumeration over collation keyword values, or NULL * upon error. The caller is responsible for closing the result. - * @draft ICU 3.0 + * @stable ICU 3.0 */ -U_DRAFT UEnumeration* U_EXPORT2 +U_STABLE UEnumeration* U_EXPORT2 ucol_getKeywordValues(const char *keyword, UErrorCode *status); /** + * Given a key and a locale, returns an array of string values in a preferred + * order that would make a difference. These are all and only those values where + * the open (creation) of the service with the locale formed from the input locale + * plus input keyword and that value has different behavior than creation with the + * input locale alone. + * @param key one of the keys supported by this service. For now, only + * "collation" is supported. + * @param locale the locale + * @param commonlyUsed if set to true it will return only commonly used values + * with the given locale in preferred order. Otherwise, + * it will return all the available values for the locale. + * @param status error status + * @return a string enumeration over keyword values for the given key and the locale. + * @stable ICU 4.2 + */ +U_STABLE UEnumeration* U_EXPORT2 +ucol_getKeywordValuesForLocale(const char* key, + const char* locale, + UBool commonlyUsed, + UErrorCode* status); + +/** * Return the functionally equivalent locale for the given * requested locale, with respect to given keyword, for the * collation service. If two locales return the same result, then @@ -589,7 +682,7 @@ ucol_getKeywordValues(const char *keyword, UErrorCode *status); * applications who wish to cache collators, or otherwise reuse * collators when possible. The functional equivalent may change * over time. For more information, please see the <a - * href="http://icu.sourceforge.net/icu/userguide/locale.html#services"> + * href="http://icu-project.org/userguide/locale.html#services"> * Locales and Services</a> section of the ICU User Guide. * @param result fillin for the functionally equivalent locale * @param resultCapacity capacity of the fillin buffer @@ -604,9 +697,9 @@ ucol_getKeywordValues(const char *keyword, UErrorCode *status); * @return the actual buffer size needed for the locale. If greater * than resultCapacity, the returned full name will be truncated and * an error code will be returned. - * @draft ICU 3.0 + * @stable ICU 3.0 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 ucol_getFunctionalEquivalent(char* result, int32_t resultCapacity, const char* keyword, const char* locale, UBool* isAvailable, UErrorCode* status); @@ -629,7 +722,7 @@ ucol_getRules( const UCollator *coll, * This string will be normalized. * The structure and the syntax of the string is defined in the "Naming collators" * section of the users guide: - * http://icu.sourceforge.net/icu/userguide/Collate_Concepts.html#Naming_Collators + * http://icu-project.org/userguide/Collate_Concepts.html#Naming_Collators * This API supports preflighting. * @param coll a collator * @param locale a locale that will appear as a collators locale in the resulting @@ -641,9 +734,9 @@ ucol_getRules( const UCollator *coll, * @return length of the resulting string * @see ucol_openFromShortString * @see ucol_normalizeShortDefinitionString - * @draft ICU 3.0 + * @stable ICU 3.0 */ -U_CAPI int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 ucol_getShortDefinitionString(const UCollator *coll, const char *locale, char *buffer, @@ -667,26 +760,33 @@ ucol_getShortDefinitionString(const UCollator *coll, * @see ucol_openFromShortString * @see ucol_getShortDefinitionString * - * @draft ICU 3.0 + * @stable ICU 3.0 */ -U_CAPI int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 ucol_normalizeShortDefinitionString(const char *source, char *destination, int32_t capacity, UParseError *parseError, UErrorCode *status); - + /** * Get a sort key for a string from a UCollator. * Sort keys may be compared using <TT>strcmp</TT>. + * + * Like ICU functions that write to an output buffer, the buffer contents + * is undefined if the buffer capacity (resultLength parameter) is too small. + * Unlike ICU functions that write a string to an output buffer, + * the terminating zero byte is counted in the sort key length. * @param coll The UCollator containing the collation rules. * @param source The string to transform. * @param sourceLength The length of source, or -1 if null-terminated. * @param result A pointer to a buffer to receive the attribute. * @param resultLength The maximum size of result. - * @return The size needed to fully store the sort key.. + * @return The size needed to fully store the sort key. + * If there was an internal error generating the sort key, + * a zero value is returned. * @see ucol_keyHashCode * @stable ICU 2.0 */ @@ -804,9 +904,9 @@ ucol_getVersion(const UCollator* coll, UVersionInfo info); * UCA version number (3.1.1, 4.0). * @param coll The UCollator to query. * @param info the version # information, the result will be filled in - * @draft ICU 2.8 + * @stable ICU 2.8 */ -U_DRAFT void U_EXPORT2 +U_STABLE void U_EXPORT2 ucol_getUCAVersion(const UCollator* coll, UVersionInfo info); /** @@ -992,9 +1092,9 @@ ucol_getLocale(const UCollator *coll, ULocDataLocaleType type, UErrorCode *statu * @return real locale name from which the collation data comes. * If the collator was instantiated from rules, returns * NULL. - * @draft ICU 2.8 likely to change in ICU 3.0, based on feedback + * @stable ICU 2.8 */ -U_DRAFT const char * U_EXPORT2 +U_STABLE const char * U_EXPORT2 ucol_getLocaleByType(const UCollator *coll, ULocDataLocaleType type, UErrorCode *status); /** @@ -1011,97 +1111,6 @@ U_STABLE USet * U_EXPORT2 ucol_getTailoredSet(const UCollator *coll, UErrorCode *status); /** - * Returned by ucol_collatorToIdentifier to signify that collator is - * not encodable as an identifier. - * @internal ICU 3.0 - */ -#define UCOL_SIT_COLLATOR_NOT_ENCODABLE 0x80000000 - -/** - * Get a 31-bit identifier given a collator. - * @param coll UCollator - * @param locale a locale that will appear as a collators locale in the resulting - * short string definition. If NULL, the locale will be harvested - * from the collator. - * @param status holds error messages - * @return 31-bit identifier. MSB is used if the collator cannot be encoded. In that - * case UCOL_SIT_COLLATOR_NOT_ENCODABLE is returned - * @see ucol_openFromIdentifier - * @see ucol_identifierToShortString - * @internal ICU 3.0 - */ -U_INTERNAL uint32_t U_EXPORT2 -ucol_collatorToIdentifier(const UCollator *coll, - const char *locale, - UErrorCode *status); - -/** - * Open a collator given a 31-bit identifier - * @param identifier 31-bit identifier, encoded by calling ucol_collatorToIdentifier - * @param forceDefaults if FALSE, the settings that are the same as the collator - * default settings will not be applied (for example, setting - * French secondary on a French collator would not be executed). - * If TRUE, all the settings will be applied regardless of the - * collator default value. If the definition - * strings that can be produced from a collator instantiated by - * calling this API are to be cached, should be set to FALSE. - * @param status for returning errors - * @return UCollator object - * @see ucol_collatorToIdentifier - * @see ucol_identifierToShortString - * @internal ICU 3.0 - */ -U_INTERNAL UCollator* U_EXPORT2 -ucol_openFromIdentifier(uint32_t identifier, - UBool forceDefaults, - UErrorCode *status); - - -/** - * Calculate the short definition string given an identifier. Supports preflighting. - * @param identifier 31-bit identifier, encoded by calling ucol_collatorToIdentifier - * @param buffer buffer to store the result - * @param capacity buffer capacity - * @param forceDefaults whether the settings that are the same as the default setting - * should be forced anyway. Setting this argument to FALSE reduces - * the number of different configurations, but decreases performace - * as a collator has to be instantiated. - * @param status for returning errors - * @return length of the short definition string - * @see ucol_collatorToIdentifier - * @see ucol_openFromIdentifier - * @see ucol_shortStringToIdentifier - * @internal ICU 3.0 - */ -U_INTERNAL int32_t U_EXPORT2 -ucol_identifierToShortString(uint32_t identifier, - char *buffer, - int32_t capacity, - UBool forceDefaults, - UErrorCode *status); - -/** - * Calculate the identifier given a short definition string. Supports preflighting. - * @param definition short string definition - * @param forceDefaults whether the settings that are the same as the default setting - * should be forced anyway. Setting this argument to FALSE reduces - * the number of different configurations, but decreases performace - * as a collator has to be instantiated. - * @param status for returning errors - * @return identifier - * @see ucol_collatorToIdentifier - * @see ucol_openFromIdentifier - * @see ucol_identifierToShortString - * @internal ICU 3.0 - */ -U_INTERNAL uint32_t U_EXPORT2 -ucol_shortStringToIdentifier(const char *definition, - UBool forceDefaults, - UErrorCode *status); - - - -/** * Universal attribute getter that returns UCOL_DEFAULT if the value is default * @param coll collator which attributes are to be changed * @param attr attribute type @@ -1183,9 +1192,9 @@ ucol_prepareShortStringOpen( const char *definition, * @param status for catching errors * @return size of the image * @see ucol_openBinary - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 ucol_cloneBinary(const UCollator *coll, uint8_t *buffer, int32_t capacity, UErrorCode *status); @@ -1205,9 +1214,9 @@ ucol_cloneBinary(const UCollator *coll, * @param status for catching errors * @return newly created collator * @see ucol_cloneBinary - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT UCollator* U_EXPORT2 +U_STABLE UCollator* U_EXPORT2 ucol_openBinary(const uint8_t *bin, int32_t length, const UCollator *base, UErrorCode *status); @@ -1216,4 +1225,3 @@ ucol_openBinary(const uint8_t *bin, int32_t length, #endif /* #if !UCONFIG_NO_COLLATION */ #endif - diff --git a/Source/WTF/icu/unicode/uconfig.h b/Source/WTF/icu/unicode/uconfig.h index 997cf686b..7d2d26e95 100644 --- a/Source/WTF/icu/unicode/uconfig.h +++ b/Source/WTF/icu/unicode/uconfig.h @@ -1,6 +1,6 @@ /* ********************************************************************** -* Copyright (C) 2002-2004, International Business Machines +* Copyright (C) 2002-2009, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************** * file name: uconfig.h @@ -15,6 +15,7 @@ #ifndef __UCONFIG_H__ #define __UCONFIG_H__ + /*! * \file * \brief Switches for excluding parts of ICU library code modules. @@ -24,17 +25,35 @@ * The switches are fairly coarse, controlling large modules. * Basic services cannot be turned off. * + * Building with any of these options does not guarantee that the + * ICU build process will completely work. It is recommended that + * the ICU libraries and data be built using the normal build. + * At that time you should remove the data used by those services. + * After building the ICU data library, you should rebuild the ICU + * libraries with these switches customized to your needs. + * * @stable ICU 2.4 */ /** + * If this switch is defined, ICU will attempt to load a header file named "uconfig_local.h" + * prior to determining default settings for uconfig variables. + * + * @internal ICU 4.0 + * + */ +#if defined(UCONFIG_USE_LOCAL) +#include "uconfig_local.h" +#endif + +/** * \def UCONFIG_ONLY_COLLATION * This switch turns off modules that are not needed for collation. * * It does not turn off legacy conversion because that is necessary * for ICU to work on EBCDIC platforms (for the default converter). * If you want "only collation" and do not build for EBCDIC, - * then you can #define UCONFIG_NO_LEGACY_CONVERSION 1 as well. + * then you can define UCONFIG_NO_LEGACY_CONVERSION 1 as well. * * @stable ICU 2.4 */ @@ -59,11 +78,37 @@ /* common library switches -------------------------------------------------- */ /** + * \def UCONFIG_NO_FILE_IO + * This switch turns off all file access in the common library + * where file access is only used for data loading. + * ICU data must then be provided in the form of a data DLL (or with an + * equivalent way to link to the data residing in an executable, + * as in building a combined library with both the common library's code and + * the data), or via udata_setCommonData(). + * Application data must be provided via udata_setAppData() or by using + * "open" functions that take pointers to data, for example ucol_openBinary(). + * + * File access is not used at all in the i18n library. + * + * File access cannot be turned off for the icuio library or for the ICU + * test suites and ICU tools. + * + * @stable ICU 3.6 + */ +#ifndef UCONFIG_NO_FILE_IO +# define UCONFIG_NO_FILE_IO 0 +#endif + +/** * \def UCONFIG_NO_CONVERSION * ICU will not completely build with this switch turned on. * This switch turns off all converters. * - * @draft ICU 3.2 + * You may want to use this together with U_CHARSET_IS_UTF8 defined to 1 + * in utypes.h if char* strings in your environment are always in UTF-8. + * + * @stable ICU 3.2 + * @see U_CHARSET_IS_UTF8 */ #ifndef UCONFIG_NO_CONVERSION # define UCONFIG_NO_CONVERSION 0 @@ -177,10 +222,10 @@ * \def UCONFIG_NO_SERVICE * This switch turns off service registration. * - * @draft ICU 3.2 + * @stable ICU 3.2 */ #ifndef UCONFIG_NO_SERVICE -# define UCONFIG_NO_SERVICE 0 +# define UCONFIG_NO_SERVICE 1 #endif #endif diff --git a/Source/WTF/icu/unicode/uenum.h b/Source/WTF/icu/unicode/uenum.h index 63690f8b2..0e7d90cc5 100644 --- a/Source/WTF/icu/unicode/uenum.h +++ b/Source/WTF/icu/unicode/uenum.h @@ -1,7 +1,7 @@ /* ******************************************************************************* * -* Copyright (C) 2002-2004, International Business Machines +* Copyright (C) 2002-2010, International Business Machines * Corporation and others. All Rights Reserved. * ******************************************************************************* @@ -18,8 +18,18 @@ #define __UENUM_H #include "unicode/utypes.h" +#include "unicode/localpointer.h" + +#if U_SHOW_CPLUSPLUS_API +#include "unicode/strenum.h" +#endif /** + * \file + * \brief C API: String Enumeration + */ + +/** * An enumeration object. * For usage in C programs. * @stable ICU 2.2 @@ -38,6 +48,25 @@ typedef struct UEnumeration UEnumeration; U_STABLE void U_EXPORT2 uenum_close(UEnumeration* en); +#if U_SHOW_CPLUSPLUS_API + +U_NAMESPACE_BEGIN + +/** + * \class LocalUEnumerationPointer + * "Smart pointer" class, closes a UEnumeration via uenum_close(). + * For most methods see the LocalPointerBase base class. + * + * @see LocalPointerBase + * @see LocalPointer + * @stable ICU 4.4 + */ +U_DEFINE_LOCAL_OPEN_POINTER(LocalUEnumerationPointer, UEnumeration, uenum_close); + +U_NAMESPACE_END + +#endif + /** * Returns the number of elements that the iterator traverses. If * the iterator is out-of-sync with its service, status is set to @@ -126,4 +155,20 @@ uenum_next(UEnumeration* en, U_STABLE void U_EXPORT2 uenum_reset(UEnumeration* en, UErrorCode* status); +#if U_SHOW_CPLUSPLUS_API + +/** + * Given a StringEnumeration, wrap it in a UEnumeration. The + * StringEnumeration is adopted; after this call, the caller must not + * delete it (regardless of error status). + * @param adopted the C++ StringEnumeration to be wrapped in a UEnumeration. + * @param ec the error code. + * @return a UEnumeration wrapping the adopted StringEnumeration. + * @draft ICU 4.2 + */ +U_CAPI UEnumeration* U_EXPORT2 +uenum_openFromStringEnumeration(U_NAMESPACE_QUALIFIER StringEnumeration* adopted, UErrorCode* ec); + +#endif + #endif diff --git a/Source/WTF/icu/unicode/uiter.h b/Source/WTF/icu/unicode/uiter.h index 963df5cf9..b469e24e6 100644 --- a/Source/WTF/icu/unicode/uiter.h +++ b/Source/WTF/icu/unicode/uiter.h @@ -1,7 +1,7 @@ /* ******************************************************************************* * -* Copyright (C) 2002-2004, International Business Machines +* Copyright (C) 2002-2006,2009 International Business Machines * Corporation and others. All Rights Reserved. * ******************************************************************************* @@ -26,7 +26,7 @@ #include "unicode/utypes.h" -#ifdef XP_CPLUSPLUS +#if U_SHOW_CPLUSPLUS_API U_NAMESPACE_BEGIN class CharacterIterator; @@ -650,7 +650,7 @@ uiter_setUTF16BE(UCharIterator *iter, const char *s, int32_t length); U_STABLE void U_EXPORT2 uiter_setUTF8(UCharIterator *iter, const char *s, int32_t length); -#ifdef XP_CPLUSPLUS +#if U_SHOW_CPLUSPLUS_API /** * Set up a UCharIterator to wrap around a C++ CharacterIterator. @@ -673,7 +673,7 @@ uiter_setUTF8(UCharIterator *iter, const char *s, int32_t length); * @stable ICU 2.1 */ U_STABLE void U_EXPORT2 -uiter_setCharacterIterator(UCharIterator *iter, CharacterIterator *charIter); +uiter_setCharacterIterator(UCharIterator *iter, U_NAMESPACE_QUALIFIER CharacterIterator *charIter); /** * Set up a UCharIterator to iterate over a C++ Replaceable. @@ -698,7 +698,7 @@ uiter_setCharacterIterator(UCharIterator *iter, CharacterIterator *charIter); * @stable ICU 2.1 */ U_STABLE void U_EXPORT2 -uiter_setReplaceable(UCharIterator *iter, const Replaceable *rep); +uiter_setReplaceable(UCharIterator *iter, const U_NAMESPACE_QUALIFIER Replaceable *rep); #endif diff --git a/Source/WTF/icu/unicode/uloc.h b/Source/WTF/icu/unicode/uloc.h index f584ec1c3..95758c3a3 100644 --- a/Source/WTF/icu/unicode/uloc.h +++ b/Source/WTF/icu/unicode/uloc.h @@ -1,6 +1,6 @@ /* ********************************************************************** -* Copyright (C) 1997-2004, International Business Machines +* Copyright (C) 1997-2010, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************** * @@ -256,51 +256,68 @@ #define ULOC_COUNTRY_CAPACITY 4 /** * Useful constant for the maximum size of the whole locale ID - * (including the terminating NULL). + * (including the terminating NULL and all keywords). * @stable ICU 2.0 */ -#define ULOC_FULLNAME_CAPACITY 56 - - -#ifndef U_HIDE_DRAFT_API +#define ULOC_FULLNAME_CAPACITY 157 /** * Useful constant for the maximum size of the script part of a locale ID * (including the terminating NULL). - * @draft ICU 2.8 + * @stable ICU 2.8 */ #define ULOC_SCRIPT_CAPACITY 6 /** * Useful constant for the maximum size of keywords in a locale - * @draft ICU 2.8 + * @stable ICU 2.8 */ #define ULOC_KEYWORDS_CAPACITY 50 /** - * Useful constant for the maximum size of keywords in a locale - * @draft ICU 2.8 + * Useful constant for the maximum total size of keywords and their values in a locale + * @stable ICU 2.8 */ #define ULOC_KEYWORD_AND_VALUES_CAPACITY 100 /** - * Character separating keywords from the locale string - * different for EBCDIC - TODO - * @draft ICU 2.8 + * Invariant character separating keywords from the locale string + * @stable ICU 2.8 */ #define ULOC_KEYWORD_SEPARATOR '@' + /** - * Character for assigning value to a keyword - * @draft ICU 2.8 + * Unicode code point for '@' separating keywords from the locale string. + * @see ULOC_KEYWORD_SEPARATOR + * @draft ICU 4.6 + */ +#define ULOC_KEYWORD_SEPARATOR_UNICODE 0x40 + +/** + * Invariant character for assigning value to a keyword + * @stable ICU 2.8 */ #define ULOC_KEYWORD_ASSIGN '=' + /** - * Character separating keywords - * @draft ICU 2.8 + * Unicode code point for '=' for assigning value to a keyword. + * @see ULOC_KEYWORD_ASSIGN + * @draft ICU 4.6 + */ +#define ULOC_KEYWORD_ASSIGN_UNICODE 0x3D + +/** + * Invariant character separating keywords + * @stable ICU 2.8 */ #define ULOC_KEYWORD_ITEM_SEPARATOR ';' -#endif /*U_HIDE_DRAFT_API*/ +/** + * Unicode code point for ';' separating keywords + * @see ULOC_KEYWORD_ITEM_SEPARATOR + * @draft ICU 4.6 + */ +#define ULOC_KEYWORD_ITEM_SEPARATOR_UNICODE 0x3B /** * Constants for *_getLocale() @@ -333,7 +350,7 @@ typedef enum { ULOC_REQUESTED_LOCALE = 2, #endif /* U_HIDE_DEPRECATED_API */ - ULOC_DATA_LOCALE_TYPE_LIMIT + ULOC_DATA_LOCALE_TYPE_LIMIT = 3 } ULocDataLocaleType ; @@ -400,9 +417,9 @@ uloc_getLanguage(const char* localeID, * @param err error information if retrieving the language code failed * @return the actual buffer size needed for the language code. If it's greater * than scriptCapacity, the returned language code will be truncated. - * @draft ICU 2.8 + * @stable ICU 2.8 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uloc_getScript(const char* localeID, char* script, int32_t scriptCapacity, @@ -420,7 +437,7 @@ uloc_getScript(const char* localeID, * than countryCapacity, the returned country code will be truncated. * @stable ICU 2.0 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uloc_getCountry(const char* localeID, char* country, int32_t countryCapacity, @@ -482,9 +499,9 @@ uloc_getName(const char* localeID, * @param err error information if retrieving the full name failed * @return the actual buffer size needed for the full name. If it's greater * than nameCapacity, the returned full name will be truncated. - * @draft ICU 2.8 + * @stable ICU 2.8 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uloc_canonicalize(const char* localeID, char* name, int32_t nameCapacity, @@ -559,9 +576,9 @@ uloc_getDisplayLanguage(const char* locale, * @param status error information if retrieving the displayable script code failed * @return the actual buffer size needed for the displayable script code. If it's greater * than scriptCapacity, the returned displayable script code will be truncated. - * @draft ICU 2.8 + * @stable ICU 2.8 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uloc_getDisplayScript(const char* locale, const char* displayLocale, UChar* script, @@ -653,9 +670,9 @@ uloc_getDisplayVariant(const char* locale, * Should not be NULL and should not indicate failure on entry. * @return the actual buffer size needed for the displayable variant code. * @see #uloc_openKeywords - * @draft ICU 2.8 + * @stable ICU 2.8 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uloc_getDisplayKeyword(const char* keyword, const char* displayLocale, UChar* dest, @@ -679,9 +696,9 @@ uloc_getDisplayKeyword(const char* keyword, * @param status error information if retrieving the displayable string failed. * Should not be NULL and must not indicate failure on entry. * @return the actual buffer size needed for the displayable variant code. - * @draft ICU 2.8 + * @stable ICU 2.8 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uloc_getDisplayKeywordValue( const char* locale, const char* keyword, const char* displayLocale, @@ -796,9 +813,9 @@ uloc_getParent(const char* localeID, * @param err error information if retrieving the full name failed * @return the actual buffer size needed for the full name. If it's greater * than nameCapacity, the returned full name will be truncated. - * @draft ICU 2.8 + * @stable ICU 2.8 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uloc_getBaseName(const char* localeID, char* name, int32_t nameCapacity, @@ -811,9 +828,9 @@ uloc_getBaseName(const char* localeID, * @param localeID the locale to get the variant code with * @param status error information if retrieving the keywords failed * @return enumeration of keywords or NULL if there are no keywords. - * @draft ICU 2.8 + * @stable ICU 2.8 */ -U_DRAFT UEnumeration* U_EXPORT2 +U_STABLE UEnumeration* U_EXPORT2 uloc_openKeywords(const char* localeID, UErrorCode* status); @@ -826,9 +843,9 @@ uloc_openKeywords(const char* localeID, * @param bufferCapacity capacity of receiving buffer * @param status containing error code - buffer not big enough. * @return the length of keyword value - * @draft ICU 2.8 + * @stable ICU 2.8 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uloc_getKeywordValue(const char* localeID, const char* keywordName, char* buffer, int32_t bufferCapacity, @@ -852,19 +869,56 @@ uloc_getKeywordValue(const char* localeID, * @param status containing error code - buffer not big enough. * @return the length needed for the buffer * @see uloc_getKeywordValue - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uloc_setKeywordValue(const char* keywordName, const char* keywordValue, char* buffer, int32_t bufferCapacity, UErrorCode* status); /** + * enums for the return value for the character and line orientation + * functions. + * @stable ICU 4.0 + */ +typedef enum { + ULOC_LAYOUT_LTR = 0, /* left-to-right. */ + ULOC_LAYOUT_RTL = 1, /* right-to-left. */ + ULOC_LAYOUT_TTB = 2, /* top-to-bottom. */ + ULOC_LAYOUT_BTT = 3, /* bottom-to-top. */ + ULOC_LAYOUT_UNKNOWN +} ULayoutType; + +/** + * Get the layout character orientation for the specified locale. + * + * @param localeId locale name + * @param status Error status + * @return an enum indicating the layout orientation for characters. + * @stable ICU 4.0 + */ +U_STABLE ULayoutType U_EXPORT2 +uloc_getCharacterOrientation(const char* localeId, + UErrorCode *status); + +/** + * Get the layout line orientation for the specified locale. + * + * @param localeId locale name + * @param status Error status + * @return an enum indicating the layout orientation for lines. + * @stable ICU 4.0 + */ +U_STABLE ULayoutType U_EXPORT2 +uloc_getLineOrientation(const char* localeId, + UErrorCode *status); + +/** * enums for the 'outResult' parameter return value * @see uloc_acceptLanguageFromHTTP * @see uloc_acceptLanguage - * @draft ICU 3.2 + * @stable ICU 3.2 */ typedef enum { ULOC_ACCEPT_FAILED = 0, /* No exact match was found. */ @@ -876,15 +930,18 @@ typedef enum { /** - * @param httpAcceptLanguage - "Accept-Language:" header as per HTTP. + * Based on a HTTP header from a web browser and a list of available locales, + * determine an acceptable locale for the user. * @param result - buffer to accept the result locale * @param resultAvailable the size of the result buffer. + * @param outResult - An out parameter that contains the fallback status + * @param httpAcceptLanguage - "Accept-Language:" header as per HTTP. * @param availableLocales - list of available locales to match * @param status Error status, may be BUFFER_OVERFLOW_ERROR * @return length needed for the locale. - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uloc_acceptLanguageFromHTTP(char *result, int32_t resultAvailable, UAcceptResult *outResult, const char *httpAcceptLanguage, @@ -892,26 +949,178 @@ uloc_acceptLanguageFromHTTP(char *result, int32_t resultAvailable, UErrorCode *status); /** - * @param acceptList -list of acceptable languages - * @param acceptListCount - count of acceptList items + * Based on a list of available locales, + * determine an acceptable locale for the user. * @param result - buffer to accept the result locale * @param resultAvailable the size of the result buffer. + * @param outResult - An out parameter that contains the fallback status + * @param acceptList - list of acceptable languages + * @param acceptListCount - count of acceptList items * @param availableLocales - list of available locales to match * @param status Error status, may be BUFFER_OVERFLOW_ERROR * @return length needed for the locale. - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uloc_acceptLanguage(char *result, int32_t resultAvailable, UAcceptResult *outResult, const char **acceptList, int32_t acceptListCount, UEnumeration* availableLocales, UErrorCode *status); -/*eof*/ +/** + * Gets the ICU locale ID for the specified Win32 LCID value. + * + * @param hostID the Win32 LCID to translate + * @param locale the output buffer for the ICU locale ID, which will be NUL-terminated + * if there is room. + * @param localeCapacity the size of the output buffer + * @param status an error is returned if the LCID is unrecognized or the output buffer + * is too small + * @return actual the actual size of the locale ID, not including NUL-termination + * @stable ICU 3.8 + */ +U_STABLE int32_t U_EXPORT2 +uloc_getLocaleForLCID(uint32_t hostID, char *locale, int32_t localeCapacity, + UErrorCode *status); -#endif /*_ULOC*/ +/** + * Add the likely subtags for a provided locale ID, per the algorithm described + * in the following CLDR technical report: + * + * http://www.unicode.org/reports/tr35/#Likely_Subtags + * + * If localeID is already in the maximal form, or there is no data available + * for maximization, it will be copied to the output buffer. For example, + * "und-Zzzz" cannot be maximized, since there is no reasonable maximization. + * + * Examples: + * + * "en" maximizes to "en_Latn_US" + * + * "de" maximizes to "de_Latn_US" + * + * "sr" maximizes to "sr_Cyrl_RS" + * + * "sh" maximizes to "sr_Latn_RS" (Note this will not reverse.) + * + * "zh_Hani" maximizes to "zh_Hans_CN" (Note this will not reverse.) + * + * @param localeID The locale to maximize + * @param maximizedLocaleID The maximized locale + * @param maximizedLocaleIDCapacity The capacity of the maximizedLocaleID buffer + * @param err Error information if maximizing the locale failed. If the length + * of the localeID and the null-terminator is greater than the maximum allowed size, + * or the localeId is not well-formed, the error code is U_ILLEGAL_ARGUMENT_ERROR. + * @return The actual buffer size needed for the maximized locale. If it's + * greater than maximizedLocaleIDCapacity, the returned ID will be truncated. + * On error, the return value is -1. + * @stable ICU 4.0 + */ +U_STABLE int32_t U_EXPORT2 +uloc_addLikelySubtags(const char* localeID, + char* maximizedLocaleID, + int32_t maximizedLocaleIDCapacity, + UErrorCode* err); + + +/** + * Minimize the subtags for a provided locale ID, per the algorithm described + * in the following CLDR technical report: + * + * http://www.unicode.org/reports/tr35/#Likely_Subtags + * + * If localeID is already in the minimal form, or there is no data available + * for minimization, it will be copied to the output buffer. Since the + * minimization algorithm relies on proper maximization, see the comments + * for uloc_addLikelySubtags for reasons why there might not be any data. + * + * Examples: + * + * "en_Latn_US" minimizes to "en" + * + * "de_Latn_US" minimizes to "de" + * + * "sr_Cyrl_RS" minimizes to "sr" + * + * "zh_Hant_TW" minimizes to "zh_TW" (The region is preferred to the + * script, and minimizing to "zh" would imply "zh_Hans_CN".) + * + * @param localeID The locale to minimize + * @param minimizedLocaleID The minimized locale + * @param minimizedLocaleIDCapacity The capacity of the minimizedLocaleID buffer + * @param err Error information if minimizing the locale failed. If the length + * of the localeID and the null-terminator is greater than the maximum allowed size, + * or the localeId is not well-formed, the error code is U_ILLEGAL_ARGUMENT_ERROR. + * @return The actual buffer size needed for the minimized locale. If it's + * greater than minimizedLocaleIDCapacity, the returned ID will be truncated. + * On error, the return value is -1. + * @stable ICU 4.0 + */ +U_STABLE int32_t U_EXPORT2 +uloc_minimizeSubtags(const char* localeID, + char* minimizedLocaleID, + int32_t minimizedLocaleIDCapacity, + UErrorCode* err); + +/** + * Returns a locale ID for the specified BCP47 language tag string. + * If the specified language tag contains any ill-formed subtags, + * the first such subtag and all following subtags are ignored. + * <p> + * This implements the 'Language-Tag' production of BCP47, and so + * supports grandfathered (regular and irregular) as well as private + * use language tags. Private use tags are represented as 'x-whatever', + * and grandfathered tags are converted to their canonical replacements + * where they exist. Note that a few grandfathered tags have no modern + * replacement, these will be converted using the fallback described in + * the first paragraph, so some information might be lost. + * @param langtag the input BCP47 language tag. + * @param localeID the output buffer receiving a locale ID for the + * specified BCP47 language tag. + * @param localeIDCapacity the size of the locale ID output buffer. + * @param parsedLength if not NULL, succsessfully parsed length + * for the input language tag is set. + * @param err error information if receiving the locald ID + * failed. + * @return the length of the locale ID. + * @draft ICU 4.2 + */ +U_DRAFT int32_t U_EXPORT2 +uloc_forLanguageTag(const char* langtag, + char* localeID, + int32_t localeIDCapacity, + int32_t* parsedLength, + UErrorCode* err); +/** + * Returns a well-formed language tag for this locale ID. + * <p> + * <b>Note</b>: When <code>strict</code> is FALSE, any locale + * fields which do not satisfy the BCP47 syntax requirement will + * be omitted from the result. When <code>strict</code> is + * TRUE, this function sets U_ILLEGAL_ARGUMENT_ERROR to the + * <code>err</code> if any locale fields do not satisfy the + * BCP47 syntax requirement. + * @param localeID the input lcoale ID + * @param langtag the output buffer receiving BCP47 language + * tag for the locale ID. + * @param langtagCapacity the size of the BCP47 language tag + * output buffer. + * @param strict boolean value indicating if the function returns + * an error for an ill-formed input locale ID. + * @param err error information if receiving the language + * tag failed. + * @return The length of the BCP47 language tag. + * @draft ICU 4.2 + */ +U_DRAFT int32_t U_EXPORT2 +uloc_toLanguageTag(const char* localeID, + char* langtag, + int32_t langtagCapacity, + UBool strict, + UErrorCode* err); +#endif /*_ULOC*/ diff --git a/Source/WTF/icu/unicode/umachine.h b/Source/WTF/icu/unicode/umachine.h index d841f5348..abbdcb79f 100644 --- a/Source/WTF/icu/unicode/umachine.h +++ b/Source/WTF/icu/unicode/umachine.h @@ -1,7 +1,7 @@ /* ****************************************************************************** * -* Copyright (C) 1999-2004, International Business Machines +* Copyright (C) 1999-2010, International Business Machines * Corporation and others. All Rights Reserved. * ****************************************************************************** @@ -26,25 +26,30 @@ /** * \file - * \brief Basic types and constants for UTF - * + * \brief Basic types and constants for UTF + * * <h2> Basic types and constants for UTF </h2> * This file defines basic types and constants for utf.h to be * platform-independent. umachine.h and utf.h are included into * utypes.h to provide all the general definitions for ICU. * All of these definitions used to be in utypes.h before * the UTF-handling macros made this unmaintainable. - * + * */ /*==========================================================================*/ /* Include platform-dependent definitions */ /* which are contained in the platform-specific file platform.h */ /*==========================================================================*/ -#if defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64) +#if defined(U_PALMOS) +# include "unicode/ppalmos.h" +#elif !defined(__MINGW32__) && (defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64)) +#ifdef CYGWINMSVC +# include "unicode/platform.h" +#endif # include "unicode/pwin32.h" #else -# include "unicode/platform.h" +# include "unicode/ptypes.h" /* platform.h is included in ptypes.h */ #endif /* @@ -86,7 +91,7 @@ /** * \def U_CDECL_END - * This is used to end a declaration of a library private ICU C API + * This is used to end a declaration of a library private ICU C API * @stable ICU 2.4 */ @@ -101,54 +106,33 @@ #endif /** - * \def U_NAMESPACE_BEGIN - * This is used to begin a declaration of a public ICU C++ API. - * If the compiler doesn't support namespaces, this does nothing. - * @stable ICU 2.4 - */ - -/** - * \def U_NAMESPACE_END - * This is used to end a declaration of a public ICU C++ API - * If the compiler doesn't support namespaces, this does nothing. - * @stable ICU 2.4 - */ - -/** - * \def U_NAMESPACE_USE - * This is used to specify that the rest of the code uses the - * public ICU C++ API namespace. - * If the compiler doesn't support namespaces, this does nothing. - * @stable ICU 2.4 + * \def U_ATTRIBUTE_DEPRECATED + * This is used for GCC specific attributes + * @internal */ - +#if defined(__GNUC__) && (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 2)) +# define U_ATTRIBUTE_DEPRECATED __attribute__ ((deprecated)) /** - * \def U_NAMESPACE_QUALIFIER - * This is used to qualify that a function or class is part of - * the public ICU C++ API namespace. - * If the compiler doesn't support namespaces, this does nothing. - * @stable ICU 2.4 + * \def U_ATTRIBUTE_DEPRECATED + * This is used for Visual C++ specific attributes + * @internal */ - -/* Define namespace symbols if the compiler supports it. */ -#if U_HAVE_NAMESPACE -# define U_NAMESPACE_BEGIN namespace U_ICU_NAMESPACE { -# define U_NAMESPACE_END } -# define U_NAMESPACE_USE using namespace U_ICU_NAMESPACE; -# define U_NAMESPACE_QUALIFIER U_ICU_NAMESPACE:: +#elif defined(U_WINDOWS) && defined(_MSC_VER) && (_MSC_VER >= 1400) +# define U_ATTRIBUTE_DEPRECATED __declspec(deprecated) #else -# define U_NAMESPACE_BEGIN -# define U_NAMESPACE_END -# define U_NAMESPACE_USE -# define U_NAMESPACE_QUALIFIER +# define U_ATTRIBUTE_DEPRECATED #endif - /** This is used to declare a function as a public ICU C API @stable ICU 2.0*/ #define U_CAPI U_CFUNC U_EXPORT +/** This is used to declare a function as a stable public ICU C API*/ #define U_STABLE U_CAPI +/** This is used to declare a function as a draft public ICU C API */ #define U_DRAFT U_CAPI -#define U_DEPRECATED U_CAPI +/** This is used to declare a function as a deprecated public ICU C API */ +#define U_DEPRECATED U_CAPI U_ATTRIBUTE_DEPRECATED +/** This is used to declare a function as an obsolete public ICU C API */ #define U_OBSOLETE U_CAPI +/** This is used to declare a function as an internal ICU C API */ #define U_INTERNAL U_CAPI /*==========================================================================*/ @@ -201,7 +185,7 @@ /** * Provides a platform independent way to specify a signed 64-bit integer constant. * note: may be wrong for some 64 bit platforms - ensure your compiler provides INT64_C - * @draft ICU 2.8 + * @stable ICU 2.8 */ # define INT64_C(c) c ## LL # endif @@ -209,7 +193,7 @@ /** * Provides a platform independent way to specify an unsigned 64-bit integer constant. * note: may be wrong for some 64 bit platforms - ensure your compiler provides UINT64_C - * @draft ICU 2.8 + * @stable ICU 2.8 */ # define UINT64_C(c) c ## ULL # endif @@ -284,7 +268,7 @@ typedef int8_t UBool; * @stable ICU 2.0 */ #if !defined(U_WCHAR_IS_UTF16) && !defined(U_WCHAR_IS_UTF32) -# ifdef __STDC_ISO_10646__ +# ifdef __STDC_ISO_10646__ # if (U_SIZEOF_WCHAR_T==2) # define U_WCHAR_IS_UTF16 # elif (U_SIZEOF_WCHAR_T==4) @@ -298,8 +282,8 @@ typedef int8_t UBool; # if (U_SIZEOF_WCHAR_T==4) # define U_WCHAR_IS_UTF32 # endif -# elif defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64) -# define U_WCHAR_IS_UTF16 +# elif defined(U_WINDOWS) +# define U_WCHAR_IS_UTF16 # endif #endif @@ -311,17 +295,23 @@ typedef int8_t UBool; /** * \var UChar * Define UChar to be wchar_t if that is 16 bits wide; always assumed to be unsigned. - * If wchar_t is not 16 bits wide, then define UChar to be uint16_t. + * If wchar_t is not 16 bits wide, then define UChar to be uint16_t or char16_t because GCC >=4.4 + * can handle UTF16 string literals. * This makes the definition of UChar platform-dependent * but allows direct string type compatibility with platforms with * 16-bit wchar_t types. * - * @stable ICU 2.0 + * @draft ICU 4.4 */ /* Define UChar to be compatible with wchar_t if possible. */ #if U_SIZEOF_WCHAR_T==2 typedef wchar_t UChar; +#elif U_GNUC_UTF16_STRING +#if defined _GCC_ + typedef __CHAR16_TYPE__ char16_t; +#endif + typedef char16_t UChar; #else typedef uint16_t UChar; #endif @@ -352,6 +342,8 @@ typedef int32_t UChar32; /* the OS in use. */ /*==========================================================================*/ +#ifndef U_HIDE_INTERNAL_API + /** * \def U_ALIGN_CODE * This is used to align code fragments to a specific byte boundary. @@ -362,8 +354,19 @@ typedef int32_t UChar32; # define U_ALIGN_CODE(n) #endif +#endif /* U_HIDE_INTERNAL_API */ + +/** + * \def U_INLINE + * This is used to request inlining of a function, on platforms and languages which support it. + */ + #ifndef U_INLINE -# define U_INLINE +# ifdef XP_CPLUSPLUS +# define U_INLINE inline +# else +# define U_INLINE +# endif #endif #include "unicode/urename.h" diff --git a/Source/WTF/icu/unicode/unistr.h b/Source/WTF/icu/unicode/unistr.h new file mode 100644 index 000000000..24d0351fb --- /dev/null +++ b/Source/WTF/icu/unicode/unistr.h @@ -0,0 +1,4440 @@ +/* +********************************************************************** +* Copyright (C) 1998-2010, International Business Machines +* Corporation and others. All Rights Reserved. +********************************************************************** +* +* File unistr.h +* +* Modification History: +* +* Date Name Description +* 09/25/98 stephen Creation. +* 11/11/98 stephen Changed per 11/9 code review. +* 04/20/99 stephen Overhauled per 4/16 code review. +* 11/18/99 aliu Made to inherit from Replaceable. Added method +* handleReplaceBetween(); other methods unchanged. +* 06/25/01 grhoten Remove dependency on iostream. +****************************************************************************** +*/ + +#ifndef UNISTR_H +#define UNISTR_H + +/** + * \file + * \brief C++ API: Unicode String + */ + +#include "unicode/utypes.h" +#include "unicode/rep.h" +#include "unicode/std_string.h" +#include "unicode/stringpiece.h" +#include "unicode/bytestream.h" + +struct UConverter; // unicode/ucnv.h +class StringThreadTest; + +#ifndef U_COMPARE_CODE_POINT_ORDER +/* see also ustring.h and unorm.h */ +/** + * Option bit for u_strCaseCompare, u_strcasecmp, unorm_compare, etc: + * Compare strings in code point order instead of code unit order. + * @stable ICU 2.2 + */ +#define U_COMPARE_CODE_POINT_ORDER 0x8000 +#endif + +#ifndef USTRING_H +/** + * \ingroup ustring_ustrlen + */ +U_STABLE int32_t U_EXPORT2 +u_strlen(const UChar *s); +#endif + +U_NAMESPACE_BEGIN + +class Locale; // unicode/locid.h +class StringCharacterIterator; +class BreakIterator; // unicode/brkiter.h + +/* The <iostream> include has been moved to unicode/ustream.h */ + +/** + * Constant to be used in the UnicodeString(char *, int32_t, EInvariant) constructor + * which constructs a Unicode string from an invariant-character char * string. + * About invariant characters see utypes.h. + * This constructor has no runtime dependency on conversion code and is + * therefore recommended over ones taking a charset name string + * (where the empty string "" indicates invariant-character conversion). + * + * @stable ICU 3.2 + */ +#define US_INV U_NAMESPACE_QUALIFIER UnicodeString::kInvariant + +/** + * Unicode String literals in C++. + * Dependent on the platform properties, different UnicodeString + * constructors should be used to create a UnicodeString object from + * a string literal. + * The macros are defined for maximum performance. + * They work only for strings that contain "invariant characters", i.e., + * only latin letters, digits, and some punctuation. + * See utypes.h for details. + * + * The string parameter must be a C string literal. + * The length of the string, not including the terminating + * <code>NUL</code>, must be specified as a constant. + * The U_STRING_DECL macro should be invoked exactly once for one + * such string variable before it is used. + * @stable ICU 2.0 + */ +#if defined(U_DECLARE_UTF16) +# define UNICODE_STRING(cs, _length) U_NAMESPACE_QUALIFIER UnicodeString(TRUE, (const UChar *)U_DECLARE_UTF16(cs), _length) +#elif U_SIZEOF_WCHAR_T==U_SIZEOF_UCHAR && (U_CHARSET_FAMILY==U_ASCII_FAMILY || (U_SIZEOF_UCHAR == 2 && defined(U_WCHAR_IS_UTF16))) +# define UNICODE_STRING(cs, _length) U_NAMESPACE_QUALIFIER UnicodeString(TRUE, (const UChar *)L ## cs, _length) +#elif U_SIZEOF_UCHAR==1 && U_CHARSET_FAMILY==U_ASCII_FAMILY +# define UNICODE_STRING(cs, _length) U_NAMESPACE_QUALIFIER UnicodeString(TRUE, (const UChar *)cs, _length) +#else +# define UNICODE_STRING(cs, _length) U_NAMESPACE_QUALIFIER UnicodeString(cs, _length, US_INV) +#endif + +/** + * Unicode String literals in C++. + * Dependent on the platform properties, different UnicodeString + * constructors should be used to create a UnicodeString object from + * a string literal. + * The macros are defined for improved performance. + * They work only for strings that contain "invariant characters", i.e., + * only latin letters, digits, and some punctuation. + * See utypes.h for details. + * + * The string parameter must be a C string literal. + * @stable ICU 2.0 + */ +#define UNICODE_STRING_SIMPLE(cs) UNICODE_STRING(cs, -1) + +/** + * UnicodeString is a string class that stores Unicode characters directly and provides + * similar functionality as the Java String and StringBuffer classes. + * It is a concrete implementation of the abstract class Replaceable (for transliteration). + * + * The UnicodeString class is not suitable for subclassing. + * + * <p>For an overview of Unicode strings in C and C++ see the + * <a href="http://icu-project.org/userguide/strings.html">User Guide Strings chapter</a>.</p> + * + * <p>In ICU, a Unicode string consists of 16-bit Unicode <em>code units</em>. + * A Unicode character may be stored with either one code unit + * (the most common case) or with a matched pair of special code units + * ("surrogates"). The data type for code units is UChar. + * For single-character handling, a Unicode character code <em>point</em> is a value + * in the range 0..0x10ffff. ICU uses the UChar32 type for code points.</p> + * + * <p>Indexes and offsets into and lengths of strings always count code units, not code points. + * This is the same as with multi-byte char* strings in traditional string handling. + * Operations on partial strings typically do not test for code point boundaries. + * If necessary, the user needs to take care of such boundaries by testing for the code unit + * values or by using functions like + * UnicodeString::getChar32Start() and UnicodeString::getChar32Limit() + * (or, in C, the equivalent macros U16_SET_CP_START() and U16_SET_CP_LIMIT(), see utf.h).</p> + * + * UnicodeString methods are more lenient with regard to input parameter values + * than other ICU APIs. In particular: + * - If indexes are out of bounds for a UnicodeString object + * (<0 or >length()) then they are "pinned" to the nearest boundary. + * - If primitive string pointer values (e.g., const UChar * or char *) + * for input strings are NULL, then those input string parameters are treated + * as if they pointed to an empty string. + * However, this is <em>not</em> the case for char * parameters for charset names + * or other IDs. + * - Most UnicodeString methods do not take a UErrorCode parameter because + * there are usually very few opportunities for failure other than a shortage + * of memory, error codes in low-level C++ string methods would be inconvenient, + * and the error code as the last parameter (ICU convention) would prevent + * the use of default parameter values. + * Instead, such methods set the UnicodeString into a "bogus" state + * (see isBogus()) if an error occurs. + * + * In string comparisons, two UnicodeString objects that are both "bogus" + * compare equal (to be transitive and prevent endless loops in sorting), + * and a "bogus" string compares less than any non-"bogus" one. + * + * Const UnicodeString methods are thread-safe. Multiple threads can use + * const methods on the same UnicodeString object simultaneously, + * but non-const methods must not be called concurrently (in multiple threads) + * with any other (const or non-const) methods. + * + * Similarly, const UnicodeString & parameters are thread-safe. + * One object may be passed in as such a parameter concurrently in multiple threads. + * This includes the const UnicodeString & parameters for + * copy construction, assignment, and cloning. + * + * <p>UnicodeString uses several storage methods. + * String contents can be stored inside the UnicodeString object itself, + * in an allocated and shared buffer, or in an outside buffer that is "aliased". + * Most of this is done transparently, but careful aliasing in particular provides + * significant performance improvements. + * Also, the internal buffer is accessible via special functions. + * For details see the + * <a href="http://icu-project.org/userguide/strings.html">User Guide Strings chapter</a>.</p> + * + * @see utf.h + * @see CharacterIterator + * @stable ICU 2.0 + */ +class U_COMMON_API UnicodeString : public Replaceable +{ +public: + + /** + * Constant to be used in the UnicodeString(char *, int32_t, EInvariant) constructor + * which constructs a Unicode string from an invariant-character char * string. + * Use the macro US_INV instead of the full qualification for this value. + * + * @see US_INV + * @stable ICU 3.2 + */ + enum EInvariant { + /** + * @see EInvariant + * @stable ICU 3.2 + */ + kInvariant + }; + + //======================================== + // Read-only operations + //======================================== + + /* Comparison - bitwise only - for international comparison use collation */ + + /** + * Equality operator. Performs only bitwise comparison. + * @param text The UnicodeString to compare to this one. + * @return TRUE if <TT>text</TT> contains the same characters as this one, + * FALSE otherwise. + * @stable ICU 2.0 + */ + inline UBool operator== (const UnicodeString& text) const; + + /** + * Inequality operator. Performs only bitwise comparison. + * @param text The UnicodeString to compare to this one. + * @return FALSE if <TT>text</TT> contains the same characters as this one, + * TRUE otherwise. + * @stable ICU 2.0 + */ + inline UBool operator!= (const UnicodeString& text) const; + + /** + * Greater than operator. Performs only bitwise comparison. + * @param text The UnicodeString to compare to this one. + * @return TRUE if the characters in this are bitwise + * greater than the characters in <code>text</code>, FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool operator> (const UnicodeString& text) const; + + /** + * Less than operator. Performs only bitwise comparison. + * @param text The UnicodeString to compare to this one. + * @return TRUE if the characters in this are bitwise + * less than the characters in <code>text</code>, FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool operator< (const UnicodeString& text) const; + + /** + * Greater than or equal operator. Performs only bitwise comparison. + * @param text The UnicodeString to compare to this one. + * @return TRUE if the characters in this are bitwise + * greater than or equal to the characters in <code>text</code>, FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool operator>= (const UnicodeString& text) const; + + /** + * Less than or equal operator. Performs only bitwise comparison. + * @param text The UnicodeString to compare to this one. + * @return TRUE if the characters in this are bitwise + * less than or equal to the characters in <code>text</code>, FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool operator<= (const UnicodeString& text) const; + + /** + * Compare the characters bitwise in this UnicodeString to + * the characters in <code>text</code>. + * @param text The UnicodeString to compare to this one. + * @return The result of bitwise character comparison: 0 if this + * contains the same characters as <code>text</code>, -1 if the characters in + * this are bitwise less than the characters in <code>text</code>, +1 if the + * characters in this are bitwise greater than the characters + * in <code>text</code>. + * @stable ICU 2.0 + */ + inline int8_t compare(const UnicodeString& text) const; + + /** + * Compare the characters bitwise in the range + * [<TT>start</TT>, <TT>start + length</TT>) with the characters + * in <TT>text</TT> + * @param start the offset at which the compare operation begins + * @param length the number of characters of text to compare. + * @param text the other text to be compared against this string. + * @return The result of bitwise character comparison: 0 if this + * contains the same characters as <code>text</code>, -1 if the characters in + * this are bitwise less than the characters in <code>text</code>, +1 if the + * characters in this are bitwise greater than the characters + * in <code>text</code>. + * @stable ICU 2.0 + */ + inline int8_t compare(int32_t start, + int32_t length, + const UnicodeString& text) const; + + /** + * Compare the characters bitwise in the range + * [<TT>start</TT>, <TT>start + length</TT>) with the characters + * in <TT>srcText</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>). + * @param start the offset at which the compare operation begins + * @param length the number of characters in this to compare. + * @param srcText the text to be compared + * @param srcStart the offset into <TT>srcText</TT> to start comparison + * @param srcLength the number of characters in <TT>src</TT> to compare + * @return The result of bitwise character comparison: 0 if this + * contains the same characters as <code>srcText</code>, -1 if the characters in + * this are bitwise less than the characters in <code>srcText</code>, +1 if the + * characters in this are bitwise greater than the characters + * in <code>srcText</code>. + * @stable ICU 2.0 + */ + inline int8_t compare(int32_t start, + int32_t length, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const; + + /** + * Compare the characters bitwise in this UnicodeString with the first + * <TT>srcLength</TT> characters in <TT>srcChars</TT>. + * @param srcChars The characters to compare to this UnicodeString. + * @param srcLength the number of characters in <TT>srcChars</TT> to compare + * @return The result of bitwise character comparison: 0 if this + * contains the same characters as <code>srcChars</code>, -1 if the characters in + * this are bitwise less than the characters in <code>srcChars</code>, +1 if the + * characters in this are bitwise greater than the characters + * in <code>srcChars</code>. + * @stable ICU 2.0 + */ + inline int8_t compare(const UChar *srcChars, + int32_t srcLength) const; + + /** + * Compare the characters bitwise in the range + * [<TT>start</TT>, <TT>start + length</TT>) with the first + * <TT>length</TT> characters in <TT>srcChars</TT> + * @param start the offset at which the compare operation begins + * @param length the number of characters to compare. + * @param srcChars the characters to be compared + * @return The result of bitwise character comparison: 0 if this + * contains the same characters as <code>srcChars</code>, -1 if the characters in + * this are bitwise less than the characters in <code>srcChars</code>, +1 if the + * characters in this are bitwise greater than the characters + * in <code>srcChars</code>. + * @stable ICU 2.0 + */ + inline int8_t compare(int32_t start, + int32_t length, + const UChar *srcChars) const; + + /** + * Compare the characters bitwise in the range + * [<TT>start</TT>, <TT>start + length</TT>) with the characters + * in <TT>srcChars</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>). + * @param start the offset at which the compare operation begins + * @param length the number of characters in this to compare + * @param srcChars the characters to be compared + * @param srcStart the offset into <TT>srcChars</TT> to start comparison + * @param srcLength the number of characters in <TT>srcChars</TT> to compare + * @return The result of bitwise character comparison: 0 if this + * contains the same characters as <code>srcChars</code>, -1 if the characters in + * this are bitwise less than the characters in <code>srcChars</code>, +1 if the + * characters in this are bitwise greater than the characters + * in <code>srcChars</code>. + * @stable ICU 2.0 + */ + inline int8_t compare(int32_t start, + int32_t length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) const; + + /** + * Compare the characters bitwise in the range + * [<TT>start</TT>, <TT>limit</TT>) with the characters + * in <TT>srcText</TT> in the range + * [<TT>srcStart</TT>, <TT>srcLimit</TT>). + * @param start the offset at which the compare operation begins + * @param limit the offset immediately following the compare operation + * @param srcText the text to be compared + * @param srcStart the offset into <TT>srcText</TT> to start comparison + * @param srcLimit the offset into <TT>srcText</TT> to limit comparison + * @return The result of bitwise character comparison: 0 if this + * contains the same characters as <code>srcText</code>, -1 if the characters in + * this are bitwise less than the characters in <code>srcText</code>, +1 if the + * characters in this are bitwise greater than the characters + * in <code>srcText</code>. + * @stable ICU 2.0 + */ + inline int8_t compareBetween(int32_t start, + int32_t limit, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLimit) const; + + /** + * Compare two Unicode strings in code point order. + * The result may be different from the results of compare(), operator<, etc. + * if supplementary characters are present: + * + * In UTF-16, supplementary characters (with code points U+10000 and above) are + * stored with pairs of surrogate code units. These have values from 0xd800 to 0xdfff, + * which means that they compare as less than some other BMP characters like U+feff. + * This function compares Unicode strings in code point order. + * If either of the UTF-16 strings is malformed (i.e., it contains unpaired surrogates), then the result is not defined. + * + * @param text Another string to compare this one to. + * @return a negative/zero/positive integer corresponding to whether + * this string is less than/equal to/greater than the second one + * in code point order + * @stable ICU 2.0 + */ + inline int8_t compareCodePointOrder(const UnicodeString& text) const; + + /** + * Compare two Unicode strings in code point order. + * The result may be different from the results of compare(), operator<, etc. + * if supplementary characters are present: + * + * In UTF-16, supplementary characters (with code points U+10000 and above) are + * stored with pairs of surrogate code units. These have values from 0xd800 to 0xdfff, + * which means that they compare as less than some other BMP characters like U+feff. + * This function compares Unicode strings in code point order. + * If either of the UTF-16 strings is malformed (i.e., it contains unpaired surrogates), then the result is not defined. + * + * @param start The start offset in this string at which the compare operation begins. + * @param length The number of code units from this string to compare. + * @param srcText Another string to compare this one to. + * @return a negative/zero/positive integer corresponding to whether + * this string is less than/equal to/greater than the second one + * in code point order + * @stable ICU 2.0 + */ + inline int8_t compareCodePointOrder(int32_t start, + int32_t length, + const UnicodeString& srcText) const; + + /** + * Compare two Unicode strings in code point order. + * The result may be different from the results of compare(), operator<, etc. + * if supplementary characters are present: + * + * In UTF-16, supplementary characters (with code points U+10000 and above) are + * stored with pairs of surrogate code units. These have values from 0xd800 to 0xdfff, + * which means that they compare as less than some other BMP characters like U+feff. + * This function compares Unicode strings in code point order. + * If either of the UTF-16 strings is malformed (i.e., it contains unpaired surrogates), then the result is not defined. + * + * @param start The start offset in this string at which the compare operation begins. + * @param length The number of code units from this string to compare. + * @param srcText Another string to compare this one to. + * @param srcStart The start offset in that string at which the compare operation begins. + * @param srcLength The number of code units from that string to compare. + * @return a negative/zero/positive integer corresponding to whether + * this string is less than/equal to/greater than the second one + * in code point order + * @stable ICU 2.0 + */ + inline int8_t compareCodePointOrder(int32_t start, + int32_t length, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const; + + /** + * Compare two Unicode strings in code point order. + * The result may be different from the results of compare(), operator<, etc. + * if supplementary characters are present: + * + * In UTF-16, supplementary characters (with code points U+10000 and above) are + * stored with pairs of surrogate code units. These have values from 0xd800 to 0xdfff, + * which means that they compare as less than some other BMP characters like U+feff. + * This function compares Unicode strings in code point order. + * If either of the UTF-16 strings is malformed (i.e., it contains unpaired surrogates), then the result is not defined. + * + * @param srcChars A pointer to another string to compare this one to. + * @param srcLength The number of code units from that string to compare. + * @return a negative/zero/positive integer corresponding to whether + * this string is less than/equal to/greater than the second one + * in code point order + * @stable ICU 2.0 + */ + inline int8_t compareCodePointOrder(const UChar *srcChars, + int32_t srcLength) const; + + /** + * Compare two Unicode strings in code point order. + * The result may be different from the results of compare(), operator<, etc. + * if supplementary characters are present: + * + * In UTF-16, supplementary characters (with code points U+10000 and above) are + * stored with pairs of surrogate code units. These have values from 0xd800 to 0xdfff, + * which means that they compare as less than some other BMP characters like U+feff. + * This function compares Unicode strings in code point order. + * If either of the UTF-16 strings is malformed (i.e., it contains unpaired surrogates), then the result is not defined. + * + * @param start The start offset in this string at which the compare operation begins. + * @param length The number of code units from this string to compare. + * @param srcChars A pointer to another string to compare this one to. + * @return a negative/zero/positive integer corresponding to whether + * this string is less than/equal to/greater than the second one + * in code point order + * @stable ICU 2.0 + */ + inline int8_t compareCodePointOrder(int32_t start, + int32_t length, + const UChar *srcChars) const; + + /** + * Compare two Unicode strings in code point order. + * The result may be different from the results of compare(), operator<, etc. + * if supplementary characters are present: + * + * In UTF-16, supplementary characters (with code points U+10000 and above) are + * stored with pairs of surrogate code units. These have values from 0xd800 to 0xdfff, + * which means that they compare as less than some other BMP characters like U+feff. + * This function compares Unicode strings in code point order. + * If either of the UTF-16 strings is malformed (i.e., it contains unpaired surrogates), then the result is not defined. + * + * @param start The start offset in this string at which the compare operation begins. + * @param length The number of code units from this string to compare. + * @param srcChars A pointer to another string to compare this one to. + * @param srcStart The start offset in that string at which the compare operation begins. + * @param srcLength The number of code units from that string to compare. + * @return a negative/zero/positive integer corresponding to whether + * this string is less than/equal to/greater than the second one + * in code point order + * @stable ICU 2.0 + */ + inline int8_t compareCodePointOrder(int32_t start, + int32_t length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) const; + + /** + * Compare two Unicode strings in code point order. + * The result may be different from the results of compare(), operator<, etc. + * if supplementary characters are present: + * + * In UTF-16, supplementary characters (with code points U+10000 and above) are + * stored with pairs of surrogate code units. These have values from 0xd800 to 0xdfff, + * which means that they compare as less than some other BMP characters like U+feff. + * This function compares Unicode strings in code point order. + * If either of the UTF-16 strings is malformed (i.e., it contains unpaired surrogates), then the result is not defined. + * + * @param start The start offset in this string at which the compare operation begins. + * @param limit The offset after the last code unit from this string to compare. + * @param srcText Another string to compare this one to. + * @param srcStart The start offset in that string at which the compare operation begins. + * @param srcLimit The offset after the last code unit from that string to compare. + * @return a negative/zero/positive integer corresponding to whether + * this string is less than/equal to/greater than the second one + * in code point order + * @stable ICU 2.0 + */ + inline int8_t compareCodePointOrderBetween(int32_t start, + int32_t limit, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLimit) const; + + /** + * Compare two strings case-insensitively using full case folding. + * This is equivalent to this->foldCase(options).compare(text.foldCase(options)). + * + * @param text Another string to compare this one to. + * @param options A bit set of options: + * - U_FOLD_CASE_DEFAULT or 0 is used for default options: + * Comparison in code unit order with default case folding. + * + * - U_COMPARE_CODE_POINT_ORDER + * Set to choose code point order instead of code unit order + * (see u_strCompare for details). + * + * - U_FOLD_CASE_EXCLUDE_SPECIAL_I + * + * @return A negative, zero, or positive integer indicating the comparison result. + * @stable ICU 2.0 + */ + inline int8_t caseCompare(const UnicodeString& text, uint32_t options) const; + + /** + * Compare two strings case-insensitively using full case folding. + * This is equivalent to this->foldCase(options).compare(srcText.foldCase(options)). + * + * @param start The start offset in this string at which the compare operation begins. + * @param length The number of code units from this string to compare. + * @param srcText Another string to compare this one to. + * @param options A bit set of options: + * - U_FOLD_CASE_DEFAULT or 0 is used for default options: + * Comparison in code unit order with default case folding. + * + * - U_COMPARE_CODE_POINT_ORDER + * Set to choose code point order instead of code unit order + * (see u_strCompare for details). + * + * - U_FOLD_CASE_EXCLUDE_SPECIAL_I + * + * @return A negative, zero, or positive integer indicating the comparison result. + * @stable ICU 2.0 + */ + inline int8_t caseCompare(int32_t start, + int32_t length, + const UnicodeString& srcText, + uint32_t options) const; + + /** + * Compare two strings case-insensitively using full case folding. + * This is equivalent to this->foldCase(options).compare(srcText.foldCase(options)). + * + * @param start The start offset in this string at which the compare operation begins. + * @param length The number of code units from this string to compare. + * @param srcText Another string to compare this one to. + * @param srcStart The start offset in that string at which the compare operation begins. + * @param srcLength The number of code units from that string to compare. + * @param options A bit set of options: + * - U_FOLD_CASE_DEFAULT or 0 is used for default options: + * Comparison in code unit order with default case folding. + * + * - U_COMPARE_CODE_POINT_ORDER + * Set to choose code point order instead of code unit order + * (see u_strCompare for details). + * + * - U_FOLD_CASE_EXCLUDE_SPECIAL_I + * + * @return A negative, zero, or positive integer indicating the comparison result. + * @stable ICU 2.0 + */ + inline int8_t caseCompare(int32_t start, + int32_t length, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength, + uint32_t options) const; + + /** + * Compare two strings case-insensitively using full case folding. + * This is equivalent to this->foldCase(options).compare(srcChars.foldCase(options)). + * + * @param srcChars A pointer to another string to compare this one to. + * @param srcLength The number of code units from that string to compare. + * @param options A bit set of options: + * - U_FOLD_CASE_DEFAULT or 0 is used for default options: + * Comparison in code unit order with default case folding. + * + * - U_COMPARE_CODE_POINT_ORDER + * Set to choose code point order instead of code unit order + * (see u_strCompare for details). + * + * - U_FOLD_CASE_EXCLUDE_SPECIAL_I + * + * @return A negative, zero, or positive integer indicating the comparison result. + * @stable ICU 2.0 + */ + inline int8_t caseCompare(const UChar *srcChars, + int32_t srcLength, + uint32_t options) const; + + /** + * Compare two strings case-insensitively using full case folding. + * This is equivalent to this->foldCase(options).compare(srcChars.foldCase(options)). + * + * @param start The start offset in this string at which the compare operation begins. + * @param length The number of code units from this string to compare. + * @param srcChars A pointer to another string to compare this one to. + * @param options A bit set of options: + * - U_FOLD_CASE_DEFAULT or 0 is used for default options: + * Comparison in code unit order with default case folding. + * + * - U_COMPARE_CODE_POINT_ORDER + * Set to choose code point order instead of code unit order + * (see u_strCompare for details). + * + * - U_FOLD_CASE_EXCLUDE_SPECIAL_I + * + * @return A negative, zero, or positive integer indicating the comparison result. + * @stable ICU 2.0 + */ + inline int8_t caseCompare(int32_t start, + int32_t length, + const UChar *srcChars, + uint32_t options) const; + + /** + * Compare two strings case-insensitively using full case folding. + * This is equivalent to this->foldCase(options).compare(srcChars.foldCase(options)). + * + * @param start The start offset in this string at which the compare operation begins. + * @param length The number of code units from this string to compare. + * @param srcChars A pointer to another string to compare this one to. + * @param srcStart The start offset in that string at which the compare operation begins. + * @param srcLength The number of code units from that string to compare. + * @param options A bit set of options: + * - U_FOLD_CASE_DEFAULT or 0 is used for default options: + * Comparison in code unit order with default case folding. + * + * - U_COMPARE_CODE_POINT_ORDER + * Set to choose code point order instead of code unit order + * (see u_strCompare for details). + * + * - U_FOLD_CASE_EXCLUDE_SPECIAL_I + * + * @return A negative, zero, or positive integer indicating the comparison result. + * @stable ICU 2.0 + */ + inline int8_t caseCompare(int32_t start, + int32_t length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength, + uint32_t options) const; + + /** + * Compare two strings case-insensitively using full case folding. + * This is equivalent to this->foldCase(options).compareBetween(text.foldCase(options)). + * + * @param start The start offset in this string at which the compare operation begins. + * @param limit The offset after the last code unit from this string to compare. + * @param srcText Another string to compare this one to. + * @param srcStart The start offset in that string at which the compare operation begins. + * @param srcLimit The offset after the last code unit from that string to compare. + * @param options A bit set of options: + * - U_FOLD_CASE_DEFAULT or 0 is used for default options: + * Comparison in code unit order with default case folding. + * + * - U_COMPARE_CODE_POINT_ORDER + * Set to choose code point order instead of code unit order + * (see u_strCompare for details). + * + * - U_FOLD_CASE_EXCLUDE_SPECIAL_I + * + * @return A negative, zero, or positive integer indicating the comparison result. + * @stable ICU 2.0 + */ + inline int8_t caseCompareBetween(int32_t start, + int32_t limit, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLimit, + uint32_t options) const; + + /** + * Determine if this starts with the characters in <TT>text</TT> + * @param text The text to match. + * @return TRUE if this starts with the characters in <TT>text</TT>, + * FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool startsWith(const UnicodeString& text) const; + + /** + * Determine if this starts with the characters in <TT>srcText</TT> + * in the range [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>). + * @param srcText The text to match. + * @param srcStart the offset into <TT>srcText</TT> to start matching + * @param srcLength the number of characters in <TT>srcText</TT> to match + * @return TRUE if this starts with the characters in <TT>text</TT>, + * FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool startsWith(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const; + + /** + * Determine if this starts with the characters in <TT>srcChars</TT> + * @param srcChars The characters to match. + * @param srcLength the number of characters in <TT>srcChars</TT> + * @return TRUE if this starts with the characters in <TT>srcChars</TT>, + * FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool startsWith(const UChar *srcChars, + int32_t srcLength) const; + + /** + * Determine if this ends with the characters in <TT>srcChars</TT> + * in the range [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>). + * @param srcChars The characters to match. + * @param srcStart the offset into <TT>srcText</TT> to start matching + * @param srcLength the number of characters in <TT>srcChars</TT> to match + * @return TRUE if this ends with the characters in <TT>srcChars</TT>, FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool startsWith(const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) const; + + /** + * Determine if this ends with the characters in <TT>text</TT> + * @param text The text to match. + * @return TRUE if this ends with the characters in <TT>text</TT>, + * FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool endsWith(const UnicodeString& text) const; + + /** + * Determine if this ends with the characters in <TT>srcText</TT> + * in the range [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>). + * @param srcText The text to match. + * @param srcStart the offset into <TT>srcText</TT> to start matching + * @param srcLength the number of characters in <TT>srcText</TT> to match + * @return TRUE if this ends with the characters in <TT>text</TT>, + * FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool endsWith(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const; + + /** + * Determine if this ends with the characters in <TT>srcChars</TT> + * @param srcChars The characters to match. + * @param srcLength the number of characters in <TT>srcChars</TT> + * @return TRUE if this ends with the characters in <TT>srcChars</TT>, + * FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool endsWith(const UChar *srcChars, + int32_t srcLength) const; + + /** + * Determine if this ends with the characters in <TT>srcChars</TT> + * in the range [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>). + * @param srcChars The characters to match. + * @param srcStart the offset into <TT>srcText</TT> to start matching + * @param srcLength the number of characters in <TT>srcChars</TT> to match + * @return TRUE if this ends with the characters in <TT>srcChars</TT>, + * FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool endsWith(const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) const; + + + /* Searching - bitwise only */ + + /** + * Locate in this the first occurrence of the characters in <TT>text</TT>, + * using bitwise comparison. + * @param text The text to search for. + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(const UnicodeString& text) const; + + /** + * Locate in this the first occurrence of the characters in <TT>text</TT> + * starting at offset <TT>start</TT>, using bitwise comparison. + * @param text The text to search for. + * @param start The offset at which searching will start. + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(const UnicodeString& text, + int32_t start) const; + + /** + * Locate in this the first occurrence in the range + * [<TT>start</TT>, <TT>start + length</TT>) of the characters + * in <TT>text</TT>, using bitwise comparison. + * @param text The text to search for. + * @param start The offset at which searching will start. + * @param length The number of characters to search + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(const UnicodeString& text, + int32_t start, + int32_t length) const; + + /** + * Locate in this the first occurrence in the range + * [<TT>start</TT>, <TT>start + length</TT>) of the characters + * in <TT>srcText</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>), + * using bitwise comparison. + * @param srcText The text to search for. + * @param srcStart the offset into <TT>srcText</TT> at which + * to start matching + * @param srcLength the number of characters in <TT>srcText</TT> to match + * @param start the offset into this at which to start matching + * @param length the number of characters in this to search + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength, + int32_t start, + int32_t length) const; + + /** + * Locate in this the first occurrence of the characters in + * <TT>srcChars</TT> + * starting at offset <TT>start</TT>, using bitwise comparison. + * @param srcChars The text to search for. + * @param srcLength the number of characters in <TT>srcChars</TT> to match + * @param start the offset into this at which to start matching + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(const UChar *srcChars, + int32_t srcLength, + int32_t start) const; + + /** + * Locate in this the first occurrence in the range + * [<TT>start</TT>, <TT>start + length</TT>) of the characters + * in <TT>srcChars</TT>, using bitwise comparison. + * @param srcChars The text to search for. + * @param srcLength the number of characters in <TT>srcChars</TT> + * @param start The offset at which searching will start. + * @param length The number of characters to search + * @return The offset into this of the start of <TT>srcChars</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(const UChar *srcChars, + int32_t srcLength, + int32_t start, + int32_t length) const; + + /** + * Locate in this the first occurrence in the range + * [<TT>start</TT>, <TT>start + length</TT>) of the characters + * in <TT>srcChars</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>), + * using bitwise comparison. + * @param srcChars The text to search for. + * @param srcStart the offset into <TT>srcChars</TT> at which + * to start matching + * @param srcLength the number of characters in <TT>srcChars</TT> to match + * @param start the offset into this at which to start matching + * @param length the number of characters in this to search + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + int32_t indexOf(const UChar *srcChars, + int32_t srcStart, + int32_t srcLength, + int32_t start, + int32_t length) const; + + /** + * Locate in this the first occurrence of the BMP code point <code>c</code>, + * using bitwise comparison. + * @param c The code unit to search for. + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(UChar c) const; + + /** + * Locate in this the first occurrence of the code point <TT>c</TT>, + * using bitwise comparison. + * + * @param c The code point to search for. + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(UChar32 c) const; + + /** + * Locate in this the first occurrence of the BMP code point <code>c</code>, + * starting at offset <TT>start</TT>, using bitwise comparison. + * @param c The code unit to search for. + * @param start The offset at which searching will start. + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(UChar c, + int32_t start) const; + + /** + * Locate in this the first occurrence of the code point <TT>c</TT> + * starting at offset <TT>start</TT>, using bitwise comparison. + * + * @param c The code point to search for. + * @param start The offset at which searching will start. + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(UChar32 c, + int32_t start) const; + + /** + * Locate in this the first occurrence of the BMP code point <code>c</code> + * in the range [<TT>start</TT>, <TT>start + length</TT>), + * using bitwise comparison. + * @param c The code unit to search for. + * @param start the offset into this at which to start matching + * @param length the number of characters in this to search + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(UChar c, + int32_t start, + int32_t length) const; + + /** + * Locate in this the first occurrence of the code point <TT>c</TT> + * in the range [<TT>start</TT>, <TT>start + length</TT>), + * using bitwise comparison. + * + * @param c The code point to search for. + * @param start the offset into this at which to start matching + * @param length the number of characters in this to search + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t indexOf(UChar32 c, + int32_t start, + int32_t length) const; + + /** + * Locate in this the last occurrence of the characters in <TT>text</TT>, + * using bitwise comparison. + * @param text The text to search for. + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(const UnicodeString& text) const; + + /** + * Locate in this the last occurrence of the characters in <TT>text</TT> + * starting at offset <TT>start</TT>, using bitwise comparison. + * @param text The text to search for. + * @param start The offset at which searching will start. + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(const UnicodeString& text, + int32_t start) const; + + /** + * Locate in this the last occurrence in the range + * [<TT>start</TT>, <TT>start + length</TT>) of the characters + * in <TT>text</TT>, using bitwise comparison. + * @param text The text to search for. + * @param start The offset at which searching will start. + * @param length The number of characters to search + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(const UnicodeString& text, + int32_t start, + int32_t length) const; + + /** + * Locate in this the last occurrence in the range + * [<TT>start</TT>, <TT>start + length</TT>) of the characters + * in <TT>srcText</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>), + * using bitwise comparison. + * @param srcText The text to search for. + * @param srcStart the offset into <TT>srcText</TT> at which + * to start matching + * @param srcLength the number of characters in <TT>srcText</TT> to match + * @param start the offset into this at which to start matching + * @param length the number of characters in this to search + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength, + int32_t start, + int32_t length) const; + + /** + * Locate in this the last occurrence of the characters in <TT>srcChars</TT> + * starting at offset <TT>start</TT>, using bitwise comparison. + * @param srcChars The text to search for. + * @param srcLength the number of characters in <TT>srcChars</TT> to match + * @param start the offset into this at which to start matching + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(const UChar *srcChars, + int32_t srcLength, + int32_t start) const; + + /** + * Locate in this the last occurrence in the range + * [<TT>start</TT>, <TT>start + length</TT>) of the characters + * in <TT>srcChars</TT>, using bitwise comparison. + * @param srcChars The text to search for. + * @param srcLength the number of characters in <TT>srcChars</TT> + * @param start The offset at which searching will start. + * @param length The number of characters to search + * @return The offset into this of the start of <TT>srcChars</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(const UChar *srcChars, + int32_t srcLength, + int32_t start, + int32_t length) const; + + /** + * Locate in this the last occurrence in the range + * [<TT>start</TT>, <TT>start + length</TT>) of the characters + * in <TT>srcChars</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>), + * using bitwise comparison. + * @param srcChars The text to search for. + * @param srcStart the offset into <TT>srcChars</TT> at which + * to start matching + * @param srcLength the number of characters in <TT>srcChars</TT> to match + * @param start the offset into this at which to start matching + * @param length the number of characters in this to search + * @return The offset into this of the start of <TT>text</TT>, + * or -1 if not found. + * @stable ICU 2.0 + */ + int32_t lastIndexOf(const UChar *srcChars, + int32_t srcStart, + int32_t srcLength, + int32_t start, + int32_t length) const; + + /** + * Locate in this the last occurrence of the BMP code point <code>c</code>, + * using bitwise comparison. + * @param c The code unit to search for. + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(UChar c) const; + + /** + * Locate in this the last occurrence of the code point <TT>c</TT>, + * using bitwise comparison. + * + * @param c The code point to search for. + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(UChar32 c) const; + + /** + * Locate in this the last occurrence of the BMP code point <code>c</code> + * starting at offset <TT>start</TT>, using bitwise comparison. + * @param c The code unit to search for. + * @param start The offset at which searching will start. + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(UChar c, + int32_t start) const; + + /** + * Locate in this the last occurrence of the code point <TT>c</TT> + * starting at offset <TT>start</TT>, using bitwise comparison. + * + * @param c The code point to search for. + * @param start The offset at which searching will start. + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(UChar32 c, + int32_t start) const; + + /** + * Locate in this the last occurrence of the BMP code point <code>c</code> + * in the range [<TT>start</TT>, <TT>start + length</TT>), + * using bitwise comparison. + * @param c The code unit to search for. + * @param start the offset into this at which to start matching + * @param length the number of characters in this to search + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(UChar c, + int32_t start, + int32_t length) const; + + /** + * Locate in this the last occurrence of the code point <TT>c</TT> + * in the range [<TT>start</TT>, <TT>start + length</TT>), + * using bitwise comparison. + * + * @param c The code point to search for. + * @param start the offset into this at which to start matching + * @param length the number of characters in this to search + * @return The offset into this of <TT>c</TT>, or -1 if not found. + * @stable ICU 2.0 + */ + inline int32_t lastIndexOf(UChar32 c, + int32_t start, + int32_t length) const; + + + /* Character access */ + + /** + * Return the code unit at offset <tt>offset</tt>. + * If the offset is not valid (0..length()-1) then U+ffff is returned. + * @param offset a valid offset into the text + * @return the code unit at offset <tt>offset</tt> + * or 0xffff if the offset is not valid for this string + * @stable ICU 2.0 + */ + inline UChar charAt(int32_t offset) const; + + /** + * Return the code unit at offset <tt>offset</tt>. + * If the offset is not valid (0..length()-1) then U+ffff is returned. + * @param offset a valid offset into the text + * @return the code unit at offset <tt>offset</tt> + * @stable ICU 2.0 + */ + inline UChar operator[] (int32_t offset) const; + + /** + * Return the code point that contains the code unit + * at offset <tt>offset</tt>. + * If the offset is not valid (0..length()-1) then U+ffff is returned. + * @param offset a valid offset into the text + * that indicates the text offset of any of the code units + * that will be assembled into a code point (21-bit value) and returned + * @return the code point of text at <tt>offset</tt> + * or 0xffff if the offset is not valid for this string + * @stable ICU 2.0 + */ + inline UChar32 char32At(int32_t offset) const; + + /** + * Adjust a random-access offset so that + * it points to the beginning of a Unicode character. + * The offset that is passed in points to + * any code unit of a code point, + * while the returned offset will point to the first code unit + * of the same code point. + * In UTF-16, if the input offset points to a second surrogate + * of a surrogate pair, then the returned offset will point + * to the first surrogate. + * @param offset a valid offset into one code point of the text + * @return offset of the first code unit of the same code point + * @see U16_SET_CP_START + * @stable ICU 2.0 + */ + inline int32_t getChar32Start(int32_t offset) const; + + /** + * Adjust a random-access offset so that + * it points behind a Unicode character. + * The offset that is passed in points behind + * any code unit of a code point, + * while the returned offset will point behind the last code unit + * of the same code point. + * In UTF-16, if the input offset points behind the first surrogate + * (i.e., to the second surrogate) + * of a surrogate pair, then the returned offset will point + * behind the second surrogate (i.e., to the first surrogate). + * @param offset a valid offset after any code unit of a code point of the text + * @return offset of the first code unit after the same code point + * @see U16_SET_CP_LIMIT + * @stable ICU 2.0 + */ + inline int32_t getChar32Limit(int32_t offset) const; + + /** + * Move the code unit index along the string by delta code points. + * Interpret the input index as a code unit-based offset into the string, + * move the index forward or backward by delta code points, and + * return the resulting index. + * The input index should point to the first code unit of a code point, + * if there is more than one. + * + * Both input and output indexes are code unit-based as for all + * string indexes/offsets in ICU (and other libraries, like MBCS char*). + * If delta<0 then the index is moved backward (toward the start of the string). + * If delta>0 then the index is moved forward (toward the end of the string). + * + * This behaves like CharacterIterator::move32(delta, kCurrent). + * + * Behavior for out-of-bounds indexes: + * <code>moveIndex32</code> pins the input index to 0..length(), i.e., + * if the input index<0 then it is pinned to 0; + * if it is index>length() then it is pinned to length(). + * Afterwards, the index is moved by <code>delta</code> code points + * forward or backward, + * but no further backward than to 0 and no further forward than to length(). + * The resulting index return value will be in between 0 and length(), inclusively. + * + * Examples: + * <pre> + * // s has code points 'a' U+10000 'b' U+10ffff U+2029 + * UnicodeString s=UNICODE_STRING("a\\U00010000b\\U0010ffff\\u2029", 31).unescape(); + * + * // initial index: position of U+10000 + * int32_t index=1; + * + * // the following examples will all result in index==4, position of U+10ffff + * + * // skip 2 code points from some position in the string + * index=s.moveIndex32(index, 2); // skips U+10000 and 'b' + * + * // go to the 3rd code point from the start of s (0-based) + * index=s.moveIndex32(0, 3); // skips 'a', U+10000, and 'b' + * + * // go to the next-to-last code point of s + * index=s.moveIndex32(s.length(), -2); // backward-skips U+2029 and U+10ffff + * </pre> + * + * @param index input code unit index + * @param delta (signed) code point count to move the index forward or backward + * in the string + * @return the resulting code unit index + * @stable ICU 2.0 + */ + int32_t moveIndex32(int32_t index, int32_t delta) const; + + /* Substring extraction */ + + /** + * Copy the characters in the range + * [<tt>start</tt>, <tt>start + length</tt>) into the array <tt>dst</tt>, + * beginning at <tt>dstStart</tt>. + * If the string aliases to <code>dst</code> itself as an external buffer, + * then extract() will not copy the contents. + * + * @param start offset of first character which will be copied into the array + * @param length the number of characters to extract + * @param dst array in which to copy characters. The length of <tt>dst</tt> + * must be at least (<tt>dstStart + length</tt>). + * @param dstStart the offset in <TT>dst</TT> where the first character + * will be extracted + * @stable ICU 2.0 + */ + inline void extract(int32_t start, + int32_t length, + UChar *dst, + int32_t dstStart = 0) const; + + /** + * Copy the contents of the string into dest. + * This is a convenience function that + * checks if there is enough space in dest, + * extracts the entire string if possible, + * and NUL-terminates dest if possible. + * + * If the string fits into dest but cannot be NUL-terminated + * (length()==destCapacity) then the error code is set to U_STRING_NOT_TERMINATED_WARNING. + * If the string itself does not fit into dest + * (length()>destCapacity) then the error code is set to U_BUFFER_OVERFLOW_ERROR. + * + * If the string aliases to <code>dest</code> itself as an external buffer, + * then extract() will not copy the contents. + * + * @param dest Destination string buffer. + * @param destCapacity Number of UChars available at dest. + * @param errorCode ICU error code. + * @return length() + * @stable ICU 2.0 + */ + int32_t + extract(UChar *dest, int32_t destCapacity, + UErrorCode &errorCode) const; + + /** + * Copy the characters in the range + * [<tt>start</tt>, <tt>start + length</tt>) into the UnicodeString + * <tt>target</tt>. + * @param start offset of first character which will be copied + * @param length the number of characters to extract + * @param target UnicodeString into which to copy characters. + * @return A reference to <TT>target</TT> + * @stable ICU 2.0 + */ + inline void extract(int32_t start, + int32_t length, + UnicodeString& target) const; + + /** + * Copy the characters in the range [<tt>start</tt>, <tt>limit</tt>) + * into the array <tt>dst</tt>, beginning at <tt>dstStart</tt>. + * @param start offset of first character which will be copied into the array + * @param limit offset immediately following the last character to be copied + * @param dst array in which to copy characters. The length of <tt>dst</tt> + * must be at least (<tt>dstStart + (limit - start)</tt>). + * @param dstStart the offset in <TT>dst</TT> where the first character + * will be extracted + * @stable ICU 2.0 + */ + inline void extractBetween(int32_t start, + int32_t limit, + UChar *dst, + int32_t dstStart = 0) const; + + /** + * Copy the characters in the range [<tt>start</tt>, <tt>limit</tt>) + * into the UnicodeString <tt>target</tt>. Replaceable API. + * @param start offset of first character which will be copied + * @param limit offset immediately following the last character to be copied + * @param target UnicodeString into which to copy characters. + * @return A reference to <TT>target</TT> + * @stable ICU 2.0 + */ + virtual void extractBetween(int32_t start, + int32_t limit, + UnicodeString& target) const; + + /** + * Copy the characters in the range + * [<tt>start</TT>, <tt>start + length</TT>) into an array of characters. + * All characters must be invariant (see utypes.h). + * Use US_INV as the last, signature-distinguishing parameter. + * + * This function does not write any more than <code>targetLength</code> + * characters but returns the length of the entire output string + * so that one can allocate a larger buffer and call the function again + * if necessary. + * The output string is NUL-terminated if possible. + * + * @param start offset of first character which will be copied + * @param startLength the number of characters to extract + * @param target the target buffer for extraction, can be NULL + * if targetLength is 0 + * @param targetCapacity the length of the target buffer + * @param inv Signature-distinguishing paramater, use US_INV. + * @return the output string length, not including the terminating NUL + * @stable ICU 3.2 + */ + int32_t extract(int32_t start, + int32_t startLength, + char *target, + int32_t targetCapacity, + enum EInvariant inv) const; + +#if U_CHARSET_IS_UTF8 || !UCONFIG_NO_CONVERSION + + /** + * Copy the characters in the range + * [<tt>start</TT>, <tt>start + length</TT>) into an array of characters + * in the platform's default codepage. + * This function does not write any more than <code>targetLength</code> + * characters but returns the length of the entire output string + * so that one can allocate a larger buffer and call the function again + * if necessary. + * The output string is NUL-terminated if possible. + * + * @param start offset of first character which will be copied + * @param startLength the number of characters to extract + * @param target the target buffer for extraction + * @param targetLength the length of the target buffer + * If <TT>target</TT> is NULL, then the number of bytes required for + * <TT>target</TT> is returned. + * @return the output string length, not including the terminating NUL + * @stable ICU 2.0 + */ + int32_t extract(int32_t start, + int32_t startLength, + char *target, + uint32_t targetLength) const; + +#endif + +#if !UCONFIG_NO_CONVERSION + + /** + * Copy the characters in the range + * [<tt>start</TT>, <tt>start + length</TT>) into an array of characters + * in a specified codepage. + * The output string is NUL-terminated. + * + * Recommendation: For invariant-character strings use + * extract(int32_t start, int32_t length, char *target, int32_t targetCapacity, enum EInvariant inv) const + * because it avoids object code dependencies of UnicodeString on + * the conversion code. + * + * @param start offset of first character which will be copied + * @param startLength the number of characters to extract + * @param target the target buffer for extraction + * @param codepage the desired codepage for the characters. 0 has + * the special meaning of the default codepage + * If <code>codepage</code> is an empty string (<code>""</code>), + * then a simple conversion is performed on the codepage-invariant + * subset ("invariant characters") of the platform encoding. See utypes.h. + * If <TT>target</TT> is NULL, then the number of bytes required for + * <TT>target</TT> is returned. It is assumed that the target is big enough + * to fit all of the characters. + * @return the output string length, not including the terminating NUL + * @stable ICU 2.0 + */ + inline int32_t extract(int32_t start, + int32_t startLength, + char *target, + const char *codepage = 0) const; + + /** + * Copy the characters in the range + * [<tt>start</TT>, <tt>start + length</TT>) into an array of characters + * in a specified codepage. + * This function does not write any more than <code>targetLength</code> + * characters but returns the length of the entire output string + * so that one can allocate a larger buffer and call the function again + * if necessary. + * The output string is NUL-terminated if possible. + * + * Recommendation: For invariant-character strings use + * extract(int32_t start, int32_t length, char *target, int32_t targetCapacity, enum EInvariant inv) const + * because it avoids object code dependencies of UnicodeString on + * the conversion code. + * + * @param start offset of first character which will be copied + * @param startLength the number of characters to extract + * @param target the target buffer for extraction + * @param targetLength the length of the target buffer + * @param codepage the desired codepage for the characters. 0 has + * the special meaning of the default codepage + * If <code>codepage</code> is an empty string (<code>""</code>), + * then a simple conversion is performed on the codepage-invariant + * subset ("invariant characters") of the platform encoding. See utypes.h. + * If <TT>target</TT> is NULL, then the number of bytes required for + * <TT>target</TT> is returned. + * @return the output string length, not including the terminating NUL + * @stable ICU 2.0 + */ + int32_t extract(int32_t start, + int32_t startLength, + char *target, + uint32_t targetLength, + const char *codepage) const; + + /** + * Convert the UnicodeString into a codepage string using an existing UConverter. + * The output string is NUL-terminated if possible. + * + * This function avoids the overhead of opening and closing a converter if + * multiple strings are extracted. + * + * @param dest destination string buffer, can be NULL if destCapacity==0 + * @param destCapacity the number of chars available at dest + * @param cnv the converter object to be used (ucnv_resetFromUnicode() will be called), + * or NULL for the default converter + * @param errorCode normal ICU error code + * @return the length of the output string, not counting the terminating NUL; + * if the length is greater than destCapacity, then the string will not fit + * and a buffer of the indicated length would need to be passed in + * @stable ICU 2.0 + */ + int32_t extract(char *dest, int32_t destCapacity, + UConverter *cnv, + UErrorCode &errorCode) const; + +#endif + + /** + * Create a temporary substring for the specified range. + * Unlike the substring constructor and setTo() functions, + * the object returned here will be a read-only alias (using getBuffer()) + * rather than copying the text. + * As a result, this substring operation is much faster but requires + * that the original string not be modified or deleted during the lifetime + * of the returned substring object. + * @param start offset of the first character visible in the substring + * @param length length of the substring + * @return a read-only alias UnicodeString object for the substring + * @stable ICU 4.4 + */ + UnicodeString tempSubString(int32_t start=0, int32_t length=INT32_MAX) const; + + /** + * Create a temporary substring for the specified range. + * Same as tempSubString(start, length) except that the substring range + * is specified as a (start, limit) pair (with an exclusive limit index) + * rather than a (start, length) pair. + * @param start offset of the first character visible in the substring + * @param limit offset immediately following the last character visible in the substring + * @return a read-only alias UnicodeString object for the substring + * @stable ICU 4.4 + */ + inline UnicodeString tempSubStringBetween(int32_t start, int32_t limit=INT32_MAX) const; + + /** + * Convert the UnicodeString to UTF-8 and write the result + * to a ByteSink. This is called by toUTF8String(). + * Unpaired surrogates are replaced with U+FFFD. + * Calls u_strToUTF8WithSub(). + * + * @param sink A ByteSink to which the UTF-8 version of the string is written. + * sink.Flush() is called at the end. + * @stable ICU 4.2 + * @see toUTF8String + */ + void toUTF8(ByteSink &sink) const; + +#if U_HAVE_STD_STRING + + /** + * Convert the UnicodeString to UTF-8 and append the result + * to a standard string. + * Unpaired surrogates are replaced with U+FFFD. + * Calls toUTF8(). + * + * @param result A standard string (or a compatible object) + * to which the UTF-8 version of the string is appended. + * @return The string object. + * @stable ICU 4.2 + * @see toUTF8 + */ + template<typename StringClass> + StringClass &toUTF8String(StringClass &result) const { + StringByteSink<StringClass> sbs(&result); + toUTF8(sbs); + return result; + } + +#endif + + /** + * Convert the UnicodeString to UTF-32. + * Unpaired surrogates are replaced with U+FFFD. + * Calls u_strToUTF32WithSub(). + * + * @param utf32 destination string buffer, can be NULL if capacity==0 + * @param capacity the number of UChar32s available at utf32 + * @param errorCode Standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return The length of the UTF-32 string. + * @see fromUTF32 + * @stable ICU 4.2 + */ + int32_t toUTF32(UChar32 *utf32, int32_t capacity, UErrorCode &errorCode) const; + + /* Length operations */ + + /** + * Return the length of the UnicodeString object. + * The length is the number of UChar code units are in the UnicodeString. + * If you want the number of code points, please use countChar32(). + * @return the length of the UnicodeString object + * @see countChar32 + * @stable ICU 2.0 + */ + inline int32_t length(void) const; + + /** + * Count Unicode code points in the length UChar code units of the string. + * A code point may occupy either one or two UChar code units. + * Counting code points involves reading all code units. + * + * This functions is basically the inverse of moveIndex32(). + * + * @param start the index of the first code unit to check + * @param length the number of UChar code units to check + * @return the number of code points in the specified code units + * @see length + * @stable ICU 2.0 + */ + int32_t + countChar32(int32_t start=0, int32_t length=INT32_MAX) const; + + /** + * Check if the length UChar code units of the string + * contain more Unicode code points than a certain number. + * This is more efficient than counting all code points in this part of the string + * and comparing that number with a threshold. + * This function may not need to scan the string at all if the length + * falls within a certain range, and + * never needs to count more than 'number+1' code points. + * Logically equivalent to (countChar32(start, length)>number). + * A Unicode code point may occupy either one or two UChar code units. + * + * @param start the index of the first code unit to check (0 for the entire string) + * @param length the number of UChar code units to check + * (use INT32_MAX for the entire string; remember that start/length + * values are pinned) + * @param number The number of code points in the (sub)string is compared against + * the 'number' parameter. + * @return Boolean value for whether the string contains more Unicode code points + * than 'number'. Same as (u_countChar32(s, length)>number). + * @see countChar32 + * @see u_strHasMoreChar32Than + * @stable ICU 2.4 + */ + UBool + hasMoreChar32Than(int32_t start, int32_t length, int32_t number) const; + + /** + * Determine if this string is empty. + * @return TRUE if this string contains 0 characters, FALSE otherwise. + * @stable ICU 2.0 + */ + inline UBool isEmpty(void) const; + + /** + * Return the capacity of the internal buffer of the UnicodeString object. + * This is useful together with the getBuffer functions. + * See there for details. + * + * @return the number of UChars available in the internal buffer + * @see getBuffer + * @stable ICU 2.0 + */ + inline int32_t getCapacity(void) const; + + /* Other operations */ + + /** + * Generate a hash code for this object. + * @return The hash code of this UnicodeString. + * @stable ICU 2.0 + */ + inline int32_t hashCode(void) const; + + /** + * Determine if this object contains a valid 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. + * setToBogus() and isBogus() can be used to indicate that no string value is available. + * For a bogus string, getBuffer() and getTerminatedBuffer() return NULL, and + * length() returns 0. + * + * @return TRUE if the string is valid, FALSE otherwise + * @see setToBogus() + * @stable ICU 2.0 + */ + inline UBool isBogus(void) const; + + + //======================================== + // Write operations + //======================================== + + /* Assignment operations */ + + /** + * Assignment operator. Replace the characters in this UnicodeString + * with the characters from <TT>srcText</TT>. + * @param srcText The text containing the characters to replace + * @return a reference to this + * @stable ICU 2.0 + */ + UnicodeString &operator=(const UnicodeString &srcText); + + /** + * Almost the same as the assignment operator. + * Replace the characters in this UnicodeString + * with the characters from <code>srcText</code>. + * + * This function works the same for all strings except for ones that + * are readonly aliases. + * Starting with ICU 2.4, the assignment operator and the copy constructor + * allocate a new buffer and copy the buffer contents even for readonly aliases. + * This function implements the old, more efficient but less safe behavior + * of making this string also a readonly alias to the same buffer. + * The fastCopyFrom function must be used only if it is known that the lifetime of + * this UnicodeString is at least as long as the lifetime of the aliased buffer + * including its contents, for example for strings from resource bundles + * or aliases to string contents. + * + * @param src The text containing the characters to replace. + * @return a reference to this + * @stable ICU 2.4 + */ + UnicodeString &fastCopyFrom(const UnicodeString &src); + + /** + * Assignment operator. Replace the characters in this UnicodeString + * with the code unit <TT>ch</TT>. + * @param ch the code unit to replace + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& operator= (UChar ch); + + /** + * Assignment operator. Replace the characters in this UnicodeString + * with the code point <TT>ch</TT>. + * @param ch the code point to replace + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& operator= (UChar32 ch); + + /** + * Set the text in the UnicodeString object to the characters + * in <TT>srcText</TT> in the range + * [<TT>srcStart</TT>, <TT>srcText.length()</TT>). + * <TT>srcText</TT> is not modified. + * @param srcText the source for the new characters + * @param srcStart the offset into <TT>srcText</TT> where new characters + * will be obtained + * @return a reference to this + * @stable ICU 2.2 + */ + inline UnicodeString& setTo(const UnicodeString& srcText, + int32_t srcStart); + + /** + * Set the text in the UnicodeString object to the characters + * in <TT>srcText</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>). + * <TT>srcText</TT> is not modified. + * @param srcText the source for the new characters + * @param srcStart the offset into <TT>srcText</TT> where new characters + * will be obtained + * @param srcLength the number of characters in <TT>srcText</TT> in the + * replace string. + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& setTo(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength); + + /** + * Set the text in the UnicodeString object to the characters in + * <TT>srcText</TT>. + * <TT>srcText</TT> is not modified. + * @param srcText the source for the new characters + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& setTo(const UnicodeString& srcText); + + /** + * Set the characters in the UnicodeString object to the characters + * in <TT>srcChars</TT>. <TT>srcChars</TT> is not modified. + * @param srcChars the source for the new characters + * @param srcLength the number of Unicode characters in srcChars. + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& setTo(const UChar *srcChars, + int32_t srcLength); + + /** + * Set the characters in the UnicodeString object to the code unit + * <TT>srcChar</TT>. + * @param srcChar the code unit which becomes the UnicodeString's character + * content + * @return a reference to this + * @stable ICU 2.0 + */ + UnicodeString& setTo(UChar srcChar); + + /** + * Set the characters in the UnicodeString object to the code point + * <TT>srcChar</TT>. + * @param srcChar the code point which becomes the UnicodeString's character + * content + * @return a reference to this + * @stable ICU 2.0 + */ + UnicodeString& setTo(UChar32 srcChar); + + /** + * Aliasing setTo() function, analogous to the readonly-aliasing UChar* constructor. + * The text will be used for the UnicodeString object, but + * it will not be released when the UnicodeString is destroyed. + * This has copy-on-write semantics: + * When the string is modified, then the buffer is first copied into + * newly allocated memory. + * The aliased buffer is never modified. + * In an assignment to another UnicodeString, the text will be aliased again, + * so that both strings then alias the same readonly-text. + * + * @param isTerminated specifies if <code>text</code> is <code>NUL</code>-terminated. + * This must be true if <code>textLength==-1</code>. + * @param text The characters to alias for the UnicodeString. + * @param textLength The number of Unicode characters in <code>text</code> to alias. + * If -1, then this constructor will determine the length + * by calling <code>u_strlen()</code>. + * @return a reference to this + * @stable ICU 2.0 + */ + UnicodeString &setTo(UBool isTerminated, + const UChar *text, + int32_t textLength); + + /** + * Aliasing setTo() function, analogous to the writable-aliasing UChar* constructor. + * The text will be used for the UnicodeString object, but + * it will not be released when the UnicodeString is destroyed. + * This has write-through semantics: + * For as long as the capacity of the buffer is sufficient, write operations + * will directly affect the buffer. When more capacity is necessary, then + * a new buffer will be allocated and the contents copied as with regularly + * constructed strings. + * In an assignment to another UnicodeString, the buffer will be copied. + * The extract(UChar *dst) function detects whether the dst pointer is the same + * as the string buffer itself and will in this case not copy the contents. + * + * @param buffer The characters to alias for the UnicodeString. + * @param buffLength The number of Unicode characters in <code>buffer</code> to alias. + * @param buffCapacity The size of <code>buffer</code> in UChars. + * @return a reference to this + * @stable ICU 2.0 + */ + UnicodeString &setTo(UChar *buffer, + int32_t buffLength, + int32_t buffCapacity); + + /** + * Make this UnicodeString object invalid. + * The string will test TRUE with isBogus(). + * + * A bogus string has no value. It is different from an empty string. + * It can be used to indicate that no string value is available. + * getBuffer() and getTerminatedBuffer() return NULL, and + * length() returns 0. + * + * This utility function is used throughout the UnicodeString + * implementation to indicate that a UnicodeString operation failed, + * and may be used in other functions, + * especially but not exclusively when such functions do not + * take a UErrorCode for simplicity. + * + * The following methods, and no others, will clear a string object's bogus flag: + * - remove() + * - remove(0, INT32_MAX) + * - truncate(0) + * - operator=() (assignment operator) + * - setTo(...) + * + * The simplest ways to turn a bogus string into an empty one + * is to use the remove() function. + * Examples for other functions that are equivalent to "set to empty string": + * \code + * if(s.isBogus()) { + * s.remove(); // set to an empty string (remove all), or + * s.remove(0, INT32_MAX); // set to an empty string (remove all), or + * s.truncate(0); // set to an empty string (complete truncation), or + * s=UnicodeString(); // assign an empty string, or + * s.setTo((UChar32)-1); // set to a pseudo code point that is out of range, or + * static const UChar nul=0; + * s.setTo(&nul, 0); // set to an empty C Unicode string + * } + * \endcode + * + * @see isBogus() + * @stable ICU 2.0 + */ + void setToBogus(); + + /** + * Set the character at the specified offset to the specified character. + * @param offset A valid offset into the text of the character to set + * @param ch The new character + * @return A reference to this + * @stable ICU 2.0 + */ + UnicodeString& setCharAt(int32_t offset, + UChar ch); + + + /* Append operations */ + + /** + * Append operator. Append the code unit <TT>ch</TT> to the UnicodeString + * object. + * @param ch the code unit to be appended + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& operator+= (UChar ch); + + /** + * Append operator. Append the code point <TT>ch</TT> to the UnicodeString + * object. + * @param ch the code point to be appended + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& operator+= (UChar32 ch); + + /** + * Append operator. Append the characters in <TT>srcText</TT> to the + * UnicodeString object at offset <TT>start</TT>. <TT>srcText</TT> is + * not modified. + * @param srcText the source for the new characters + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& operator+= (const UnicodeString& srcText); + + /** + * Append the characters + * in <TT>srcText</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>) to the + * UnicodeString object at offset <TT>start</TT>. <TT>srcText</TT> + * is not modified. + * @param srcText the source for the new characters + * @param srcStart the offset into <TT>srcText</TT> where new characters + * will be obtained + * @param srcLength the number of characters in <TT>srcText</TT> in + * the append string + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& append(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength); + + /** + * Append the characters in <TT>srcText</TT> to the UnicodeString object at + * offset <TT>start</TT>. <TT>srcText</TT> is not modified. + * @param srcText the source for the new characters + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& append(const UnicodeString& srcText); + + /** + * Append the characters in <TT>srcChars</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>) to the UnicodeString + * object at offset + * <TT>start</TT>. <TT>srcChars</TT> is not modified. + * @param srcChars the source for the new characters + * @param srcStart the offset into <TT>srcChars</TT> where new characters + * will be obtained + * @param srcLength the number of characters in <TT>srcChars</TT> in + * the append string + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& append(const UChar *srcChars, + int32_t srcStart, + int32_t srcLength); + + /** + * Append the characters in <TT>srcChars</TT> to the UnicodeString object + * at offset <TT>start</TT>. <TT>srcChars</TT> is not modified. + * @param srcChars the source for the new characters + * @param srcLength the number of Unicode characters in <TT>srcChars</TT> + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& append(const UChar *srcChars, + int32_t srcLength); + + /** + * Append the code unit <TT>srcChar</TT> to the UnicodeString object. + * @param srcChar the code unit to append + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& append(UChar srcChar); + + /** + * Append the code point <TT>srcChar</TT> to the UnicodeString object. + * @param srcChar the code point to append + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& append(UChar32 srcChar); + + + /* Insert operations */ + + /** + * Insert the characters in <TT>srcText</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>) into the UnicodeString + * object at offset <TT>start</TT>. <TT>srcText</TT> is not modified. + * @param start the offset where the insertion begins + * @param srcText the source for the new characters + * @param srcStart the offset into <TT>srcText</TT> where new characters + * will be obtained + * @param srcLength the number of characters in <TT>srcText</TT> in + * the insert string + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& insert(int32_t start, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength); + + /** + * Insert the characters in <TT>srcText</TT> into the UnicodeString object + * at offset <TT>start</TT>. <TT>srcText</TT> is not modified. + * @param start the offset where the insertion begins + * @param srcText the source for the new characters + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& insert(int32_t start, + const UnicodeString& srcText); + + /** + * Insert the characters in <TT>srcChars</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>) into the UnicodeString + * object at offset <TT>start</TT>. <TT>srcChars</TT> is not modified. + * @param start the offset at which the insertion begins + * @param srcChars the source for the new characters + * @param srcStart the offset into <TT>srcChars</TT> where new characters + * will be obtained + * @param srcLength the number of characters in <TT>srcChars</TT> + * in the insert string + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& insert(int32_t start, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength); + + /** + * Insert the characters in <TT>srcChars</TT> into the UnicodeString object + * at offset <TT>start</TT>. <TT>srcChars</TT> is not modified. + * @param start the offset where the insertion begins + * @param srcChars the source for the new characters + * @param srcLength the number of Unicode characters in srcChars. + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& insert(int32_t start, + const UChar *srcChars, + int32_t srcLength); + + /** + * Insert the code unit <TT>srcChar</TT> into the UnicodeString object at + * offset <TT>start</TT>. + * @param start the offset at which the insertion occurs + * @param srcChar the code unit to insert + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& insert(int32_t start, + UChar srcChar); + + /** + * Insert the code point <TT>srcChar</TT> into the UnicodeString object at + * offset <TT>start</TT>. + * @param start the offset at which the insertion occurs + * @param srcChar the code point to insert + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& insert(int32_t start, + UChar32 srcChar); + + + /* Replace operations */ + + /** + * Replace the characters in the range + * [<TT>start</TT>, <TT>start + length</TT>) with the characters in + * <TT>srcText</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>). + * <TT>srcText</TT> is not modified. + * @param start the offset at which the replace operation begins + * @param length the number of characters to replace. The character at + * <TT>start + length</TT> is not modified. + * @param srcText the source for the new characters + * @param srcStart the offset into <TT>srcText</TT> where new characters + * will be obtained + * @param srcLength the number of characters in <TT>srcText</TT> in + * the replace string + * @return a reference to this + * @stable ICU 2.0 + */ + UnicodeString& replace(int32_t start, + int32_t length, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength); + + /** + * Replace the characters in the range + * [<TT>start</TT>, <TT>start + length</TT>) + * with the characters in <TT>srcText</TT>. <TT>srcText</TT> is + * not modified. + * @param start the offset at which the replace operation begins + * @param length the number of characters to replace. The character at + * <TT>start + length</TT> is not modified. + * @param srcText the source for the new characters + * @return a reference to this + * @stable ICU 2.0 + */ + UnicodeString& replace(int32_t start, + int32_t length, + const UnicodeString& srcText); + + /** + * Replace the characters in the range + * [<TT>start</TT>, <TT>start + length</TT>) with the characters in + * <TT>srcChars</TT> in the range + * [<TT>srcStart</TT>, <TT>srcStart + srcLength</TT>). <TT>srcChars</TT> + * is not modified. + * @param start the offset at which the replace operation begins + * @param length the number of characters to replace. The character at + * <TT>start + length</TT> is not modified. + * @param srcChars the source for the new characters + * @param srcStart the offset into <TT>srcChars</TT> where new characters + * will be obtained + * @param srcLength the number of characters in <TT>srcChars</TT> + * in the replace string + * @return a reference to this + * @stable ICU 2.0 + */ + UnicodeString& replace(int32_t start, + int32_t length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength); + + /** + * Replace the characters in the range + * [<TT>start</TT>, <TT>start + length</TT>) with the characters in + * <TT>srcChars</TT>. <TT>srcChars</TT> is not modified. + * @param start the offset at which the replace operation begins + * @param length number of characters to replace. The character at + * <TT>start + length</TT> is not modified. + * @param srcChars the source for the new characters + * @param srcLength the number of Unicode characters in srcChars + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& replace(int32_t start, + int32_t length, + const UChar *srcChars, + int32_t srcLength); + + /** + * Replace the characters in the range + * [<TT>start</TT>, <TT>start + length</TT>) with the code unit + * <TT>srcChar</TT>. + * @param start the offset at which the replace operation begins + * @param length the number of characters to replace. The character at + * <TT>start + length</TT> is not modified. + * @param srcChar the new code unit + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& replace(int32_t start, + int32_t length, + UChar srcChar); + + /** + * Replace the characters in the range + * [<TT>start</TT>, <TT>start + length</TT>) with the code point + * <TT>srcChar</TT>. + * @param start the offset at which the replace operation begins + * @param length the number of characters to replace. The character at + * <TT>start + length</TT> is not modified. + * @param srcChar the new code point + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& replace(int32_t start, + int32_t length, + UChar32 srcChar); + + /** + * Replace the characters in the range [<TT>start</TT>, <TT>limit</TT>) + * with the characters in <TT>srcText</TT>. <TT>srcText</TT> is not modified. + * @param start the offset at which the replace operation begins + * @param limit the offset immediately following the replace range + * @param srcText the source for the new characters + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& replaceBetween(int32_t start, + int32_t limit, + const UnicodeString& srcText); + + /** + * Replace the characters in the range [<TT>start</TT>, <TT>limit</TT>) + * with the characters in <TT>srcText</TT> in the range + * [<TT>srcStart</TT>, <TT>srcLimit</TT>). <TT>srcText</TT> is not modified. + * @param start the offset at which the replace operation begins + * @param limit the offset immediately following the replace range + * @param srcText the source for the new characters + * @param srcStart the offset into <TT>srcChars</TT> where new characters + * will be obtained + * @param srcLimit the offset immediately following the range to copy + * in <TT>srcText</TT> + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& replaceBetween(int32_t start, + int32_t limit, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLimit); + + /** + * Replace a substring of this object with the given text. + * @param start the beginning index, inclusive; <code>0 <= start + * <= limit</code>. + * @param limit the ending index, exclusive; <code>start <= limit + * <= length()</code>. + * @param text the text to replace characters <code>start</code> + * to <code>limit - 1</code> + * @stable ICU 2.0 + */ + virtual void handleReplaceBetween(int32_t start, + int32_t limit, + const UnicodeString& text); + + /** + * Replaceable API + * @return TRUE if it has MetaData + * @stable ICU 2.4 + */ + virtual UBool hasMetaData() const; + + /** + * Copy a substring of this object, retaining attribute (out-of-band) + * information. This method is used to duplicate or reorder substrings. + * The destination index must not overlap the source range. + * + * @param start the beginning index, inclusive; <code>0 <= start <= + * limit</code>. + * @param limit the ending index, exclusive; <code>start <= limit <= + * length()</code>. + * @param dest the destination index. The characters from + * <code>start..limit-1</code> will be copied to <code>dest</code>. + * Implementations of this method may assume that <code>dest <= start || + * dest >= limit</code>. + * @stable ICU 2.0 + */ + virtual void copy(int32_t start, int32_t limit, int32_t dest); + + /* Search and replace operations */ + + /** + * Replace all occurrences of characters in oldText with the characters + * in newText + * @param oldText the text containing the search text + * @param newText the text containing the replacement text + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& findAndReplace(const UnicodeString& oldText, + const UnicodeString& newText); + + /** + * Replace all occurrences of characters in oldText with characters + * in newText + * in the range [<TT>start</TT>, <TT>start + length</TT>). + * @param start the start of the range in which replace will performed + * @param length the length of the range in which replace will be performed + * @param oldText the text containing the search text + * @param newText the text containing the replacement text + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& findAndReplace(int32_t start, + int32_t length, + const UnicodeString& oldText, + const UnicodeString& newText); + + /** + * Replace all occurrences of characters in oldText in the range + * [<TT>oldStart</TT>, <TT>oldStart + oldLength</TT>) with the characters + * in newText in the range + * [<TT>newStart</TT>, <TT>newStart + newLength</TT>) + * in the range [<TT>start</TT>, <TT>start + length</TT>). + * @param start the start of the range in which replace will performed + * @param length the length of the range in which replace will be performed + * @param oldText the text containing the search text + * @param oldStart the start of the search range in <TT>oldText</TT> + * @param oldLength the length of the search range in <TT>oldText</TT> + * @param newText the text containing the replacement text + * @param newStart the start of the replacement range in <TT>newText</TT> + * @param newLength the length of the replacement range in <TT>newText</TT> + * @return a reference to this + * @stable ICU 2.0 + */ + UnicodeString& findAndReplace(int32_t start, + int32_t length, + const UnicodeString& oldText, + int32_t oldStart, + int32_t oldLength, + const UnicodeString& newText, + int32_t newStart, + int32_t newLength); + + + /* Remove operations */ + + /** + * Remove all characters from the UnicodeString object. + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& remove(void); + + /** + * Remove the characters in the range + * [<TT>start</TT>, <TT>start + length</TT>) from the UnicodeString object. + * @param start the offset of the first character to remove + * @param length the number of characters to remove + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& remove(int32_t start, + int32_t length = (int32_t)INT32_MAX); + + /** + * Remove the characters in the range + * [<TT>start</TT>, <TT>limit</TT>) from the UnicodeString object. + * @param start the offset of the first character to remove + * @param limit the offset immediately following the range to remove + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& removeBetween(int32_t start, + int32_t limit = (int32_t)INT32_MAX); + + /** + * Retain only the characters in the range + * [<code>start</code>, <code>limit</code>) from the UnicodeString object. + * Removes characters before <code>start</code> and at and after <code>limit</code>. + * @param start the offset of the first character to retain + * @param limit the offset immediately following the range to retain + * @return a reference to this + * @stable ICU 4.4 + */ + inline UnicodeString &retainBetween(int32_t start, int32_t limit = INT32_MAX); + + /* Length operations */ + + /** + * Pad the start of this UnicodeString with the character <TT>padChar</TT>. + * If the length of this UnicodeString is less than targetLength, + * length() - targetLength copies of padChar will be added to the + * beginning of this UnicodeString. + * @param targetLength the desired length of the string + * @param padChar the character to use for padding. Defaults to + * space (U+0020) + * @return TRUE if the text was padded, FALSE otherwise. + * @stable ICU 2.0 + */ + UBool padLeading(int32_t targetLength, + UChar padChar = 0x0020); + + /** + * Pad the end of this UnicodeString with the character <TT>padChar</TT>. + * If the length of this UnicodeString is less than targetLength, + * length() - targetLength copies of padChar will be added to the + * end of this UnicodeString. + * @param targetLength the desired length of the string + * @param padChar the character to use for padding. Defaults to + * space (U+0020) + * @return TRUE if the text was padded, FALSE otherwise. + * @stable ICU 2.0 + */ + UBool padTrailing(int32_t targetLength, + UChar padChar = 0x0020); + + /** + * Truncate this UnicodeString to the <TT>targetLength</TT>. + * @param targetLength the desired length of this UnicodeString. + * @return TRUE if the text was truncated, FALSE otherwise + * @stable ICU 2.0 + */ + inline UBool truncate(int32_t targetLength); + + /** + * Trims leading and trailing whitespace from this UnicodeString. + * @return a reference to this + * @stable ICU 2.0 + */ + UnicodeString& trim(void); + + + /* Miscellaneous operations */ + + /** + * Reverse this UnicodeString in place. + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& reverse(void); + + /** + * Reverse the range [<TT>start</TT>, <TT>start + length</TT>) in + * this UnicodeString. + * @param start the start of the range to reverse + * @param length the number of characters to to reverse + * @return a reference to this + * @stable ICU 2.0 + */ + inline UnicodeString& reverse(int32_t start, + int32_t length); + + /** + * Convert the characters in this to UPPER CASE following the conventions of + * the default locale. + * @return A reference to this. + * @stable ICU 2.0 + */ + UnicodeString& toUpper(void); + + /** + * Convert the characters in this to UPPER CASE following the conventions of + * a specific locale. + * @param locale The locale containing the conventions to use. + * @return A reference to this. + * @stable ICU 2.0 + */ + UnicodeString& toUpper(const Locale& locale); + + /** + * Convert the characters in this to lower case following the conventions of + * the default locale. + * @return A reference to this. + * @stable ICU 2.0 + */ + UnicodeString& toLower(void); + + /** + * Convert the characters in this to lower case following the conventions of + * a specific locale. + * @param locale The locale containing the conventions to use. + * @return A reference to this. + * @stable ICU 2.0 + */ + UnicodeString& toLower(const Locale& locale); + +#if !UCONFIG_NO_BREAK_ITERATION + + /** + * Titlecase this string, convenience function using the default locale. + * + * Casing is locale-dependent and context-sensitive. + * Titlecasing uses a break iterator to find the first characters of words + * that are to be titlecased. It titlecases those characters and lowercases + * all others. + * + * The titlecase break iterator can be provided to customize for arbitrary + * styles, using rules and dictionaries beyond the standard iterators. + * It may be more efficient to always provide an iterator to avoid + * opening and closing one for each string. + * The standard titlecase iterator for the root locale implements the + * algorithm of Unicode TR 21. + * + * This function uses only the setText(), first() and next() methods of the + * provided break iterator. + * + * @param titleIter A break iterator to find the first characters of words + * that are to be titlecased. + * If none is provided (0), then a standard titlecase + * break iterator is opened. + * Otherwise the provided iterator is set to the string's text. + * @return A reference to this. + * @stable ICU 2.1 + */ + UnicodeString &toTitle(BreakIterator *titleIter); + + /** + * Titlecase this string. + * + * Casing is locale-dependent and context-sensitive. + * Titlecasing uses a break iterator to find the first characters of words + * that are to be titlecased. It titlecases those characters and lowercases + * all others. + * + * The titlecase break iterator can be provided to customize for arbitrary + * styles, using rules and dictionaries beyond the standard iterators. + * It may be more efficient to always provide an iterator to avoid + * opening and closing one for each string. + * The standard titlecase iterator for the root locale implements the + * algorithm of Unicode TR 21. + * + * This function uses only the setText(), first() and next() methods of the + * provided break iterator. + * + * @param titleIter A break iterator to find the first characters of words + * that are to be titlecased. + * If none is provided (0), then a standard titlecase + * break iterator is opened. + * Otherwise the provided iterator is set to the string's text. + * @param locale The locale to consider. + * @return A reference to this. + * @stable ICU 2.1 + */ + UnicodeString &toTitle(BreakIterator *titleIter, const Locale &locale); + + /** + * Titlecase this string, with options. + * + * Casing is locale-dependent and context-sensitive. + * Titlecasing uses a break iterator to find the first characters of words + * that are to be titlecased. It titlecases those characters and lowercases + * all others. (This can be modified with options.) + * + * The titlecase break iterator can be provided to customize for arbitrary + * styles, using rules and dictionaries beyond the standard iterators. + * It may be more efficient to always provide an iterator to avoid + * opening and closing one for each string. + * The standard titlecase iterator for the root locale implements the + * algorithm of Unicode TR 21. + * + * This function uses only the setText(), first() and next() methods of the + * provided break iterator. + * + * @param titleIter A break iterator to find the first characters of words + * that are to be titlecased. + * If none is provided (0), then a standard titlecase + * break iterator is opened. + * Otherwise the provided iterator is set to the string's text. + * @param locale The locale to consider. + * @param options Options bit set, see ucasemap_open(). + * @return A reference to this. + * @see U_TITLECASE_NO_LOWERCASE + * @see U_TITLECASE_NO_BREAK_ADJUSTMENT + * @see ucasemap_open + * @stable ICU 3.8 + */ + UnicodeString &toTitle(BreakIterator *titleIter, const Locale &locale, uint32_t options); + +#endif + + /** + * Case-fold the characters in this string. + * Case-folding is locale-independent and not context-sensitive, + * but there is an option for whether to include or exclude mappings for dotted I + * and dotless i that are marked with 'I' in CaseFolding.txt. + * The result may be longer or shorter than the original. + * + * @param options Either U_FOLD_CASE_DEFAULT or U_FOLD_CASE_EXCLUDE_SPECIAL_I + * @return A reference to this. + * @stable ICU 2.0 + */ + UnicodeString &foldCase(uint32_t options=0 /*U_FOLD_CASE_DEFAULT*/); + + //======================================== + // Access to the internal buffer + //======================================== + + /** + * Get a read/write pointer to the internal buffer. + * The buffer is guaranteed to be large enough for at least minCapacity UChars, + * writable, and is still owned by the UnicodeString object. + * Calls to getBuffer(minCapacity) must not be nested, and + * must be matched with calls to releaseBuffer(newLength). + * If the string buffer was read-only or shared, + * then it will be reallocated and copied. + * + * An attempted nested call will return 0, and will not further modify the + * state of the UnicodeString object. + * It also returns 0 if the string is bogus. + * + * The actual capacity of the string buffer may be larger than minCapacity. + * getCapacity() returns the actual capacity. + * For many operations, the full capacity should be used to avoid reallocations. + * + * While the buffer is "open" between getBuffer(minCapacity) + * and releaseBuffer(newLength), the following applies: + * - The string length is set to 0. + * - Any read API call on the UnicodeString object will behave like on a 0-length string. + * - Any write API call on the UnicodeString object is disallowed and will have no effect. + * - You can read from and write to the returned buffer. + * - The previous string contents will still be in the buffer; + * if you want to use it, then you need to call length() before getBuffer(minCapacity). + * If the length() was greater than minCapacity, then any contents after minCapacity + * may be lost. + * The buffer contents is not NUL-terminated by getBuffer(). + * If length()<getCapacity() then you can terminate it by writing a NUL + * at index length(). + * - You must call releaseBuffer(newLength) before and in order to + * return to normal UnicodeString operation. + * + * @param minCapacity the minimum number of UChars that are to be available + * in the buffer, starting at the returned pointer; + * default to the current string capacity if minCapacity==-1 + * @return a writable pointer to the internal string buffer, + * or 0 if an error occurs (nested calls, out of memory) + * + * @see releaseBuffer + * @see getTerminatedBuffer() + * @stable ICU 2.0 + */ + UChar *getBuffer(int32_t minCapacity); + + /** + * Release a read/write buffer on a UnicodeString object with an + * "open" getBuffer(minCapacity). + * This function must be called in a matched pair with getBuffer(minCapacity). + * releaseBuffer(newLength) must be called if and only if a getBuffer(minCapacity) is "open". + * + * It will set the string length to newLength, at most to the current capacity. + * If newLength==-1 then it will set the length according to the + * first NUL in the buffer, or to the capacity if there is no NUL. + * + * After calling releaseBuffer(newLength) the UnicodeString is back to normal operation. + * + * @param newLength the new length of the UnicodeString object; + * defaults to the current capacity if newLength is greater than that; + * if newLength==-1, it defaults to u_strlen(buffer) but not more than + * the current capacity of the string + * + * @see getBuffer(int32_t minCapacity) + * @stable ICU 2.0 + */ + void releaseBuffer(int32_t newLength=-1); + + /** + * Get a read-only pointer to the internal buffer. + * This can be called at any time on a valid UnicodeString. + * + * It returns 0 if the string is bogus, or + * during an "open" getBuffer(minCapacity). + * + * It can be called as many times as desired. + * The pointer that it returns will remain valid until the UnicodeString object is modified, + * at which time the pointer is semantically invalidated and must not be used any more. + * + * The capacity of the buffer can be determined with getCapacity(). + * The part after length() may or may not be initialized and valid, + * depending on the history of the UnicodeString object. + * + * The buffer contents is (probably) not NUL-terminated. + * You can check if it is with + * <code>(s.length()<s.getCapacity() && buffer[s.length()]==0)</code>. + * (See getTerminatedBuffer().) + * + * The buffer may reside in read-only memory. Its contents must not + * be modified. + * + * @return a read-only pointer to the internal string buffer, + * or 0 if the string is empty or bogus + * + * @see getBuffer(int32_t minCapacity) + * @see getTerminatedBuffer() + * @stable ICU 2.0 + */ + inline const UChar *getBuffer() const; + + /** + * Get a read-only pointer to the internal buffer, + * making sure that it is NUL-terminated. + * This can be called at any time on a valid UnicodeString. + * + * It returns 0 if the string is bogus, or + * during an "open" getBuffer(minCapacity), or if the buffer cannot + * be NUL-terminated (because memory allocation failed). + * + * It can be called as many times as desired. + * The pointer that it returns will remain valid until the UnicodeString object is modified, + * at which time the pointer is semantically invalidated and must not be used any more. + * + * The capacity of the buffer can be determined with getCapacity(). + * The part after length()+1 may or may not be initialized and valid, + * depending on the history of the UnicodeString object. + * + * The buffer contents is guaranteed to be NUL-terminated. + * getTerminatedBuffer() may reallocate the buffer if a terminating NUL + * is written. + * For this reason, this function is not const, unlike getBuffer(). + * Note that a UnicodeString may also contain NUL characters as part of its contents. + * + * The buffer may reside in read-only memory. Its contents must not + * be modified. + * + * @return a read-only pointer to the internal string buffer, + * or 0 if the string is empty or bogus + * + * @see getBuffer(int32_t minCapacity) + * @see getBuffer() + * @stable ICU 2.2 + */ + inline const UChar *getTerminatedBuffer(); + + //======================================== + // Constructors + //======================================== + + /** Construct an empty UnicodeString. + * @stable ICU 2.0 + */ + UnicodeString(); + + /** + * Construct a UnicodeString with capacity to hold <TT>capacity</TT> UChars + * @param capacity the number of UChars this UnicodeString should hold + * before a resize is necessary; if count is greater than 0 and count + * code points c take up more space than capacity, then capacity is adjusted + * accordingly. + * @param c is used to initially fill the string + * @param count specifies how many code points c are to be written in the + * string + * @stable ICU 2.0 + */ + UnicodeString(int32_t capacity, UChar32 c, int32_t count); + + /** + * Single UChar (code unit) constructor. + * @param ch the character to place in the UnicodeString + * @stable ICU 2.0 + */ + UnicodeString(UChar ch); + + /** + * Single UChar32 (code point) constructor. + * @param ch the character to place in the UnicodeString + * @stable ICU 2.0 + */ + UnicodeString(UChar32 ch); + + /** + * UChar* constructor. + * @param text The characters to place in the UnicodeString. <TT>text</TT> + * must be NULL (U+0000) terminated. + * @stable ICU 2.0 + */ + UnicodeString(const UChar *text); + + /** + * UChar* constructor. + * @param text The characters to place in the UnicodeString. + * @param textLength The number of Unicode characters in <TT>text</TT> + * to copy. + * @stable ICU 2.0 + */ + UnicodeString(const UChar *text, + int32_t textLength); + + /** + * Readonly-aliasing UChar* constructor. + * The text will be used for the UnicodeString object, but + * it will not be released when the UnicodeString is destroyed. + * This has copy-on-write semantics: + * When the string is modified, then the buffer is first copied into + * newly allocated memory. + * The aliased buffer is never modified. + * In an assignment to another UnicodeString, the text will be aliased again, + * so that both strings then alias the same readonly-text. + * + * @param isTerminated specifies if <code>text</code> is <code>NUL</code>-terminated. + * This must be true if <code>textLength==-1</code>. + * @param text The characters to alias for the UnicodeString. + * @param textLength The number of Unicode characters in <code>text</code> to alias. + * If -1, then this constructor will determine the length + * by calling <code>u_strlen()</code>. + * @stable ICU 2.0 + */ + UnicodeString(UBool isTerminated, + const UChar *text, + int32_t textLength); + + /** + * Writable-aliasing UChar* constructor. + * The text will be used for the UnicodeString object, but + * it will not be released when the UnicodeString is destroyed. + * This has write-through semantics: + * For as long as the capacity of the buffer is sufficient, write operations + * will directly affect the buffer. When more capacity is necessary, then + * a new buffer will be allocated and the contents copied as with regularly + * constructed strings. + * In an assignment to another UnicodeString, the buffer will be copied. + * The extract(UChar *dst) function detects whether the dst pointer is the same + * as the string buffer itself and will in this case not copy the contents. + * + * @param buffer The characters to alias for the UnicodeString. + * @param buffLength The number of Unicode characters in <code>buffer</code> to alias. + * @param buffCapacity The size of <code>buffer</code> in UChars. + * @stable ICU 2.0 + */ + UnicodeString(UChar *buffer, int32_t buffLength, int32_t buffCapacity); + +#if U_CHARSET_IS_UTF8 || !UCONFIG_NO_CONVERSION + + /** + * char* constructor. + * @param codepageData an array of bytes, null-terminated, + * in the platform's default codepage. + * @stable ICU 2.0 + */ + UnicodeString(const char *codepageData); + + /** + * char* constructor. + * @param codepageData an array of bytes in the platform's default codepage. + * @param dataLength The number of bytes in <TT>codepageData</TT>. + * @stable ICU 2.0 + */ + UnicodeString(const char *codepageData, int32_t dataLength); + +#endif + +#if !UCONFIG_NO_CONVERSION + + /** + * char* constructor. + * @param codepageData an array of bytes, null-terminated + * @param codepage the encoding of <TT>codepageData</TT>. The special + * value 0 for <TT>codepage</TT> indicates that the text is in the + * platform's default codepage. + * + * If <code>codepage</code> is an empty string (<code>""</code>), + * then a simple conversion is performed on the codepage-invariant + * subset ("invariant characters") of the platform encoding. See utypes.h. + * Recommendation: For invariant-character strings use the constructor + * UnicodeString(const char *src, int32_t length, enum EInvariant inv) + * because it avoids object code dependencies of UnicodeString on + * the conversion code. + * + * @stable ICU 2.0 + */ + UnicodeString(const char *codepageData, const char *codepage); + + /** + * char* constructor. + * @param codepageData an array of bytes. + * @param dataLength The number of bytes in <TT>codepageData</TT>. + * @param codepage the encoding of <TT>codepageData</TT>. The special + * value 0 for <TT>codepage</TT> indicates that the text is in the + * platform's default codepage. + * If <code>codepage</code> is an empty string (<code>""</code>), + * then a simple conversion is performed on the codepage-invariant + * subset ("invariant characters") of the platform encoding. See utypes.h. + * Recommendation: For invariant-character strings use the constructor + * UnicodeString(const char *src, int32_t length, enum EInvariant inv) + * because it avoids object code dependencies of UnicodeString on + * the conversion code. + * + * @stable ICU 2.0 + */ + UnicodeString(const char *codepageData, int32_t dataLength, const char *codepage); + + /** + * char * / UConverter constructor. + * This constructor uses an existing UConverter object to + * convert the codepage string to Unicode and construct a UnicodeString + * from that. + * + * The converter is reset at first. + * If the error code indicates a failure before this constructor is called, + * or if an error occurs during conversion or construction, + * then the string will be bogus. + * + * This function avoids the overhead of opening and closing a converter if + * multiple strings are constructed. + * + * @param src input codepage string + * @param srcLength length of the input string, can be -1 for NUL-terminated strings + * @param cnv converter object (ucnv_resetToUnicode() will be called), + * can be NULL for the default converter + * @param errorCode normal ICU error code + * @stable ICU 2.0 + */ + UnicodeString( + const char *src, int32_t srcLength, + UConverter *cnv, + UErrorCode &errorCode); + +#endif + + /** + * Constructs a Unicode string from an invariant-character char * string. + * About invariant characters see utypes.h. + * This constructor has no runtime dependency on conversion code and is + * therefore recommended over ones taking a charset name string + * (where the empty string "" indicates invariant-character conversion). + * + * Use the macro US_INV as the third, signature-distinguishing parameter. + * + * For example: + * \code + * void fn(const char *s) { + * UnicodeString ustr(s, -1, US_INV); + * // use ustr ... + * } + * \endcode + * + * @param src String using only invariant characters. + * @param length Length of src, or -1 if NUL-terminated. + * @param inv Signature-distinguishing paramater, use US_INV. + * + * @see US_INV + * @stable ICU 3.2 + */ + UnicodeString(const char *src, int32_t length, enum EInvariant inv); + + + /** + * Copy constructor. + * @param that The UnicodeString object to copy. + * @stable ICU 2.0 + */ + UnicodeString(const UnicodeString& that); + + /** + * 'Substring' constructor from tail of source string. + * @param src The UnicodeString object to copy. + * @param srcStart The offset into <tt>src</tt> at which to start copying. + * @stable ICU 2.2 + */ + UnicodeString(const UnicodeString& src, int32_t srcStart); + + /** + * 'Substring' constructor from subrange of source string. + * @param src The UnicodeString object to copy. + * @param srcStart The offset into <tt>src</tt> at which to start copying. + * @param srcLength The number of characters from <tt>src</tt> to copy. + * @stable ICU 2.2 + */ + UnicodeString(const UnicodeString& src, int32_t srcStart, int32_t srcLength); + + /** + * Clone this object, an instance of a subclass of Replaceable. + * Clones can be used concurrently in multiple threads. + * If a subclass does not implement clone(), or if an error occurs, + * then NULL is returned. + * The clone functions in all subclasses return a pointer to a Replaceable + * because some compilers do not support covariant (same-as-this) + * return types; cast to the appropriate subclass if necessary. + * The caller must delete the clone. + * + * @return a clone of this object + * + * @see Replaceable::clone + * @see getDynamicClassID + * @stable ICU 2.6 + */ + virtual Replaceable *clone() const; + + /** Destructor. + * @stable ICU 2.0 + */ + virtual ~UnicodeString(); + + /** + * Create a UnicodeString from a UTF-8 string. + * Illegal input is replaced with U+FFFD. Otherwise, errors result in a bogus string. + * Calls u_strFromUTF8WithSub(). + * + * @param utf8 UTF-8 input string. + * Note that a StringPiece can be implicitly constructed + * from a std::string or a NUL-terminated const char * string. + * @return A UnicodeString with equivalent UTF-16 contents. + * @see toUTF8 + * @see toUTF8String + * @stable ICU 4.2 + */ + static UnicodeString fromUTF8(const StringPiece &utf8); + + /** + * Create a UnicodeString from a UTF-32 string. + * Illegal input is replaced with U+FFFD. Otherwise, errors result in a bogus string. + * Calls u_strFromUTF32WithSub(). + * + * @param utf32 UTF-32 input string. Must not be NULL. + * @param length Length of the input string, or -1 if NUL-terminated. + * @return A UnicodeString with equivalent UTF-16 contents. + * @see toUTF32 + * @stable ICU 4.2 + */ + static UnicodeString fromUTF32(const UChar32 *utf32, int32_t length); + + /* Miscellaneous operations */ + + /** + * Unescape a string of characters and return a string containing + * the result. The following escape sequences are recognized: + * + * \\uhhhh 4 hex digits; h in [0-9A-Fa-f] + * \\Uhhhhhhhh 8 hex digits + * \\xhh 1-2 hex digits + * \\ooo 1-3 octal digits; o in [0-7] + * \\cX control-X; X is masked with 0x1F + * + * as well as the standard ANSI C escapes: + * + * \\a => U+0007, \\b => U+0008, \\t => U+0009, \\n => U+000A, + * \\v => U+000B, \\f => U+000C, \\r => U+000D, \\e => U+001B, + * \\" => U+0022, \\' => U+0027, \\? => U+003F, \\\\ => U+005C + * + * Anything else following a backslash is generically escaped. For + * example, "[a\\-z]" returns "[a-z]". + * + * If an escape sequence is ill-formed, this method returns an empty + * string. An example of an ill-formed sequence is "\\u" followed by + * fewer than 4 hex digits. + * + * This function is similar to u_unescape() but not identical to it. + * The latter takes a source char*, so it does escape recognition + * and also invariant conversion. + * + * @return a string with backslash escapes interpreted, or an + * empty string on error. + * @see UnicodeString#unescapeAt() + * @see u_unescape() + * @see u_unescapeAt() + * @stable ICU 2.0 + */ + UnicodeString unescape() const; + + /** + * Unescape a single escape sequence and return the represented + * character. See unescape() for a listing of the recognized escape + * sequences. The character at offset-1 is assumed (without + * checking) to be a backslash. If the escape sequence is + * ill-formed, or the offset is out of range, (UChar32)0xFFFFFFFF is + * returned. + * + * @param offset an input output parameter. On input, it is the + * offset into this string where the escape sequence is located, + * after the initial backslash. On output, it is advanced after the + * last character parsed. On error, it is not advanced at all. + * @return the character represented by the escape sequence at + * offset, or (UChar32)0xFFFFFFFF on error. + * @see UnicodeString#unescape() + * @see u_unescape() + * @see u_unescapeAt() + * @stable ICU 2.0 + */ + UChar32 unescapeAt(int32_t &offset) const; + + /** + * ICU "poor man's RTTI", returns a UClassID for this class. + * + * @stable ICU 2.2 + */ + static UClassID U_EXPORT2 getStaticClassID(); + + /** + * ICU "poor man's RTTI", returns a UClassID for the actual class. + * + * @stable ICU 2.2 + */ + virtual UClassID getDynamicClassID() const; + + //======================================== + // Implementation methods + //======================================== + +protected: + /** + * Implement Replaceable::getLength() (see jitterbug 1027). + * @stable ICU 2.4 + */ + virtual int32_t getLength() const; + + /** + * The change in Replaceable to use virtual getCharAt() allows + * UnicodeString::charAt() to be inline again (see jitterbug 709). + * @stable ICU 2.4 + */ + virtual UChar getCharAt(int32_t offset) const; + + /** + * The change in Replaceable to use virtual getChar32At() allows + * UnicodeString::char32At() to be inline again (see jitterbug 709). + * @stable ICU 2.4 + */ + virtual UChar32 getChar32At(int32_t offset) const; + +private: + // For char* constructors. Could be made public. + UnicodeString &setToUTF8(const StringPiece &utf8); + // For extract(char*). + // We could make a toUTF8(target, capacity, errorCode) public but not + // this version: New API will be cleaner if we make callers create substrings + // rather than having start+length on every method, + // and it should take a UErrorCode&. + int32_t + toUTF8(int32_t start, int32_t len, + char *target, int32_t capacity) const; + + + inline int8_t + doCompare(int32_t start, + int32_t length, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const; + + int8_t doCompare(int32_t start, + int32_t length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) const; + + inline int8_t + doCompareCodePointOrder(int32_t start, + int32_t length, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const; + + int8_t doCompareCodePointOrder(int32_t start, + int32_t length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) const; + + inline int8_t + doCaseCompare(int32_t start, + int32_t length, + const UnicodeString &srcText, + int32_t srcStart, + int32_t srcLength, + uint32_t options) const; + + int8_t + doCaseCompare(int32_t start, + int32_t length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength, + uint32_t options) const; + + int32_t doIndexOf(UChar c, + int32_t start, + int32_t length) const; + + int32_t doIndexOf(UChar32 c, + int32_t start, + int32_t length) const; + + int32_t doLastIndexOf(UChar c, + int32_t start, + int32_t length) const; + + int32_t doLastIndexOf(UChar32 c, + int32_t start, + int32_t length) const; + + void doExtract(int32_t start, + int32_t length, + UChar *dst, + int32_t dstStart) const; + + inline void doExtract(int32_t start, + int32_t length, + UnicodeString& target) const; + + inline UChar doCharAt(int32_t offset) const; + + UnicodeString& doReplace(int32_t start, + int32_t length, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength); + + UnicodeString& doReplace(int32_t start, + int32_t length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength); + + UnicodeString& doReverse(int32_t start, + int32_t length); + + // calculate hash code + int32_t doHashCode(void) const; + + // get pointer to start of array + // these do not check for kOpenGetBuffer, unlike the public getBuffer() function + inline UChar* getArrayStart(void); + inline const UChar* getArrayStart(void) const; + + // A UnicodeString object (not necessarily its current buffer) + // is writable unless it isBogus() or it has an "open" getBuffer(minCapacity). + inline UBool isWritable() const; + + // Is the current buffer writable? + inline UBool isBufferWritable() const; + + // None of the following does releaseArray(). + inline void setLength(int32_t len); // sets only fShortLength and fLength + inline void setToEmpty(); // sets fFlags=kShortString + inline void setArray(UChar *array, int32_t len, int32_t capacity); // does not set fFlags + + // allocate the array; result may be fStackBuffer + // sets refCount to 1 if appropriate + // sets fArray, fCapacity, and fFlags + // returns boolean for success or failure + UBool allocate(int32_t capacity); + + // release the array if owned + void releaseArray(void); + + // turn a bogus string into an empty one + void unBogus(); + + // implements assigment operator, copy constructor, and fastCopyFrom() + UnicodeString ©From(const UnicodeString &src, UBool fastCopy=FALSE); + + // Pin start and limit to acceptable values. + inline void pinIndex(int32_t& start) const; + inline void pinIndices(int32_t& start, + int32_t& length) const; + +#if !UCONFIG_NO_CONVERSION + + /* Internal extract() using UConverter. */ + int32_t doExtract(int32_t start, int32_t length, + char *dest, int32_t destCapacity, + UConverter *cnv, + UErrorCode &errorCode) const; + + /* + * Real constructor for converting from codepage data. + * It assumes that it is called with !fRefCounted. + * + * If <code>codepage==0</code>, then the default converter + * is used for the platform encoding. + * If <code>codepage</code> is an empty string (<code>""</code>), + * then a simple conversion is performed on the codepage-invariant + * subset ("invariant characters") of the platform encoding. See utypes.h. + */ + void doCodepageCreate(const char *codepageData, + int32_t dataLength, + const char *codepage); + + /* + * Worker function for creating a UnicodeString from + * a codepage string using a UConverter. + */ + void + doCodepageCreate(const char *codepageData, + int32_t dataLength, + UConverter *converter, + UErrorCode &status); + +#endif + + /* + * This function is called when write access to the array + * is necessary. + * + * We need to make a copy of the array if + * the buffer is read-only, or + * the buffer is refCounted (shared), and refCount>1, or + * the buffer is too small. + * + * Return FALSE if memory could not be allocated. + */ + UBool cloneArrayIfNeeded(int32_t newCapacity = -1, + int32_t growCapacity = -1, + UBool doCopyArray = TRUE, + int32_t **pBufferToDelete = 0, + UBool forceClone = FALSE); + + // common function for case mappings + UnicodeString & + caseMap(BreakIterator *titleIter, + const char *locale, + uint32_t options, + int32_t toWhichCase); + + // ref counting + void addRef(void); + int32_t removeRef(void); + int32_t refCount(void) const; + + // constants + enum { + // Set the stack buffer size so that sizeof(UnicodeString) is a multiple of sizeof(pointer): + // 32-bit pointers: 4+1+1+13*2 = 32 bytes + // 64-bit pointers: 8+1+1+15*2 = 40 bytes + US_STACKBUF_SIZE= sizeof(void *)==4 ? 13 : 15, // Size of stack buffer for small strings + kInvalidUChar=0xffff, // invalid UChar index + kGrowSize=128, // grow size for this buffer + kInvalidHashCode=0, // invalid hash code + kEmptyHashCode=1, // hash code for empty string + + // bit flag values for fFlags + kIsBogus=1, // this string is bogus, i.e., not valid or NULL + kUsingStackBuffer=2,// fArray==fStackBuffer + kRefCounted=4, // there is a refCount field before the characters in fArray + kBufferIsReadonly=8,// do not write to this buffer + kOpenGetBuffer=16, // getBuffer(minCapacity) was called (is "open"), + // and releaseBuffer(newLength) must be called + + // combined values for convenience + kShortString=kUsingStackBuffer, + kLongString=kRefCounted, + kReadonlyAlias=kBufferIsReadonly, + kWritableAlias=0 + }; + + friend class StringThreadTest; + + union StackBufferOrFields; // forward declaration necessary before friend declaration + friend union StackBufferOrFields; // make US_STACKBUF_SIZE visible inside fUnion + + /* + * The following are all the class fields that are stored + * in each UnicodeString object. + * Note that UnicodeString has virtual functions, + * therefore there is an implicit vtable pointer + * as the first real field. + * The fields should be aligned such that no padding is + * necessary, mostly by having larger types first. + * On 32-bit machines, the size should be 32 bytes, + * on 64-bit machines (8-byte pointers), it should be 40 bytes. + */ + // (implicit) *vtable; + int8_t fShortLength; // 0..127: length <0: real length is in fUnion.fFields.fLength + uint8_t fFlags; // bit flags: see constants above + union StackBufferOrFields { + // fStackBuffer is used iff (fFlags&kUsingStackBuffer) + // else fFields is used + UChar fStackBuffer [US_STACKBUF_SIZE]; // buffer for small strings + struct { + uint16_t fPadding; // align the following field at 8B (32b pointers) or 12B (64b) + int32_t fLength; // number of characters in fArray if >127; else undefined + UChar *fArray; // the Unicode data (aligned at 12B (32b pointers) or 16B (64b)) + int32_t fCapacity; // sizeof fArray + } fFields; + } fUnion; +}; + +/** + * Create a new UnicodeString with the concatenation of two others. + * + * @param s1 The first string to be copied to the new one. + * @param s2 The second string to be copied to the new one, after s1. + * @return UnicodeString(s1).append(s2) + * @stable ICU 2.8 + */ +U_COMMON_API UnicodeString U_EXPORT2 +operator+ (const UnicodeString &s1, const UnicodeString &s2); + +//======================================== +// Inline members +//======================================== + +//======================================== +// Privates +//======================================== + +inline void +UnicodeString::pinIndex(int32_t& start) const +{ + // pin index + if(start < 0) { + start = 0; + } else if(start > length()) { + start = length(); + } +} + +inline void +UnicodeString::pinIndices(int32_t& start, + int32_t& _length) const +{ + // pin indices + int32_t len = length(); + if(start < 0) { + start = 0; + } else if(start > len) { + start = len; + } + if(_length < 0) { + _length = 0; + } else if(_length > (len - start)) { + _length = (len - start); + } +} + +inline UChar* +UnicodeString::getArrayStart() +{ return (fFlags&kUsingStackBuffer) ? fUnion.fStackBuffer : fUnion.fFields.fArray; } + +inline const UChar* +UnicodeString::getArrayStart() const +{ return (fFlags&kUsingStackBuffer) ? fUnion.fStackBuffer : fUnion.fFields.fArray; } + +//======================================== +// Read-only implementation methods +//======================================== +inline int32_t +UnicodeString::length() const +{ return fShortLength>=0 ? fShortLength : fUnion.fFields.fLength; } + +inline int32_t +UnicodeString::getCapacity() const +{ return (fFlags&kUsingStackBuffer) ? US_STACKBUF_SIZE : fUnion.fFields.fCapacity; } + +inline int32_t +UnicodeString::hashCode() const +{ return doHashCode(); } + +inline UBool +UnicodeString::isBogus() const +{ return (UBool)(fFlags & kIsBogus); } + +inline UBool +UnicodeString::isWritable() const +{ return (UBool)!(fFlags&(kOpenGetBuffer|kIsBogus)); } + +inline UBool +UnicodeString::isBufferWritable() const +{ + return (UBool)( + !(fFlags&(kOpenGetBuffer|kIsBogus|kBufferIsReadonly)) && + (!(fFlags&kRefCounted) || refCount()==1)); +} + +inline const UChar * +UnicodeString::getBuffer() const { + if(fFlags&(kIsBogus|kOpenGetBuffer)) { + return 0; + } else if(fFlags&kUsingStackBuffer) { + return fUnion.fStackBuffer; + } else { + return fUnion.fFields.fArray; + } +} + +//======================================== +// Read-only alias methods +//======================================== +inline int8_t +UnicodeString::doCompare(int32_t start, + int32_t thisLength, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const +{ + if(srcText.isBogus()) { + return (int8_t)!isBogus(); // 0 if both are bogus, 1 otherwise + } else { + srcText.pinIndices(srcStart, srcLength); + return doCompare(start, thisLength, srcText.getArrayStart(), srcStart, srcLength); + } +} + +inline UBool +UnicodeString::operator== (const UnicodeString& text) const +{ + if(isBogus()) { + return text.isBogus(); + } else { + int32_t len = length(), textLength = text.length(); + return + !text.isBogus() && + len == textLength && + doCompare(0, len, text, 0, textLength) == 0; + } +} + +inline UBool +UnicodeString::operator!= (const UnicodeString& text) const +{ return (! operator==(text)); } + +inline UBool +UnicodeString::operator> (const UnicodeString& text) const +{ return doCompare(0, length(), text, 0, text.length()) == 1; } + +inline UBool +UnicodeString::operator< (const UnicodeString& text) const +{ return doCompare(0, length(), text, 0, text.length()) == -1; } + +inline UBool +UnicodeString::operator>= (const UnicodeString& text) const +{ return doCompare(0, length(), text, 0, text.length()) != -1; } + +inline UBool +UnicodeString::operator<= (const UnicodeString& text) const +{ return doCompare(0, length(), text, 0, text.length()) != 1; } + +inline int8_t +UnicodeString::compare(const UnicodeString& text) const +{ return doCompare(0, length(), text, 0, text.length()); } + +inline int8_t +UnicodeString::compare(int32_t start, + int32_t _length, + const UnicodeString& srcText) const +{ return doCompare(start, _length, srcText, 0, srcText.length()); } + +inline int8_t +UnicodeString::compare(const UChar *srcChars, + int32_t srcLength) const +{ return doCompare(0, length(), srcChars, 0, srcLength); } + +inline int8_t +UnicodeString::compare(int32_t start, + int32_t _length, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const +{ return doCompare(start, _length, srcText, srcStart, srcLength); } + +inline int8_t +UnicodeString::compare(int32_t start, + int32_t _length, + const UChar *srcChars) const +{ return doCompare(start, _length, srcChars, 0, _length); } + +inline int8_t +UnicodeString::compare(int32_t start, + int32_t _length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) const +{ return doCompare(start, _length, srcChars, srcStart, srcLength); } + +inline int8_t +UnicodeString::compareBetween(int32_t start, + int32_t limit, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLimit) const +{ return doCompare(start, limit - start, + srcText, srcStart, srcLimit - srcStart); } + +inline int8_t +UnicodeString::doCompareCodePointOrder(int32_t start, + int32_t thisLength, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const +{ + if(srcText.isBogus()) { + return (int8_t)!isBogus(); // 0 if both are bogus, 1 otherwise + } else { + srcText.pinIndices(srcStart, srcLength); + return doCompareCodePointOrder(start, thisLength, srcText.getArrayStart(), srcStart, srcLength); + } +} + +inline int8_t +UnicodeString::compareCodePointOrder(const UnicodeString& text) const +{ return doCompareCodePointOrder(0, length(), text, 0, text.length()); } + +inline int8_t +UnicodeString::compareCodePointOrder(int32_t start, + int32_t _length, + const UnicodeString& srcText) const +{ return doCompareCodePointOrder(start, _length, srcText, 0, srcText.length()); } + +inline int8_t +UnicodeString::compareCodePointOrder(const UChar *srcChars, + int32_t srcLength) const +{ return doCompareCodePointOrder(0, length(), srcChars, 0, srcLength); } + +inline int8_t +UnicodeString::compareCodePointOrder(int32_t start, + int32_t _length, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const +{ return doCompareCodePointOrder(start, _length, srcText, srcStart, srcLength); } + +inline int8_t +UnicodeString::compareCodePointOrder(int32_t start, + int32_t _length, + const UChar *srcChars) const +{ return doCompareCodePointOrder(start, _length, srcChars, 0, _length); } + +inline int8_t +UnicodeString::compareCodePointOrder(int32_t start, + int32_t _length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) const +{ return doCompareCodePointOrder(start, _length, srcChars, srcStart, srcLength); } + +inline int8_t +UnicodeString::compareCodePointOrderBetween(int32_t start, + int32_t limit, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLimit) const +{ return doCompareCodePointOrder(start, limit - start, + srcText, srcStart, srcLimit - srcStart); } + +inline int8_t +UnicodeString::doCaseCompare(int32_t start, + int32_t thisLength, + const UnicodeString &srcText, + int32_t srcStart, + int32_t srcLength, + uint32_t options) const +{ + if(srcText.isBogus()) { + return (int8_t)!isBogus(); // 0 if both are bogus, 1 otherwise + } else { + srcText.pinIndices(srcStart, srcLength); + return doCaseCompare(start, thisLength, srcText.getArrayStart(), srcStart, srcLength, options); + } +} + +inline int8_t +UnicodeString::caseCompare(const UnicodeString &text, uint32_t options) const { + return doCaseCompare(0, length(), text, 0, text.length(), options); +} + +inline int8_t +UnicodeString::caseCompare(int32_t start, + int32_t _length, + const UnicodeString &srcText, + uint32_t options) const { + return doCaseCompare(start, _length, srcText, 0, srcText.length(), options); +} + +inline int8_t +UnicodeString::caseCompare(const UChar *srcChars, + int32_t srcLength, + uint32_t options) const { + return doCaseCompare(0, length(), srcChars, 0, srcLength, options); +} + +inline int8_t +UnicodeString::caseCompare(int32_t start, + int32_t _length, + const UnicodeString &srcText, + int32_t srcStart, + int32_t srcLength, + uint32_t options) const { + return doCaseCompare(start, _length, srcText, srcStart, srcLength, options); +} + +inline int8_t +UnicodeString::caseCompare(int32_t start, + int32_t _length, + const UChar *srcChars, + uint32_t options) const { + return doCaseCompare(start, _length, srcChars, 0, _length, options); +} + +inline int8_t +UnicodeString::caseCompare(int32_t start, + int32_t _length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength, + uint32_t options) const { + return doCaseCompare(start, _length, srcChars, srcStart, srcLength, options); +} + +inline int8_t +UnicodeString::caseCompareBetween(int32_t start, + int32_t limit, + const UnicodeString &srcText, + int32_t srcStart, + int32_t srcLimit, + uint32_t options) const { + return doCaseCompare(start, limit - start, srcText, srcStart, srcLimit - srcStart, options); +} + +inline int32_t +UnicodeString::indexOf(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength, + int32_t start, + int32_t _length) const +{ + if(!srcText.isBogus()) { + srcText.pinIndices(srcStart, srcLength); + if(srcLength > 0) { + return indexOf(srcText.getArrayStart(), srcStart, srcLength, start, _length); + } + } + return -1; +} + +inline int32_t +UnicodeString::indexOf(const UnicodeString& text) const +{ return indexOf(text, 0, text.length(), 0, length()); } + +inline int32_t +UnicodeString::indexOf(const UnicodeString& text, + int32_t start) const { + pinIndex(start); + return indexOf(text, 0, text.length(), start, length() - start); +} + +inline int32_t +UnicodeString::indexOf(const UnicodeString& text, + int32_t start, + int32_t _length) const +{ return indexOf(text, 0, text.length(), start, _length); } + +inline int32_t +UnicodeString::indexOf(const UChar *srcChars, + int32_t srcLength, + int32_t start) const { + pinIndex(start); + return indexOf(srcChars, 0, srcLength, start, length() - start); +} + +inline int32_t +UnicodeString::indexOf(const UChar *srcChars, + int32_t srcLength, + int32_t start, + int32_t _length) const +{ return indexOf(srcChars, 0, srcLength, start, _length); } + +inline int32_t +UnicodeString::indexOf(UChar c, + int32_t start, + int32_t _length) const +{ return doIndexOf(c, start, _length); } + +inline int32_t +UnicodeString::indexOf(UChar32 c, + int32_t start, + int32_t _length) const +{ return doIndexOf(c, start, _length); } + +inline int32_t +UnicodeString::indexOf(UChar c) const +{ return doIndexOf(c, 0, length()); } + +inline int32_t +UnicodeString::indexOf(UChar32 c) const +{ return indexOf(c, 0, length()); } + +inline int32_t +UnicodeString::indexOf(UChar c, + int32_t start) const { + pinIndex(start); + return doIndexOf(c, start, length() - start); +} + +inline int32_t +UnicodeString::indexOf(UChar32 c, + int32_t start) const { + pinIndex(start); + return indexOf(c, start, length() - start); +} + +inline int32_t +UnicodeString::lastIndexOf(const UChar *srcChars, + int32_t srcLength, + int32_t start, + int32_t _length) const +{ return lastIndexOf(srcChars, 0, srcLength, start, _length); } + +inline int32_t +UnicodeString::lastIndexOf(const UChar *srcChars, + int32_t srcLength, + int32_t start) const { + pinIndex(start); + return lastIndexOf(srcChars, 0, srcLength, start, length() - start); +} + +inline int32_t +UnicodeString::lastIndexOf(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength, + int32_t start, + int32_t _length) const +{ + if(!srcText.isBogus()) { + srcText.pinIndices(srcStart, srcLength); + if(srcLength > 0) { + return lastIndexOf(srcText.getArrayStart(), srcStart, srcLength, start, _length); + } + } + return -1; +} + +inline int32_t +UnicodeString::lastIndexOf(const UnicodeString& text, + int32_t start, + int32_t _length) const +{ return lastIndexOf(text, 0, text.length(), start, _length); } + +inline int32_t +UnicodeString::lastIndexOf(const UnicodeString& text, + int32_t start) const { + pinIndex(start); + return lastIndexOf(text, 0, text.length(), start, length() - start); +} + +inline int32_t +UnicodeString::lastIndexOf(const UnicodeString& text) const +{ return lastIndexOf(text, 0, text.length(), 0, length()); } + +inline int32_t +UnicodeString::lastIndexOf(UChar c, + int32_t start, + int32_t _length) const +{ return doLastIndexOf(c, start, _length); } + +inline int32_t +UnicodeString::lastIndexOf(UChar32 c, + int32_t start, + int32_t _length) const { + return doLastIndexOf(c, start, _length); +} + +inline int32_t +UnicodeString::lastIndexOf(UChar c) const +{ return doLastIndexOf(c, 0, length()); } + +inline int32_t +UnicodeString::lastIndexOf(UChar32 c) const { + return lastIndexOf(c, 0, length()); +} + +inline int32_t +UnicodeString::lastIndexOf(UChar c, + int32_t start) const { + pinIndex(start); + return doLastIndexOf(c, start, length() - start); +} + +inline int32_t +UnicodeString::lastIndexOf(UChar32 c, + int32_t start) const { + pinIndex(start); + return lastIndexOf(c, start, length() - start); +} + +inline UBool +UnicodeString::startsWith(const UnicodeString& text) const +{ return compare(0, text.length(), text, 0, text.length()) == 0; } + +inline UBool +UnicodeString::startsWith(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const +{ return doCompare(0, srcLength, srcText, srcStart, srcLength) == 0; } + +inline UBool +UnicodeString::startsWith(const UChar *srcChars, + int32_t srcLength) const +{ return doCompare(0, srcLength, srcChars, 0, srcLength) == 0; } + +inline UBool +UnicodeString::startsWith(const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) const +{ return doCompare(0, srcLength, srcChars, srcStart, srcLength) == 0;} + +inline UBool +UnicodeString::endsWith(const UnicodeString& text) const +{ return doCompare(length() - text.length(), text.length(), + text, 0, text.length()) == 0; } + +inline UBool +UnicodeString::endsWith(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) const { + srcText.pinIndices(srcStart, srcLength); + return doCompare(length() - srcLength, srcLength, + srcText, srcStart, srcLength) == 0; +} + +inline UBool +UnicodeString::endsWith(const UChar *srcChars, + int32_t srcLength) const { + if(srcLength < 0) { + srcLength = u_strlen(srcChars); + } + return doCompare(length() - srcLength, srcLength, + srcChars, 0, srcLength) == 0; +} + +inline UBool +UnicodeString::endsWith(const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) const { + if(srcLength < 0) { + srcLength = u_strlen(srcChars + srcStart); + } + return doCompare(length() - srcLength, srcLength, + srcChars, srcStart, srcLength) == 0; +} + +//======================================== +// replace +//======================================== +inline UnicodeString& +UnicodeString::replace(int32_t start, + int32_t _length, + const UnicodeString& srcText) +{ return doReplace(start, _length, srcText, 0, srcText.length()); } + +inline UnicodeString& +UnicodeString::replace(int32_t start, + int32_t _length, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) +{ return doReplace(start, _length, srcText, srcStart, srcLength); } + +inline UnicodeString& +UnicodeString::replace(int32_t start, + int32_t _length, + const UChar *srcChars, + int32_t srcLength) +{ return doReplace(start, _length, srcChars, 0, srcLength); } + +inline UnicodeString& +UnicodeString::replace(int32_t start, + int32_t _length, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) +{ return doReplace(start, _length, srcChars, srcStart, srcLength); } + +inline UnicodeString& +UnicodeString::replace(int32_t start, + int32_t _length, + UChar srcChar) +{ return doReplace(start, _length, &srcChar, 0, 1); } + +inline UnicodeString& +UnicodeString::replace(int32_t start, + int32_t _length, + UChar32 srcChar) { + UChar buffer[U16_MAX_LENGTH]; + int32_t count = 0; + UBool isError = FALSE; + U16_APPEND(buffer, count, U16_MAX_LENGTH, srcChar, isError); + return doReplace(start, _length, buffer, 0, count); +} + +inline UnicodeString& +UnicodeString::replaceBetween(int32_t start, + int32_t limit, + const UnicodeString& srcText) +{ return doReplace(start, limit - start, srcText, 0, srcText.length()); } + +inline UnicodeString& +UnicodeString::replaceBetween(int32_t start, + int32_t limit, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLimit) +{ return doReplace(start, limit - start, srcText, srcStart, srcLimit - srcStart); } + +inline UnicodeString& +UnicodeString::findAndReplace(const UnicodeString& oldText, + const UnicodeString& newText) +{ return findAndReplace(0, length(), oldText, 0, oldText.length(), + newText, 0, newText.length()); } + +inline UnicodeString& +UnicodeString::findAndReplace(int32_t start, + int32_t _length, + const UnicodeString& oldText, + const UnicodeString& newText) +{ return findAndReplace(start, _length, oldText, 0, oldText.length(), + newText, 0, newText.length()); } + +// ============================ +// extract +// ============================ +inline void +UnicodeString::doExtract(int32_t start, + int32_t _length, + UnicodeString& target) const +{ target.replace(0, target.length(), *this, start, _length); } + +inline void +UnicodeString::extract(int32_t start, + int32_t _length, + UChar *target, + int32_t targetStart) const +{ doExtract(start, _length, target, targetStart); } + +inline void +UnicodeString::extract(int32_t start, + int32_t _length, + UnicodeString& target) const +{ doExtract(start, _length, target); } + +#if !UCONFIG_NO_CONVERSION + +inline int32_t +UnicodeString::extract(int32_t start, + int32_t _length, + char *dst, + const char *codepage) const + +{ + // This dstSize value will be checked explicitly + // Removed #if defined(__GNUC__) per ICU defect http://bugs.icu-project.org/trac/ticket/8197 + return extract(start, _length, dst, dst!=0 ? 0xffffffff : 0, codepage); +} +#endif + +inline void +UnicodeString::extractBetween(int32_t start, + int32_t limit, + UChar *dst, + int32_t dstStart) const { + pinIndex(start); + pinIndex(limit); + doExtract(start, limit - start, dst, dstStart); +} + +inline UnicodeString +UnicodeString::tempSubStringBetween(int32_t start, int32_t limit) const { + return tempSubString(start, limit - start); +} + +inline UChar +UnicodeString::doCharAt(int32_t offset) const +{ + if((uint32_t)offset < (uint32_t)length()) { + return getArrayStart()[offset]; + } else { + return kInvalidUChar; + } +} + +inline UChar +UnicodeString::charAt(int32_t offset) const +{ return doCharAt(offset); } + +inline UChar +UnicodeString::operator[] (int32_t offset) const +{ return doCharAt(offset); } + +inline UChar32 +UnicodeString::char32At(int32_t offset) const +{ + int32_t len = length(); + if((uint32_t)offset < (uint32_t)len) { + const UChar *array = getArrayStart(); + UChar32 c; + U16_GET(array, 0, offset, len, c); + return c; + } else { + return kInvalidUChar; + } +} + +inline int32_t +UnicodeString::getChar32Start(int32_t offset) const { + if((uint32_t)offset < (uint32_t)length()) { + const UChar *array = getArrayStart(); + U16_SET_CP_START(array, 0, offset); + return offset; + } else { + return 0; + } +} + +inline int32_t +UnicodeString::getChar32Limit(int32_t offset) const { + int32_t len = length(); + if((uint32_t)offset < (uint32_t)len) { + const UChar *array = getArrayStart(); + U16_SET_CP_LIMIT(array, 0, offset, len); + return offset; + } else { + return len; + } +} + +inline UBool +UnicodeString::isEmpty() const { + return fShortLength == 0; +} + +//======================================== +// Write implementation methods +//======================================== +inline void +UnicodeString::setLength(int32_t len) { + if(len <= 127) { + fShortLength = (int8_t)len; + } else { + fShortLength = (int8_t)-1; + fUnion.fFields.fLength = len; + } +} + +inline void +UnicodeString::setToEmpty() { + fShortLength = 0; + fFlags = kShortString; +} + +inline void +UnicodeString::setArray(UChar *array, int32_t len, int32_t capacity) { + setLength(len); + fUnion.fFields.fArray = array; + 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 modified + * without copy-on-write, e.g., via truncate(newLength) or remove(void). + * Then the NUL would be written into the middle of another copy's string. + */ + 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 contents + * modified, but the NUL at [len] is beyond the string contents, + * and multiple string objects and threads writing the same NUL into the + * same location is harmless. + * In all other cases, the buffer is fully writable and it is anyway 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& +UnicodeString::operator= (UChar ch) +{ return doReplace(0, length(), &ch, 0, 1); } + +inline UnicodeString& +UnicodeString::operator= (UChar32 ch) +{ return replace(0, length(), ch); } + +inline UnicodeString& +UnicodeString::setTo(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) +{ + unBogus(); + return doReplace(0, length(), srcText, srcStart, srcLength); +} + +inline UnicodeString& +UnicodeString::setTo(const UnicodeString& srcText, + int32_t srcStart) +{ + unBogus(); + srcText.pinIndex(srcStart); + return doReplace(0, length(), srcText, srcStart, srcText.length() - srcStart); +} + +inline UnicodeString& +UnicodeString::setTo(const UnicodeString& srcText) +{ + unBogus(); + return doReplace(0, length(), srcText, 0, srcText.length()); +} + +inline UnicodeString& +UnicodeString::setTo(const UChar *srcChars, + int32_t srcLength) +{ + unBogus(); + return doReplace(0, length(), srcChars, 0, srcLength); +} + +inline UnicodeString& +UnicodeString::setTo(UChar srcChar) +{ + unBogus(); + return doReplace(0, length(), &srcChar, 0, 1); +} + +inline UnicodeString& +UnicodeString::setTo(UChar32 srcChar) +{ + unBogus(); + return replace(0, length(), srcChar); +} + +inline UnicodeString& +UnicodeString::append(const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) +{ return doReplace(length(), 0, srcText, srcStart, srcLength); } + +inline UnicodeString& +UnicodeString::append(const UnicodeString& srcText) +{ return doReplace(length(), 0, srcText, 0, srcText.length()); } + +inline UnicodeString& +UnicodeString::append(const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) +{ return doReplace(length(), 0, srcChars, srcStart, srcLength); } + +inline UnicodeString& +UnicodeString::append(const UChar *srcChars, + int32_t srcLength) +{ return doReplace(length(), 0, srcChars, 0, srcLength); } + +inline UnicodeString& +UnicodeString::append(UChar srcChar) +{ return doReplace(length(), 0, &srcChar, 0, 1); } + +inline UnicodeString& +UnicodeString::append(UChar32 srcChar) { + UChar buffer[U16_MAX_LENGTH]; + int32_t _length = 0; + UBool isError = FALSE; + U16_APPEND(buffer, _length, U16_MAX_LENGTH, srcChar, isError); + return doReplace(length(), 0, buffer, 0, _length); +} + +inline UnicodeString& +UnicodeString::operator+= (UChar ch) +{ return doReplace(length(), 0, &ch, 0, 1); } + +inline UnicodeString& +UnicodeString::operator+= (UChar32 ch) { + return append(ch); +} + +inline UnicodeString& +UnicodeString::operator+= (const UnicodeString& srcText) +{ return doReplace(length(), 0, srcText, 0, srcText.length()); } + +inline UnicodeString& +UnicodeString::insert(int32_t start, + const UnicodeString& srcText, + int32_t srcStart, + int32_t srcLength) +{ return doReplace(start, 0, srcText, srcStart, srcLength); } + +inline UnicodeString& +UnicodeString::insert(int32_t start, + const UnicodeString& srcText) +{ return doReplace(start, 0, srcText, 0, srcText.length()); } + +inline UnicodeString& +UnicodeString::insert(int32_t start, + const UChar *srcChars, + int32_t srcStart, + int32_t srcLength) +{ return doReplace(start, 0, srcChars, srcStart, srcLength); } + +inline UnicodeString& +UnicodeString::insert(int32_t start, + const UChar *srcChars, + int32_t srcLength) +{ return doReplace(start, 0, srcChars, 0, srcLength); } + +inline UnicodeString& +UnicodeString::insert(int32_t start, + UChar srcChar) +{ return doReplace(start, 0, &srcChar, 0, 1); } + +inline UnicodeString& +UnicodeString::insert(int32_t start, + UChar32 srcChar) +{ return replace(start, 0, srcChar); } + + +inline UnicodeString& +UnicodeString::remove() +{ + // 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 + // issues with getTerminatedBuffer() + if(fFlags & (kIsBogus|kBufferIsReadonly)) { + setToEmpty(); + } else { + fShortLength = 0; + } + return *this; +} + +inline UnicodeString& +UnicodeString::remove(int32_t start, + int32_t _length) +{ + if(start <= 0 && _length == INT32_MAX) { + // remove(guaranteed everything) of a bogus string makes the string empty and non-bogus + return remove(); + } + return doReplace(start, _length, NULL, 0, 0); +} + +inline UnicodeString& +UnicodeString::removeBetween(int32_t start, + int32_t limit) +{ return doReplace(start, limit - start, NULL, 0, 0); } + +inline UnicodeString & +UnicodeString::retainBetween(int32_t start, int32_t limit) { + truncate(limit); + return doReplace(0, start, NULL, 0, 0); +} + +inline UBool +UnicodeString::truncate(int32_t targetLength) +{ + if(isBogus() && targetLength == 0) { + // truncate(0) of a bogus string makes the string empty and non-bogus + unBogus(); + return FALSE; + } else if((uint32_t)targetLength < (uint32_t)length()) { + setLength(targetLength); + if(fFlags&kBufferIsReadonly) { + fUnion.fFields.fCapacity = targetLength; // not NUL-terminated any more + } + return TRUE; + } else { + return FALSE; + } +} + +inline UnicodeString& +UnicodeString::reverse() +{ return doReverse(0, length()); } + +inline UnicodeString& +UnicodeString::reverse(int32_t start, + int32_t _length) +{ return doReverse(start, _length); } + +U_NAMESPACE_END + +#endif diff --git a/Source/WTF/icu/unicode/unorm.h b/Source/WTF/icu/unicode/unorm.h index 8bdbee7c6..fbb7b49b3 100644 --- a/Source/WTF/icu/unicode/unorm.h +++ b/Source/WTF/icu/unicode/unorm.h @@ -1,6 +1,6 @@ /* ******************************************************************************* -* Copyright (c) 1996-2004, International Business Machines Corporation +* Copyright (c) 1996-2010, International Business Machines Corporation * and others. All Rights Reserved. ******************************************************************************* * File unorm.h @@ -20,6 +20,7 @@ #if !UCONFIG_NO_NORMALIZATION #include "unicode/uiter.h" +#include "unicode/unorm2.h" /** * \file @@ -27,11 +28,16 @@ * * <h2>Unicode normalization API</h2> * + * Note: This API has been replaced by the unorm2.h API and is only available + * for backward compatibility. The functions here simply delegate to the + * unorm2.h functions, for example unorm2_getInstance() and unorm2_normalize(). + * There is one exception: The new API does not provide a replacement for unorm_compare(). + * * <code>unorm_normalize</code> transforms Unicode text into an equivalent composed or * decomposed form, allowing for easier sorting and searching of text. * <code>unorm_normalize</code> supports the standard normalization forms described in * <a href="http://www.unicode.org/unicode/reports/tr15/" target="unicode"> - * Unicode Standard Annex #15 — Unicode Normalization Forms</a>. + * Unicode Standard Annex #15: Unicode Normalization Forms</a>. * * Characters with accents or other adornments can be encoded in * several different ways in Unicode. For example, take the character A-acute. @@ -106,7 +112,7 @@ * unorm_normalize(UNORM_FCD) may be implemented with UNORM_NFD. * * For more details on FCD see the collation design document: - * http://oss.software.ibm.com/cvs/icu/~checkout~/icuhtml/design/collation/ICU_collation_design.htm + * http://source.icu-project.org/repos/icu/icuhtml/trunk/design/collation/ICU_collation_design.htm * * ICU collation performs either NFD or FCD normalization automatically if normalization * is turned on for the collator object. @@ -182,6 +188,7 @@ enum { * Normalize a string. * The string will be normalized according the specified normalization mode * and options. + * The source and result buffers must not be the same, nor overlap. * * @param source The string to normalize. * @param sourceLength The length of source, or -1 if NUL-terminated. @@ -201,28 +208,7 @@ unorm_normalize(const UChar *source, int32_t sourceLength, UNormalizationMode mode, int32_t options, UChar *result, int32_t resultLength, UErrorCode *status); -#endif -/** - * Result values for unorm_quickCheck(). - * For details see Unicode Technical Report 15. - * @stable ICU 2.0 - */ -typedef enum UNormalizationCheckResult { - /** - * Indicates that string is not in the normalized format - */ - UNORM_NO, - /** - * Indicates that string is in the normalized format - */ - UNORM_YES, - /** - * Indicates that string cannot be determined if it is in the normalized - * format without further thorough checks. - */ - UNORM_MAYBE -} UNormalizationCheckResult; -#if !UCONFIG_NO_NORMALIZATION + /** * Performing quick check on a string, to quickly determine if the string is * in a particular normalization format. @@ -451,7 +437,7 @@ unorm_previous(UCharIterator *src, * * @param left Left source string, may be same as dest. * @param leftLength Length of left source string, or -1 if NUL-terminated. - * @param right Right source string. + * @param right Right source string. Must not be the same as dest, nor overlap. * @param rightLength Length of right source string, or -1 if NUL-terminated. * @param dest The output buffer; can be NULL if destCapacity==0 for pure preflighting. * @param destCapacity The number of UChars that fit into dest. diff --git a/Source/WTF/icu/unicode/unorm2.h b/Source/WTF/icu/unicode/unorm2.h new file mode 100644 index 000000000..a522b4735 --- /dev/null +++ b/Source/WTF/icu/unicode/unorm2.h @@ -0,0 +1,391 @@ +/* +******************************************************************************* +* +* Copyright (C) 2009-2010, International Business Machines +* Corporation and others. All Rights Reserved. +* +******************************************************************************* +* file name: unorm2.h +* encoding: US-ASCII +* tab size: 8 (not used) +* indentation:4 +* +* created on: 2009dec15 +* created by: Markus W. Scherer +*/ + +#ifndef __UNORM2_H__ +#define __UNORM2_H__ + +/** + * \file + * \brief C API: New API for Unicode Normalization. + * + * Unicode normalization functionality for standard Unicode normalization or + * for using custom mapping tables. + * All instances of UNormalizer2 are unmodifiable/immutable. + * Instances returned by unorm2_getInstance() are singletons that must not be deleted by the caller. + * For more details see the Normalizer2 C++ class. + */ + +#include "unicode/utypes.h" +#include "unicode/localpointer.h" +#include "unicode/uset.h" + +/** + * Constants for normalization modes. + * For details about standard Unicode normalization forms + * and about the algorithms which are also used with custom mapping tables + * see http://www.unicode.org/unicode/reports/tr15/ + * @stable ICU 4.4 + */ +typedef enum { + /** + * Decomposition followed by composition. + * Same as standard NFC when using an "nfc" instance. + * Same as standard NFKC when using an "nfkc" instance. + * For details about standard Unicode normalization forms + * see http://www.unicode.org/unicode/reports/tr15/ + * @stable ICU 4.4 + */ + UNORM2_COMPOSE, + /** + * Map, and reorder canonically. + * Same as standard NFD when using an "nfc" instance. + * Same as standard NFKD when using an "nfkc" instance. + * For details about standard Unicode normalization forms + * see http://www.unicode.org/unicode/reports/tr15/ + * @stable ICU 4.4 + */ + UNORM2_DECOMPOSE, + /** + * "Fast C or D" form. + * If a string is in this form, then further decomposition <i>without reordering</i> + * would yield the same form as DECOMPOSE. + * Text in "Fast C or D" form can be processed efficiently with data tables + * that are "canonically closed", that is, that provide equivalent data for + * equivalent text, without having to be fully normalized. + * Not a standard Unicode normalization form. + * Not a unique form: Different FCD strings can be canonically equivalent. + * For details see http://www.unicode.org/notes/tn5/#FCD + * @stable ICU 4.4 + */ + UNORM2_FCD, + /** + * Compose only contiguously. + * Also known as "FCC" or "Fast C Contiguous". + * The result will often but not always be in NFC. + * The result will conform to FCD which is useful for processing. + * Not a standard Unicode normalization form. + * For details see http://www.unicode.org/notes/tn5/#FCC + * @stable ICU 4.4 + */ + UNORM2_COMPOSE_CONTIGUOUS +} UNormalization2Mode; + +/** + * Result values for normalization quick check functions. + * For details see http://www.unicode.org/reports/tr15/#Detecting_Normalization_Forms + * @stable ICU 2.0 + */ +typedef enum UNormalizationCheckResult { + /** + * The input string is not in the normalization form. + * @stable ICU 2.0 + */ + UNORM_NO, + /** + * The input string is in the normalization form. + * @stable ICU 2.0 + */ + UNORM_YES, + /** + * The input string may or may not be in the normalization form. + * This value is only returned for composition forms like NFC and FCC, + * when a backward-combining character is found for which the surrounding text + * would have to be analyzed further. + * @stable ICU 2.0 + */ + UNORM_MAYBE +} UNormalizationCheckResult; + +/** + * Opaque C service object type for the new normalization API. + * @stable ICU 4.4 + */ +struct UNormalizer2; +typedef struct UNormalizer2 UNormalizer2; /**< C typedef for struct UNormalizer2. @stable ICU 4.4 */ + +#if !UCONFIG_NO_NORMALIZATION + +/** + * Returns a UNormalizer2 instance which uses the specified data file + * (packageName/name similar to ucnv_openPackage() and ures_open()/ResourceBundle) + * and which composes or decomposes text according to the specified mode. + * Returns an unmodifiable singleton instance. Do not delete it. + * + * Use packageName=NULL for data files that are part of ICU's own data. + * Use name="nfc" and UNORM2_COMPOSE/UNORM2_DECOMPOSE for Unicode standard NFC/NFD. + * Use name="nfkc" and UNORM2_COMPOSE/UNORM2_DECOMPOSE for Unicode standard NFKC/NFKD. + * Use name="nfkc_cf" and UNORM2_COMPOSE for Unicode standard NFKC_CF=NFKC_Casefold. + * + * @param packageName NULL for ICU built-in data, otherwise application data package name + * @param name "nfc" or "nfkc" or "nfkc_cf" or name of custom data file + * @param mode normalization mode (compose or decompose etc.) + * @param pErrorCode Standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return the requested UNormalizer2, if successful + * @stable ICU 4.4 + */ +U_STABLE const UNormalizer2 * U_EXPORT2 +unorm2_getInstance(const char *packageName, + const char *name, + UNormalization2Mode mode, + UErrorCode *pErrorCode); + +/** + * Constructs a filtered normalizer wrapping any UNormalizer2 instance + * and a filter set. + * Both are aliased and must not be modified or deleted while this object + * is used. + * The filter set should be frozen; otherwise the performance will suffer greatly. + * @param norm2 wrapped UNormalizer2 instance + * @param filterSet USet which determines the characters to be normalized + * @param pErrorCode Standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return the requested UNormalizer2, if successful + * @stable ICU 4.4 + */ +U_STABLE UNormalizer2 * U_EXPORT2 +unorm2_openFiltered(const UNormalizer2 *norm2, const USet *filterSet, UErrorCode *pErrorCode); + +/** + * Closes a UNormalizer2 instance from unorm2_openFiltered(). + * Do not close instances from unorm2_getInstance()! + * @param norm2 UNormalizer2 instance to be closed + * @stable ICU 4.4 + */ +U_STABLE void U_EXPORT2 +unorm2_close(UNormalizer2 *norm2); + +#if U_SHOW_CPLUSPLUS_API + +U_NAMESPACE_BEGIN + +/** + * \class LocalUNormalizer2Pointer + * "Smart pointer" class, closes a UNormalizer2 via unorm2_close(). + * For most methods see the LocalPointerBase base class. + * + * @see LocalPointerBase + * @see LocalPointer + * @stable ICU 4.4 + */ +U_DEFINE_LOCAL_OPEN_POINTER(LocalUNormalizer2Pointer, UNormalizer2, unorm2_close); + +U_NAMESPACE_END + +#endif + +/** + * Writes the normalized form of the source string to the destination string + * (replacing its contents) and returns the length of the destination string. + * The source and destination strings must be different buffers. + * @param norm2 UNormalizer2 instance + * @param src source string + * @param length length of the source string, or -1 if NUL-terminated + * @param dest destination string; its contents is replaced with normalized src + * @param capacity number of UChars that can be written to dest + * @param pErrorCode Standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return dest + * @stable ICU 4.4 + */ +U_STABLE int32_t U_EXPORT2 +unorm2_normalize(const UNormalizer2 *norm2, + const UChar *src, int32_t length, + UChar *dest, int32_t capacity, + UErrorCode *pErrorCode); +/** + * Appends the normalized form of the second string to the first string + * (merging them at the boundary) and returns the length of the first string. + * The result is normalized if the first string was normalized. + * The first and second strings must be different buffers. + * @param norm2 UNormalizer2 instance + * @param first string, should be normalized + * @param firstLength length of the first string, or -1 if NUL-terminated + * @param firstCapacity number of UChars that can be written to first + * @param second string, will be normalized + * @param secondLength length of the source string, or -1 if NUL-terminated + * @param pErrorCode Standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return first + * @stable ICU 4.4 + */ +U_STABLE int32_t U_EXPORT2 +unorm2_normalizeSecondAndAppend(const UNormalizer2 *norm2, + UChar *first, int32_t firstLength, int32_t firstCapacity, + const UChar *second, int32_t secondLength, + UErrorCode *pErrorCode); +/** + * Appends the second string to the first string + * (merging them at the boundary) and returns the length of the first string. + * The result is normalized if both the strings were normalized. + * The first and second strings must be different buffers. + * @param norm2 UNormalizer2 instance + * @param first string, should be normalized + * @param firstLength length of the first string, or -1 if NUL-terminated + * @param firstCapacity number of UChars that can be written to first + * @param second string, should be normalized + * @param secondLength length of the source string, or -1 if NUL-terminated + * @param pErrorCode Standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return first + * @stable ICU 4.4 + */ +U_STABLE int32_t U_EXPORT2 +unorm2_append(const UNormalizer2 *norm2, + UChar *first, int32_t firstLength, int32_t firstCapacity, + const UChar *second, int32_t secondLength, + UErrorCode *pErrorCode); + +/** + * Gets the decomposition mapping of c. Equivalent to unorm2_normalize(string(c)) + * on a UNORM2_DECOMPOSE UNormalizer2 instance, but much faster. + * This function is independent of the mode of the UNormalizer2. + * @param norm2 UNormalizer2 instance + * @param c code point + * @param decomposition String buffer which will be set to c's + * decomposition mapping, if there is one. + * @param capacity number of UChars that can be written to decomposition + * @param pErrorCode Standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return the non-negative length of c's decomposition, if there is one; otherwise a negative value + * @draft ICU 4.6 + */ +U_DRAFT int32_t U_EXPORT2 +unorm2_getDecomposition(const UNormalizer2 *norm2, + UChar32 c, UChar *decomposition, int32_t capacity, + UErrorCode *pErrorCode); + +/** + * Tests if the string is normalized. + * Internally, in cases where the quickCheck() method would return "maybe" + * (which is only possible for the two COMPOSE modes) this method + * resolves to "yes" or "no" to provide a definitive result, + * at the cost of doing more work in those cases. + * @param norm2 UNormalizer2 instance + * @param s input string + * @param length length of the string, or -1 if NUL-terminated + * @param pErrorCode Standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return TRUE if s is normalized + * @stable ICU 4.4 + */ +U_STABLE UBool U_EXPORT2 +unorm2_isNormalized(const UNormalizer2 *norm2, + const UChar *s, int32_t length, + UErrorCode *pErrorCode); + +/** + * Tests if the string is normalized. + * For the two COMPOSE modes, the result could be "maybe" in cases that + * would take a little more work to resolve definitively. + * Use spanQuickCheckYes() and normalizeSecondAndAppend() for a faster + * combination of quick check + normalization, to avoid + * re-checking the "yes" prefix. + * @param norm2 UNormalizer2 instance + * @param s input string + * @param length length of the string, or -1 if NUL-terminated + * @param pErrorCode Standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return UNormalizationCheckResult + * @stable ICU 4.4 + */ +U_STABLE UNormalizationCheckResult U_EXPORT2 +unorm2_quickCheck(const UNormalizer2 *norm2, + const UChar *s, int32_t length, + UErrorCode *pErrorCode); + +/** + * Returns the end of the normalized substring of the input string. + * In other words, with <code>end=spanQuickCheckYes(s, ec);</code> + * the substring <code>UnicodeString(s, 0, end)</code> + * will pass the quick check with a "yes" result. + * + * The returned end index is usually one or more characters before the + * "no" or "maybe" character: The end index is at a normalization boundary. + * (See the class documentation for more about normalization boundaries.) + * + * When the goal is a normalized string and most input strings are expected + * to be normalized already, then call this method, + * and if it returns a prefix shorter than the input string, + * copy that prefix and use normalizeSecondAndAppend() for the remainder. + * @param norm2 UNormalizer2 instance + * @param s input string + * @param length length of the string, or -1 if NUL-terminated + * @param pErrorCode Standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return "yes" span end index + * @stable ICU 4.4 + */ +U_STABLE int32_t U_EXPORT2 +unorm2_spanQuickCheckYes(const UNormalizer2 *norm2, + const UChar *s, int32_t length, + UErrorCode *pErrorCode); + +/** + * Tests if the character always has a normalization boundary before it, + * regardless of context. + * For details see the Normalizer2 base class documentation. + * @param norm2 UNormalizer2 instance + * @param c character to test + * @return TRUE if c has a normalization boundary before it + * @stable ICU 4.4 + */ +U_STABLE UBool U_EXPORT2 +unorm2_hasBoundaryBefore(const UNormalizer2 *norm2, UChar32 c); + +/** + * Tests if the character always has a normalization boundary after it, + * regardless of context. + * For details see the Normalizer2 base class documentation. + * @param norm2 UNormalizer2 instance + * @param c character to test + * @return TRUE if c has a normalization boundary after it + * @stable ICU 4.4 + */ +U_STABLE UBool U_EXPORT2 +unorm2_hasBoundaryAfter(const UNormalizer2 *norm2, UChar32 c); + +/** + * Tests if the character is normalization-inert. + * For details see the Normalizer2 base class documentation. + * @param norm2 UNormalizer2 instance + * @param c character to test + * @return TRUE if c is normalization-inert + * @stable ICU 4.4 + */ +U_STABLE UBool U_EXPORT2 +unorm2_isInert(const UNormalizer2 *norm2, UChar32 c); + +#endif /* !UCONFIG_NO_NORMALIZATION */ +#endif /* __UNORM2_H__ */ diff --git a/Source/WTF/icu/unicode/uobject.h b/Source/WTF/icu/unicode/uobject.h new file mode 100644 index 000000000..27d4c84da --- /dev/null +++ b/Source/WTF/icu/unicode/uobject.h @@ -0,0 +1,352 @@ +/* +****************************************************************************** +* +* Copyright (C) 2002-2010, International Business Machines +* Corporation and others. All Rights Reserved. +* +****************************************************************************** +* file name: uobject.h +* encoding: US-ASCII +* tab size: 8 (not used) +* indentation:4 +* +* created on: 2002jun26 +* created by: Markus W. Scherer +*/ + +#ifndef __UOBJECT_H__ +#define __UOBJECT_H__ + +#include "unicode/utypes.h" + +U_NAMESPACE_BEGIN + +/** + * \file + * \brief C++ API: Common ICU base class UObject. + */ + +/** U_OVERRIDE_CXX_ALLOCATION - Define this to override operator new and + * delete in UMemory. Enabled by default for ICU. + * + * Enabling forces all allocation of ICU object types to use ICU's + * memory allocation. On Windows, this allows the ICU DLL to be used by + * applications that statically link the C Runtime library, meaning that + * the app and ICU will be using different heaps. + * + * @stable ICU 2.2 + */ +#ifndef U_OVERRIDE_CXX_ALLOCATION +#define U_OVERRIDE_CXX_ALLOCATION 1 +#endif + +/** + * \def U_HAVE_PLACEMENT_NEW + * Define this to define the placement new and + * delete in UMemory for STL. + * + * @stable ICU 2.6 + */ +#ifndef U_HAVE_PLACEMENT_NEW +#define U_HAVE_PLACEMENT_NEW 1 +#endif + + +/** + * \def U_HAVE_DEBUG_LOCATION_NEW + * Define this to define the MFC debug + * version of the operator new. + * + * @stable ICU 3.4 + */ +#ifndef U_HAVE_DEBUG_LOCATION_NEW +#define U_HAVE_DEBUG_LOCATION_NEW 0 +#endif + +/** + * @{ + * \def U_NO_THROW + * Define this to define the throw() specification so + * certain functions do not throw any exceptions + * + * UMemory operator new methods should have the throw() specification + * appended to them, so that the compiler adds the additional NULL check + * before calling constructors. Without, if <code>operator new</code> returns NULL the + * constructor is still called, and if the constructor references member + * data, (which it typically does), the result is a segmentation violation. + * + * @draft ICU 4.2 + */ +#ifndef U_NO_THROW +#define U_NO_THROW throw() +#endif + +/** @} */ + +/** + * UMemory is the common ICU base class. + * All other ICU C++ classes are derived from UMemory (starting with ICU 2.4). + * + * This is primarily to make it possible and simple to override the + * C++ memory management by adding new/delete operators to this base class. + * + * To override ALL ICU memory management, including that from plain C code, + * replace the allocation functions declared in cmemory.h + * + * UMemory does not contain any virtual functions. + * Common "boilerplate" functions are defined in UObject. + * + * @stable ICU 2.4 + */ +class U_COMMON_API UMemory { +public: + +/* test versions for debugging shaper heap memory problems */ +#ifdef SHAPER_MEMORY_DEBUG + static void * NewArray(int size, int count); + static void * GrowArray(void * array, int newSize ); + static void FreeArray(void * array ); +#endif + +#if U_OVERRIDE_CXX_ALLOCATION + /** + * Override for ICU4C C++ memory management. + * simple, non-class types are allocated using the macros in common/cmemory.h + * (uprv_malloc(), uprv_free(), uprv_realloc()); + * they or something else could be used here to implement C++ new/delete + * for ICU4C C++ classes + * @stable ICU 2.4 + */ + static void * U_EXPORT2 operator new(size_t size) U_NO_THROW; + + /** + * Override for ICU4C C++ memory management. + * See new(). + * @stable ICU 2.4 + */ + static void * U_EXPORT2 operator new[](size_t size) U_NO_THROW; + + /** + * Override for ICU4C C++ memory management. + * simple, non-class types are allocated using the macros in common/cmemory.h + * (uprv_malloc(), uprv_free(), uprv_realloc()); + * they or something else could be used here to implement C++ new/delete + * for ICU4C C++ classes + * @stable ICU 2.4 + */ + static void U_EXPORT2 operator delete(void *p) U_NO_THROW; + + /** + * Override for ICU4C C++ memory management. + * See delete(). + * @stable ICU 2.4 + */ + static void U_EXPORT2 operator delete[](void *p) U_NO_THROW; + +#if U_HAVE_PLACEMENT_NEW + /** + * Override for ICU4C C++ memory management for STL. + * See new(). + * @stable ICU 2.6 + */ + static inline void * U_EXPORT2 operator new(size_t, void *ptr) U_NO_THROW { return ptr; } + + /** + * Override for ICU4C C++ memory management for STL. + * See delete(). + * @stable ICU 2.6 + */ + static inline void U_EXPORT2 operator delete(void *, void *) U_NO_THROW {} +#endif /* U_HAVE_PLACEMENT_NEW */ +#if U_HAVE_DEBUG_LOCATION_NEW + /** + * This method overrides the MFC debug version of the operator new + * + * @param size The requested memory size + * @param file The file where the allocation was requested + * @param line The line where the allocation was requested + */ + static void * U_EXPORT2 operator new(size_t size, const char* file, int line) U_NO_THROW; + /** + * This method provides a matching delete for the MFC debug new + * + * @param p The pointer to the allocated memory + * @param file The file where the allocation was requested + * @param line The line where the allocation was requested + */ + static void U_EXPORT2 operator delete(void* p, const char* file, int line) U_NO_THROW; +#endif /* U_HAVE_DEBUG_LOCATION_NEW */ +#endif /* U_OVERRIDE_CXX_ALLOCATION */ + + /* + * Assignment operator not declared. The compiler will provide one + * which does nothing since this class does not contain any data members. + * API/code coverage may show the assignment operator as present and + * untested - ignore. + * Subclasses need this assignment operator if they use compiler-provided + * assignment operators of their own. An alternative to not declaring one + * here would be to declare and empty-implement a protected or public one. + UMemory &UMemory::operator=(const UMemory &); + */ +}; + +/** + * UObject is the common ICU "boilerplate" class. + * UObject inherits UMemory (starting with ICU 2.4), + * and all other public ICU C++ classes + * are derived from UObject (starting with ICU 2.2). + * + * UObject contains common virtual functions like for ICU's "poor man's RTTI". + * It does not contain default implementations of virtual methods + * like getDynamicClassID to allow derived classes such as Format + * to declare these as pure virtual. + * + * The clone() function is not available in UObject because it is not + * implemented by all ICU classes. + * Many ICU services provide a clone() function for their class trees, + * defined on the service's C++ base class, and all subclasses within that + * service class tree return a pointer to the service base class + * (which itself is a subclass of UObject). + * This is because some compilers do not support covariant (same-as-this) + * return types; cast to the appropriate subclass if necessary. + * + * @stable ICU 2.2 + */ +class U_COMMON_API UObject : public UMemory { +public: + /** + * Destructor. + * + * @stable ICU 2.2 + */ + virtual ~UObject(); + + /** + * ICU4C "poor man's RTTI", returns a UClassID for the actual ICU class. + * + * @stable ICU 2.2 + */ + virtual UClassID getDynamicClassID() const = 0; + +protected: + // the following functions are protected to prevent instantiation and + // direct use of UObject itself + + // default constructor + // commented out because UObject is abstract (see getDynamicClassID) + // inline UObject() {} + + // copy constructor + // commented out because UObject is abstract (see getDynamicClassID) + // inline UObject(const UObject &other) {} + +#if 0 + // TODO Sometime in the future. Implement operator==(). + // (This comment inserted in 2.2) + // some or all of the following "boilerplate" functions may be made public + // in a future ICU4C release when all subclasses implement them + + // assignment operator + // (not virtual, see "Taligent's Guide to Designing Programs" pp.73..74) + // commented out because the implementation is the same as a compiler's default + // UObject &operator=(const UObject &other) { return *this; } + + // comparison operators + virtual inline UBool operator==(const UObject &other) const { return this==&other; } + inline UBool operator!=(const UObject &other) const { return !operator==(other); } + + // clone() commented out from the base class: + // some compilers do not support co-variant return types + // (i.e., subclasses would have to return UObject * as well, instead of SubClass *) + // see also UObject class documentation. + // virtual UObject *clone() const; +#endif + + /* + * Assignment operator not declared. The compiler will provide one + * which does nothing since this class does not contain any data members. + * API/code coverage may show the assignment operator as present and + * untested - ignore. + * Subclasses need this assignment operator if they use compiler-provided + * assignment operators of their own. An alternative to not declaring one + * here would be to declare and empty-implement a protected or public one. + UObject &UObject::operator=(const UObject &); + */ + +// Future implementation for RTTI that support subtyping. [alan] +// +// public: +// /** +// * @internal +// */ +// static UClassID getStaticClassID(); +// +// /** +// * @internal +// */ +// UBool instanceOf(UClassID type) const; +}; + +/** + * This is a simple macro to add ICU RTTI to an ICU object implementation. + * This does not go into the header. This should only be used in *.cpp files. + * + * @param myClass The name of the class that needs RTTI defined. + * @internal + */ +#define UOBJECT_DEFINE_RTTI_IMPLEMENTATION(myClass) \ + UClassID U_EXPORT2 myClass::getStaticClassID() { \ + static char classID = 0; \ + return (UClassID)&classID; \ + } \ + UClassID myClass::getDynamicClassID() const \ + { return myClass::getStaticClassID(); } + + +/** + * This macro adds ICU RTTI to an ICU abstract class implementation. + * This macro should be invoked in *.cpp files. The corresponding + * header should declare getStaticClassID. + * + * @param myClass The name of the class that needs RTTI defined. + * @internal + */ +#define UOBJECT_DEFINE_ABSTRACT_RTTI_IMPLEMENTATION(myClass) \ + UClassID U_EXPORT2 myClass::getStaticClassID() { \ + static char classID = 0; \ + return (UClassID)&classID; \ + } + +/** + * This is a simple macro to express that a class and its subclasses do not offer + * ICU's "poor man's RTTI". + * Beginning with ICU 4.6, ICU requires C++ compiler RTTI. + * This does not go into the header. This should only be used in *.cpp files. + * Use this with a private getDynamicClassID() in an immediate subclass of UObject. + * + * @param myClass The name of the class that needs RTTI defined. + * @internal + */ +#define UOBJECT_DEFINE_NO_RTTI_IMPLEMENTATION(myClass) \ + UClassID myClass::getDynamicClassID() const { return NULL; } + +// /** +// * This macro adds ICU RTTI to an ICU concrete class implementation. +// * This macro should be invoked in *.cpp files. The corresponding +// * header should declare getDynamicClassID and getStaticClassID. +// * +// * @param myClass The name of the class that needs RTTI defined. +// * @param myParent The name of the myClass's parent. +// * @internal +// */ +/*#define UOBJECT_DEFINE_RTTI_IMPLEMENTATION(myClass, myParent) \ + UOBJECT_DEFINE_ABSTRACT_RTTI_IMPLEMENTATION(myClass, myParent) \ + UClassID myClass::getDynamicClassID() const { \ + return myClass::getStaticClassID(); \ + } +*/ + + +U_NAMESPACE_END + +#endif diff --git a/Source/WTF/icu/unicode/urename.h b/Source/WTF/icu/unicode/urename.h index 55625921f..468bdbd0f 100644 --- a/Source/WTF/icu/unicode/urename.h +++ b/Source/WTF/icu/unicode/urename.h @@ -1,6 +1,6 @@ /* ******************************************************************************* -* Copyright (C) 2002-2004, International Business Machines +* Copyright (C) 2002-2010, International Business Machines * Corporation and others. All Rights Reserved. ******************************************************************************* * @@ -27,1438 +27,2211 @@ #if !U_DISABLE_RENAMING +/* We need the U_ICU_ENTRY_POINT_RENAME definition. There's a default one in unicode/uvernum.h we can use, but we will give + the platform a chance to define it first. + Normally (if utypes.h or umachine.h was included first) this will not be necessary as it will already be defined. + */ +#ifndef U_ICU_ENTRY_POINT_RENAME +#include "unicode/umachine.h" +#endif + +/* If we still don't have U_ICU_ENTRY_POINT_RENAME use the default. */ +#ifndef U_ICU_ENTRY_POINT_RENAME +#include "unicode/uvernum.h" +#endif + +/* Error out before the following defines cause very strange and unexpected code breakage */ +#ifndef U_ICU_ENTRY_POINT_RENAME +#error U_ICU_ENTRY_POINT_RENAME is not defined - cannot continue. Consider defining U_DISABLE_RENAMING if renaming should not be used. +#endif + + /* C exports renaming data */ -#define T_CString_int64ToString T_CString_int64ToString_3_2 -#define T_CString_integerToString T_CString_integerToString_3_2 -#define T_CString_stricmp T_CString_stricmp_3_2 -#define T_CString_stringToInteger T_CString_stringToInteger_3_2 -#define T_CString_strnicmp T_CString_strnicmp_3_2 -#define T_CString_toLowerCase T_CString_toLowerCase_3_2 -#define T_CString_toUpperCase T_CString_toUpperCase_3_2 -#define T_FileStream_close T_FileStream_close_3_2 -#define T_FileStream_eof T_FileStream_eof_3_2 -#define T_FileStream_error T_FileStream_error_3_2 -#define T_FileStream_file_exists T_FileStream_file_exists_3_2 -#define T_FileStream_getc T_FileStream_getc_3_2 -#define T_FileStream_open T_FileStream_open_3_2 -#define T_FileStream_peek T_FileStream_peek_3_2 -#define T_FileStream_putc T_FileStream_putc_3_2 -#define T_FileStream_read T_FileStream_read_3_2 -#define T_FileStream_readLine T_FileStream_readLine_3_2 -#define T_FileStream_remove T_FileStream_remove_3_2 -#define T_FileStream_rewind T_FileStream_rewind_3_2 -#define T_FileStream_size T_FileStream_size_3_2 -#define T_FileStream_stderr T_FileStream_stderr_3_2 -#define T_FileStream_stdin T_FileStream_stdin_3_2 -#define T_FileStream_stdout T_FileStream_stdout_3_2 -#define T_FileStream_ungetc T_FileStream_ungetc_3_2 -#define T_FileStream_write T_FileStream_write_3_2 -#define T_FileStream_writeLine T_FileStream_writeLine_3_2 -#define UCNV_FROM_U_CALLBACK_ESCAPE UCNV_FROM_U_CALLBACK_ESCAPE_3_2 -#define UCNV_FROM_U_CALLBACK_SKIP UCNV_FROM_U_CALLBACK_SKIP_3_2 -#define UCNV_FROM_U_CALLBACK_STOP UCNV_FROM_U_CALLBACK_STOP_3_2 -#define UCNV_FROM_U_CALLBACK_SUBSTITUTE UCNV_FROM_U_CALLBACK_SUBSTITUTE_3_2 -#define UCNV_TO_U_CALLBACK_ESCAPE UCNV_TO_U_CALLBACK_ESCAPE_3_2 -#define UCNV_TO_U_CALLBACK_SKIP UCNV_TO_U_CALLBACK_SKIP_3_2 -#define UCNV_TO_U_CALLBACK_STOP UCNV_TO_U_CALLBACK_STOP_3_2 -#define UCNV_TO_U_CALLBACK_SUBSTITUTE UCNV_TO_U_CALLBACK_SUBSTITUTE_3_2 -#define UDataMemory_createNewInstance UDataMemory_createNewInstance_3_2 -#define UDataMemory_init UDataMemory_init_3_2 -#define UDataMemory_isLoaded UDataMemory_isLoaded_3_2 -#define UDataMemory_normalizeDataPointer UDataMemory_normalizeDataPointer_3_2 -#define UDataMemory_setData UDataMemory_setData_3_2 -#define UDatamemory_assign UDatamemory_assign_3_2 -#define _ASCIIData _ASCIIData_3_2 -#define _Bocu1Data _Bocu1Data_3_2 -#define _CESU8Data _CESU8Data_3_2 -#define _HZData _HZData_3_2 -#define _IMAPData _IMAPData_3_2 -#define _ISCIIData _ISCIIData_3_2 -#define _ISO2022Data _ISO2022Data_3_2 -#define _LMBCSData1 _LMBCSData1_3_2 -#define _LMBCSData11 _LMBCSData11_3_2 -#define _LMBCSData16 _LMBCSData16_3_2 -#define _LMBCSData17 _LMBCSData17_3_2 -#define _LMBCSData18 _LMBCSData18_3_2 -#define _LMBCSData19 _LMBCSData19_3_2 -#define _LMBCSData2 _LMBCSData2_3_2 -#define _LMBCSData3 _LMBCSData3_3_2 -#define _LMBCSData4 _LMBCSData4_3_2 -#define _LMBCSData5 _LMBCSData5_3_2 -#define _LMBCSData6 _LMBCSData6_3_2 -#define _LMBCSData8 _LMBCSData8_3_2 -#define _Latin1Data _Latin1Data_3_2 -#define _MBCSData _MBCSData_3_2 -#define _SCSUData _SCSUData_3_2 -#define _UTF16BEData _UTF16BEData_3_2 -#define _UTF16Data _UTF16Data_3_2 -#define _UTF16LEData _UTF16LEData_3_2 -#define _UTF32BEData _UTF32BEData_3_2 -#define _UTF32Data _UTF32Data_3_2 -#define _UTF32LEData _UTF32LEData_3_2 -#define _UTF7Data _UTF7Data_3_2 -#define _UTF8Data _UTF8Data_3_2 -#define cmemory_cleanup cmemory_cleanup_3_2 -#define cmemory_inUse cmemory_inUse_3_2 -#define locale_getKeywords locale_getKeywords_3_2 -#define locale_get_default locale_get_default_3_2 -#define locale_set_default locale_set_default_3_2 -#define res_countArrayItems res_countArrayItems_3_2 -#define res_findResource res_findResource_3_2 -#define res_getAlias res_getAlias_3_2 -#define res_getArrayItem res_getArrayItem_3_2 -#define res_getBinary res_getBinary_3_2 -#define res_getIntVector res_getIntVector_3_2 -#define res_getResource res_getResource_3_2 -#define res_getString res_getString_3_2 -#define res_getTableItemByIndex res_getTableItemByIndex_3_2 -#define res_getTableItemByKey res_getTableItemByKey_3_2 -#define res_load res_load_3_2 -#define res_unload res_unload_3_2 -#define transliterator_cleanup transliterator_cleanup_3_2 -#define u_UCharsToChars u_UCharsToChars_3_2 -#define u_austrcpy u_austrcpy_3_2 -#define u_austrncpy u_austrncpy_3_2 -#define u_catclose u_catclose_3_2 -#define u_catgets u_catgets_3_2 -#define u_catopen u_catopen_3_2 -#define u_charAge u_charAge_3_2 -#define u_charDigitValue u_charDigitValue_3_2 -#define u_charDirection u_charDirection_3_2 -#define u_charFromName u_charFromName_3_2 -#define u_charMirror u_charMirror_3_2 -#define u_charName u_charName_3_2 -#define u_charType u_charType_3_2 -#define u_charsToUChars u_charsToUChars_3_2 -#define u_cleanup u_cleanup_3_2 -#define u_countChar32 u_countChar32_3_2 -#define u_digit u_digit_3_2 -#define u_enumCharNames u_enumCharNames_3_2 -#define u_enumCharTypes u_enumCharTypes_3_2 -#define u_errorName u_errorName_3_2 -#define u_fclose u_fclose_3_2 -#define u_feof u_feof_3_2 -#define u_fflush u_fflush_3_2 -#define u_fgetConverter u_fgetConverter_3_2 -#define u_fgetc u_fgetc_3_2 -#define u_fgetcodepage u_fgetcodepage_3_2 -#define u_fgetcx u_fgetcx_3_2 -#define u_fgetfile u_fgetfile_3_2 -#define u_fgetlocale u_fgetlocale_3_2 -#define u_fgets u_fgets_3_2 -#define u_file_read u_file_read_3_2 -#define u_file_write u_file_write_3_2 -#define u_file_write_flush u_file_write_flush_3_2 -#define u_finit u_finit_3_2 -#define u_foldCase u_foldCase_3_2 -#define u_fopen u_fopen_3_2 -#define u_forDigit u_forDigit_3_2 -#define u_formatMessage u_formatMessage_3_2 -#define u_formatMessageWithError u_formatMessageWithError_3_2 -#define u_fprintf u_fprintf_3_2 -#define u_fprintf_u u_fprintf_u_3_2 -#define u_fputc u_fputc_3_2 -#define u_fputs u_fputs_3_2 -#define u_frewind u_frewind_3_2 -#define u_fscanf u_fscanf_3_2 -#define u_fscanf_u u_fscanf_u_3_2 -#define u_fsetcodepage u_fsetcodepage_3_2 -#define u_fsetlocale u_fsetlocale_3_2 -#define u_fsettransliterator u_fsettransliterator_3_2 -#define u_fstropen u_fstropen_3_2 -#define u_fungetc u_fungetc_3_2 -#define u_getCombiningClass u_getCombiningClass_3_2 -#define u_getDataDirectory u_getDataDirectory_3_2 -#define u_getDefaultConverter u_getDefaultConverter_3_2 -#define u_getFC_NFKC_Closure u_getFC_NFKC_Closure_3_2 -#define u_getISOComment u_getISOComment_3_2 -#define u_getIntPropertyMaxValue u_getIntPropertyMaxValue_3_2 -#define u_getIntPropertyMinValue u_getIntPropertyMinValue_3_2 -#define u_getIntPropertyValue u_getIntPropertyValue_3_2 -#define u_getNumericValue u_getNumericValue_3_2 -#define u_getPropertyEnum u_getPropertyEnum_3_2 -#define u_getPropertyName u_getPropertyName_3_2 -#define u_getPropertyValueEnum u_getPropertyValueEnum_3_2 -#define u_getPropertyValueName u_getPropertyValueName_3_2 -#define u_getUnicodeProperties u_getUnicodeProperties_3_2 -#define u_getUnicodeVersion u_getUnicodeVersion_3_2 -#define u_getVersion u_getVersion_3_2 -#define u_growBufferFromStatic u_growBufferFromStatic_3_2 -#define u_hasBinaryProperty u_hasBinaryProperty_3_2 -#define u_init u_init_3_2 -#define u_isIDIgnorable u_isIDIgnorable_3_2 -#define u_isIDPart u_isIDPart_3_2 -#define u_isIDStart u_isIDStart_3_2 -#define u_isISOControl u_isISOControl_3_2 -#define u_isJavaIDPart u_isJavaIDPart_3_2 -#define u_isJavaIDStart u_isJavaIDStart_3_2 -#define u_isJavaSpaceChar u_isJavaSpaceChar_3_2 -#define u_isMirrored u_isMirrored_3_2 -#define u_isUAlphabetic u_isUAlphabetic_3_2 -#define u_isULowercase u_isULowercase_3_2 -#define u_isUUppercase u_isUUppercase_3_2 -#define u_isUWhiteSpace u_isUWhiteSpace_3_2 -#define u_isWhitespace u_isWhitespace_3_2 -#define u_isalnum u_isalnum_3_2 -#define u_isalpha u_isalpha_3_2 -#define u_isbase u_isbase_3_2 -#define u_isblank u_isblank_3_2 -#define u_iscntrl u_iscntrl_3_2 -#define u_isdefined u_isdefined_3_2 -#define u_isdigit u_isdigit_3_2 -#define u_isgraph u_isgraph_3_2 -#define u_islower u_islower_3_2 -#define u_isprint u_isprint_3_2 -#define u_ispunct u_ispunct_3_2 -#define u_isspace u_isspace_3_2 -#define u_istitle u_istitle_3_2 -#define u_isupper u_isupper_3_2 -#define u_isxdigit u_isxdigit_3_2 -#define u_lengthOfIdenticalLevelRun u_lengthOfIdenticalLevelRun_3_2 -#define u_locbund_close u_locbund_close_3_2 -#define u_locbund_getNumberFormat u_locbund_getNumberFormat_3_2 -#define u_locbund_init u_locbund_init_3_2 -#define u_memcasecmp u_memcasecmp_3_2 -#define u_memchr u_memchr_3_2 -#define u_memchr32 u_memchr32_3_2 -#define u_memcmp u_memcmp_3_2 -#define u_memcmpCodePointOrder u_memcmpCodePointOrder_3_2 -#define u_memcpy u_memcpy_3_2 -#define u_memmove u_memmove_3_2 -#define u_memrchr u_memrchr_3_2 -#define u_memrchr32 u_memrchr32_3_2 -#define u_memset u_memset_3_2 -#define u_parseMessage u_parseMessage_3_2 -#define u_parseMessageWithError u_parseMessageWithError_3_2 -#define u_printf_parse u_printf_parse_3_2 -#define u_releaseDefaultConverter u_releaseDefaultConverter_3_2 -#define u_scanf_parse u_scanf_parse_3_2 -#define u_setAtomicIncDecFunctions u_setAtomicIncDecFunctions_3_2 -#define u_setDataDirectory u_setDataDirectory_3_2 -#define u_setMemoryFunctions u_setMemoryFunctions_3_2 -#define u_setMutexFunctions u_setMutexFunctions_3_2 -#define u_shapeArabic u_shapeArabic_3_2 -#define u_snprintf u_snprintf_3_2 -#define u_snprintf_u u_snprintf_u_3_2 -#define u_sprintf u_sprintf_3_2 -#define u_sprintf_u u_sprintf_u_3_2 -#define u_sscanf u_sscanf_3_2 -#define u_sscanf_u u_sscanf_u_3_2 -#define u_strCaseCompare u_strCaseCompare_3_2 -#define u_strCompare u_strCompare_3_2 -#define u_strCompareIter u_strCompareIter_3_2 -#define u_strFindFirst u_strFindFirst_3_2 -#define u_strFindLast u_strFindLast_3_2 -#define u_strFoldCase u_strFoldCase_3_2 -#define u_strFromPunycode u_strFromPunycode_3_2 -#define u_strFromUTF32 u_strFromUTF32_3_2 -#define u_strFromUTF8 u_strFromUTF8_3_2 -#define u_strFromWCS u_strFromWCS_3_2 -#define u_strHasMoreChar32Than u_strHasMoreChar32Than_3_2 -#define u_strToLower u_strToLower_3_2 -#define u_strToPunycode u_strToPunycode_3_2 -#define u_strToTitle u_strToTitle_3_2 -#define u_strToUTF32 u_strToUTF32_3_2 -#define u_strToUTF8 u_strToUTF8_3_2 -#define u_strToUpper u_strToUpper_3_2 -#define u_strToWCS u_strToWCS_3_2 -#define u_strcasecmp u_strcasecmp_3_2 -#define u_strcat u_strcat_3_2 -#define u_strchr u_strchr_3_2 -#define u_strchr32 u_strchr32_3_2 -#define u_strcmp u_strcmp_3_2 -#define u_strcmpCodePointOrder u_strcmpCodePointOrder_3_2 -#define u_strcmpFold u_strcmpFold_3_2 -#define u_strcpy u_strcpy_3_2 -#define u_strcspn u_strcspn_3_2 -#define u_strlen u_strlen_3_2 -#define u_strncasecmp u_strncasecmp_3_2 -#define u_strncat u_strncat_3_2 -#define u_strncmp u_strncmp_3_2 -#define u_strncmpCodePointOrder u_strncmpCodePointOrder_3_2 -#define u_strncpy u_strncpy_3_2 -#define u_strpbrk u_strpbrk_3_2 -#define u_strrchr u_strrchr_3_2 -#define u_strrchr32 u_strrchr32_3_2 -#define u_strrstr u_strrstr_3_2 -#define u_strspn u_strspn_3_2 -#define u_strstr u_strstr_3_2 -#define u_strtok_r u_strtok_r_3_2 -#define u_terminateChars u_terminateChars_3_2 -#define u_terminateUChar32s u_terminateUChar32s_3_2 -#define u_terminateUChars u_terminateUChars_3_2 -#define u_terminateWChars u_terminateWChars_3_2 -#define u_tolower u_tolower_3_2 -#define u_totitle u_totitle_3_2 -#define u_toupper u_toupper_3_2 -#define u_uastrcpy u_uastrcpy_3_2 -#define u_uastrncpy u_uastrncpy_3_2 -#define u_unescape u_unescape_3_2 -#define u_unescapeAt u_unescapeAt_3_2 -#define u_versionFromString u_versionFromString_3_2 -#define u_versionToString u_versionToString_3_2 -#define u_vformatMessage u_vformatMessage_3_2 -#define u_vformatMessageWithError u_vformatMessageWithError_3_2 -#define u_vfprintf u_vfprintf_3_2 -#define u_vfprintf_u u_vfprintf_u_3_2 -#define u_vfscanf u_vfscanf_3_2 -#define u_vfscanf_u u_vfscanf_u_3_2 -#define u_vparseMessage u_vparseMessage_3_2 -#define u_vparseMessageWithError u_vparseMessageWithError_3_2 -#define u_vsnprintf u_vsnprintf_3_2 -#define u_vsnprintf_u u_vsnprintf_u_3_2 -#define u_vsprintf u_vsprintf_3_2 -#define u_vsprintf_u u_vsprintf_u_3_2 -#define u_vsscanf u_vsscanf_3_2 -#define u_vsscanf_u u_vsscanf_u_3_2 -#define u_writeDiff u_writeDiff_3_2 -#define u_writeIdenticalLevelRun u_writeIdenticalLevelRun_3_2 -#define u_writeIdenticalLevelRunTwoChars u_writeIdenticalLevelRunTwoChars_3_2 -#define ubidi_close ubidi_close_3_2 -#define ubidi_countRuns ubidi_countRuns_3_2 -#define ubidi_getDirection ubidi_getDirection_3_2 -#define ubidi_getLength ubidi_getLength_3_2 -#define ubidi_getLevelAt ubidi_getLevelAt_3_2 -#define ubidi_getLevels ubidi_getLevels_3_2 -#define ubidi_getLogicalIndex ubidi_getLogicalIndex_3_2 -#define ubidi_getLogicalMap ubidi_getLogicalMap_3_2 -#define ubidi_getLogicalRun ubidi_getLogicalRun_3_2 -#define ubidi_getMemory ubidi_getMemory_3_2 -#define ubidi_getParaLevel ubidi_getParaLevel_3_2 -#define ubidi_getRuns ubidi_getRuns_3_2 -#define ubidi_getText ubidi_getText_3_2 -#define ubidi_getVisualIndex ubidi_getVisualIndex_3_2 -#define ubidi_getVisualMap ubidi_getVisualMap_3_2 -#define ubidi_getVisualRun ubidi_getVisualRun_3_2 -#define ubidi_invertMap ubidi_invertMap_3_2 -#define ubidi_isInverse ubidi_isInverse_3_2 -#define ubidi_open ubidi_open_3_2 -#define ubidi_openSized ubidi_openSized_3_2 -#define ubidi_reorderLogical ubidi_reorderLogical_3_2 -#define ubidi_reorderVisual ubidi_reorderVisual_3_2 -#define ubidi_setInverse ubidi_setInverse_3_2 -#define ubidi_setLine ubidi_setLine_3_2 -#define ubidi_setPara ubidi_setPara_3_2 -#define ubidi_writeReordered ubidi_writeReordered_3_2 -#define ubidi_writeReverse ubidi_writeReverse_3_2 -#define ublock_getCode ublock_getCode_3_2 -#define ubrk_close ubrk_close_3_2 -#define ubrk_countAvailable ubrk_countAvailable_3_2 -#define ubrk_current ubrk_current_3_2 -#define ubrk_first ubrk_first_3_2 -#define ubrk_following ubrk_following_3_2 -#define ubrk_getAvailable ubrk_getAvailable_3_2 -#define ubrk_getLocaleByType ubrk_getLocaleByType_3_2 -#define ubrk_getRuleStatus ubrk_getRuleStatus_3_2 -#define ubrk_getRuleStatusVec ubrk_getRuleStatusVec_3_2 -#define ubrk_isBoundary ubrk_isBoundary_3_2 -#define ubrk_last ubrk_last_3_2 -#define ubrk_next ubrk_next_3_2 -#define ubrk_open ubrk_open_3_2 -#define ubrk_openRules ubrk_openRules_3_2 -#define ubrk_preceding ubrk_preceding_3_2 -#define ubrk_previous ubrk_previous_3_2 -#define ubrk_safeClone ubrk_safeClone_3_2 -#define ubrk_setText ubrk_setText_3_2 -#define ubrk_swap ubrk_swap_3_2 -#define ucal_add ucal_add_3_2 -#define ucal_clear ucal_clear_3_2 -#define ucal_clearField ucal_clearField_3_2 -#define ucal_close ucal_close_3_2 -#define ucal_countAvailable ucal_countAvailable_3_2 -#define ucal_equivalentTo ucal_equivalentTo_3_2 -#define ucal_get ucal_get_3_2 -#define ucal_getAttribute ucal_getAttribute_3_2 -#define ucal_getAvailable ucal_getAvailable_3_2 -#define ucal_getDSTSavings ucal_getDSTSavings_3_2 -#define ucal_getDefaultTimeZone ucal_getDefaultTimeZone_3_2 -#define ucal_getLimit ucal_getLimit_3_2 -#define ucal_getLocaleByType ucal_getLocaleByType_3_2 -#define ucal_getMillis ucal_getMillis_3_2 -#define ucal_getNow ucal_getNow_3_2 -#define ucal_getTimeZoneDisplayName ucal_getTimeZoneDisplayName_3_2 -#define ucal_inDaylightTime ucal_inDaylightTime_3_2 -#define ucal_isSet ucal_isSet_3_2 -#define ucal_open ucal_open_3_2 -#define ucal_openCountryTimeZones ucal_openCountryTimeZones_3_2 -#define ucal_openTimeZones ucal_openTimeZones_3_2 -#define ucal_roll ucal_roll_3_2 -#define ucal_set ucal_set_3_2 -#define ucal_setAttribute ucal_setAttribute_3_2 -#define ucal_setDate ucal_setDate_3_2 -#define ucal_setDateTime ucal_setDateTime_3_2 -#define ucal_setDefaultTimeZone ucal_setDefaultTimeZone_3_2 -#define ucal_setMillis ucal_setMillis_3_2 -#define ucal_setTimeZone ucal_setTimeZone_3_2 -#define ucase_addPropertyStarts ucase_addPropertyStarts_3_2 -#define ucase_close ucase_close_3_2 -#define ucase_fold ucase_fold_3_2 -#define ucase_getSingleton ucase_getSingleton_3_2 -#define ucase_getType ucase_getType_3_2 -#define ucase_getTypeOrIgnorable ucase_getTypeOrIgnorable_3_2 -#define ucase_isCaseSensitive ucase_isCaseSensitive_3_2 -#define ucase_isSoftDotted ucase_isSoftDotted_3_2 -#define ucase_open ucase_open_3_2 -#define ucase_openBinary ucase_openBinary_3_2 -#define ucase_swap ucase_swap_3_2 -#define ucase_toFullFolding ucase_toFullFolding_3_2 -#define ucase_toFullLower ucase_toFullLower_3_2 -#define ucase_toFullTitle ucase_toFullTitle_3_2 -#define ucase_toFullUpper ucase_toFullUpper_3_2 -#define ucase_tolower ucase_tolower_3_2 -#define ucase_totitle ucase_totitle_3_2 -#define ucase_toupper ucase_toupper_3_2 -#define uchar_addPropertyStarts uchar_addPropertyStarts_3_2 -#define uchar_getHST uchar_getHST_3_2 -#define uchar_swapNames uchar_swapNames_3_2 -#define ucln_common_lib_cleanup ucln_common_lib_cleanup_3_2 -#define ucln_common_registerCleanup ucln_common_registerCleanup_3_2 -#define ucln_i18n_registerCleanup ucln_i18n_registerCleanup_3_2 -#define ucln_registerCleanup ucln_registerCleanup_3_2 -#define ucmp8_close ucmp8_close_3_2 -#define ucmp8_compact ucmp8_compact_3_2 -#define ucmp8_expand ucmp8_expand_3_2 -#define ucmp8_flattenMem ucmp8_flattenMem_3_2 -#define ucmp8_getArray ucmp8_getArray_3_2 -#define ucmp8_getCount ucmp8_getCount_3_2 -#define ucmp8_getIndex ucmp8_getIndex_3_2 -#define ucmp8_getkBlockCount ucmp8_getkBlockCount_3_2 -#define ucmp8_getkUnicodeCount ucmp8_getkUnicodeCount_3_2 -#define ucmp8_init ucmp8_init_3_2 -#define ucmp8_initAdopt ucmp8_initAdopt_3_2 -#define ucmp8_initAlias ucmp8_initAlias_3_2 -#define ucmp8_initBogus ucmp8_initBogus_3_2 -#define ucmp8_initFromData ucmp8_initFromData_3_2 -#define ucmp8_isBogus ucmp8_isBogus_3_2 -#define ucmp8_open ucmp8_open_3_2 -#define ucmp8_openAdopt ucmp8_openAdopt_3_2 -#define ucmp8_openAlias ucmp8_openAlias_3_2 -#define ucmp8_set ucmp8_set_3_2 -#define ucmp8_setRange ucmp8_setRange_3_2 -#define ucnv_MBCSFromUChar32 ucnv_MBCSFromUChar32_3_2 -#define ucnv_MBCSFromUnicodeWithOffsets ucnv_MBCSFromUnicodeWithOffsets_3_2 -#define ucnv_MBCSGetType ucnv_MBCSGetType_3_2 -#define ucnv_MBCSGetUnicodeSetForBytes ucnv_MBCSGetUnicodeSetForBytes_3_2 -#define ucnv_MBCSGetUnicodeSetForUnicode ucnv_MBCSGetUnicodeSetForUnicode_3_2 -#define ucnv_MBCSIsLeadByte ucnv_MBCSIsLeadByte_3_2 -#define ucnv_MBCSSimpleGetNextUChar ucnv_MBCSSimpleGetNextUChar_3_2 -#define ucnv_MBCSToUnicodeWithOffsets ucnv_MBCSToUnicodeWithOffsets_3_2 -#define ucnv_cbFromUWriteBytes ucnv_cbFromUWriteBytes_3_2 -#define ucnv_cbFromUWriteSub ucnv_cbFromUWriteSub_3_2 -#define ucnv_cbFromUWriteUChars ucnv_cbFromUWriteUChars_3_2 -#define ucnv_cbToUWriteSub ucnv_cbToUWriteSub_3_2 -#define ucnv_cbToUWriteUChars ucnv_cbToUWriteUChars_3_2 -#define ucnv_close ucnv_close_3_2 -#define ucnv_compareNames ucnv_compareNames_3_2 -#define ucnv_convert ucnv_convert_3_2 -#define ucnv_convertEx ucnv_convertEx_3_2 -#define ucnv_copyPlatformString ucnv_copyPlatformString_3_2 -#define ucnv_countAliases ucnv_countAliases_3_2 -#define ucnv_countAvailable ucnv_countAvailable_3_2 -#define ucnv_countStandards ucnv_countStandards_3_2 -#define ucnv_createAlgorithmicConverter ucnv_createAlgorithmicConverter_3_2 -#define ucnv_createConverter ucnv_createConverter_3_2 -#define ucnv_createConverterFromPackage ucnv_createConverterFromPackage_3_2 -#define ucnv_createConverterFromSharedData ucnv_createConverterFromSharedData_3_2 -#define ucnv_detectUnicodeSignature ucnv_detectUnicodeSignature_3_2 -#define ucnv_extContinueMatchFromU ucnv_extContinueMatchFromU_3_2 -#define ucnv_extContinueMatchToU ucnv_extContinueMatchToU_3_2 -#define ucnv_extGetUnicodeSet ucnv_extGetUnicodeSet_3_2 -#define ucnv_extInitialMatchFromU ucnv_extInitialMatchFromU_3_2 -#define ucnv_extInitialMatchToU ucnv_extInitialMatchToU_3_2 -#define ucnv_extSimpleMatchFromU ucnv_extSimpleMatchFromU_3_2 -#define ucnv_extSimpleMatchToU ucnv_extSimpleMatchToU_3_2 -#define ucnv_fixFileSeparator ucnv_fixFileSeparator_3_2 -#define ucnv_flushCache ucnv_flushCache_3_2 -#define ucnv_fromAlgorithmic ucnv_fromAlgorithmic_3_2 -#define ucnv_fromUChars ucnv_fromUChars_3_2 -#define ucnv_fromUWriteBytes ucnv_fromUWriteBytes_3_2 -#define ucnv_fromUnicode ucnv_fromUnicode_3_2 -#define ucnv_fromUnicode_UTF8 ucnv_fromUnicode_UTF8_3_2 -#define ucnv_fromUnicode_UTF8_OFFSETS_LOGIC ucnv_fromUnicode_UTF8_OFFSETS_LOGIC_3_2 -#define ucnv_getAlias ucnv_getAlias_3_2 -#define ucnv_getAliases ucnv_getAliases_3_2 -#define ucnv_getAvailableName ucnv_getAvailableName_3_2 -#define ucnv_getCCSID ucnv_getCCSID_3_2 -#define ucnv_getCanonicalName ucnv_getCanonicalName_3_2 -#define ucnv_getCompleteUnicodeSet ucnv_getCompleteUnicodeSet_3_2 -#define ucnv_getDefaultName ucnv_getDefaultName_3_2 -#define ucnv_getDisplayName ucnv_getDisplayName_3_2 -#define ucnv_getFromUCallBack ucnv_getFromUCallBack_3_2 -#define ucnv_getInvalidChars ucnv_getInvalidChars_3_2 -#define ucnv_getInvalidUChars ucnv_getInvalidUChars_3_2 -#define ucnv_getMaxCharSize ucnv_getMaxCharSize_3_2 -#define ucnv_getMinCharSize ucnv_getMinCharSize_3_2 -#define ucnv_getName ucnv_getName_3_2 -#define ucnv_getNextUChar ucnv_getNextUChar_3_2 -#define ucnv_getNonSurrogateUnicodeSet ucnv_getNonSurrogateUnicodeSet_3_2 -#define ucnv_getPlatform ucnv_getPlatform_3_2 -#define ucnv_getStandard ucnv_getStandard_3_2 -#define ucnv_getStandardName ucnv_getStandardName_3_2 -#define ucnv_getStarters ucnv_getStarters_3_2 -#define ucnv_getSubstChars ucnv_getSubstChars_3_2 -#define ucnv_getToUCallBack ucnv_getToUCallBack_3_2 -#define ucnv_getType ucnv_getType_3_2 -#define ucnv_getUnicodeSet ucnv_getUnicodeSet_3_2 -#define ucnv_incrementRefCount ucnv_incrementRefCount_3_2 -#define ucnv_io_countAliases ucnv_io_countAliases_3_2 -#define ucnv_io_countAvailableAliases ucnv_io_countAvailableAliases_3_2 -#define ucnv_io_countAvailableConverters ucnv_io_countAvailableConverters_3_2 -#define ucnv_io_countStandards ucnv_io_countStandards_3_2 -#define ucnv_io_flushAvailableConverterCache ucnv_io_flushAvailableConverterCache_3_2 -#define ucnv_io_getAlias ucnv_io_getAlias_3_2 -#define ucnv_io_getAliases ucnv_io_getAliases_3_2 -#define ucnv_io_getAvailableConverter ucnv_io_getAvailableConverter_3_2 -#define ucnv_io_getConverterName ucnv_io_getConverterName_3_2 -#define ucnv_io_getDefaultConverterName ucnv_io_getDefaultConverterName_3_2 -#define ucnv_io_setDefaultConverterName ucnv_io_setDefaultConverterName_3_2 -#define ucnv_io_stripASCIIForCompare ucnv_io_stripASCIIForCompare_3_2 -#define ucnv_io_stripEBCDICForCompare ucnv_io_stripEBCDICForCompare_3_2 -#define ucnv_isAmbiguous ucnv_isAmbiguous_3_2 -#define ucnv_load ucnv_load_3_2 -#define ucnv_loadSharedData ucnv_loadSharedData_3_2 -#define ucnv_open ucnv_open_3_2 -#define ucnv_openAllNames ucnv_openAllNames_3_2 -#define ucnv_openCCSID ucnv_openCCSID_3_2 -#define ucnv_openPackage ucnv_openPackage_3_2 -#define ucnv_openStandardNames ucnv_openStandardNames_3_2 -#define ucnv_openU ucnv_openU_3_2 -#define ucnv_reset ucnv_reset_3_2 -#define ucnv_resetFromUnicode ucnv_resetFromUnicode_3_2 -#define ucnv_resetToUnicode ucnv_resetToUnicode_3_2 -#define ucnv_safeClone ucnv_safeClone_3_2 -#define ucnv_setDefaultName ucnv_setDefaultName_3_2 -#define ucnv_setFallback ucnv_setFallback_3_2 -#define ucnv_setFromUCallBack ucnv_setFromUCallBack_3_2 -#define ucnv_setSubstChars ucnv_setSubstChars_3_2 -#define ucnv_setToUCallBack ucnv_setToUCallBack_3_2 -#define ucnv_swap ucnv_swap_3_2 -#define ucnv_swapAliases ucnv_swapAliases_3_2 -#define ucnv_toAlgorithmic ucnv_toAlgorithmic_3_2 -#define ucnv_toUChars ucnv_toUChars_3_2 -#define ucnv_toUWriteCodePoint ucnv_toUWriteCodePoint_3_2 -#define ucnv_toUWriteUChars ucnv_toUWriteUChars_3_2 -#define ucnv_toUnicode ucnv_toUnicode_3_2 -#define ucnv_unload ucnv_unload_3_2 -#define ucnv_unloadSharedDataIfReady ucnv_unloadSharedDataIfReady_3_2 -#define ucnv_usesFallback ucnv_usesFallback_3_2 -#define ucol_allocWeights ucol_allocWeights_3_2 -#define ucol_assembleTailoringTable ucol_assembleTailoringTable_3_2 -#define ucol_calcSortKey ucol_calcSortKey_3_2 -#define ucol_calcSortKeySimpleTertiary ucol_calcSortKeySimpleTertiary_3_2 -#define ucol_cloneBinary ucol_cloneBinary_3_2 -#define ucol_cloneRuleData ucol_cloneRuleData_3_2 -#define ucol_close ucol_close_3_2 -#define ucol_closeElements ucol_closeElements_3_2 -#define ucol_collatorToIdentifier ucol_collatorToIdentifier_3_2 -#define ucol_countAvailable ucol_countAvailable_3_2 -#define ucol_createElements ucol_createElements_3_2 -#define ucol_doCE ucol_doCE_3_2 -#define ucol_equal ucol_equal_3_2 -#define ucol_equals ucol_equals_3_2 -#define ucol_getAttribute ucol_getAttribute_3_2 -#define ucol_getAttributeOrDefault ucol_getAttributeOrDefault_3_2 -#define ucol_getAvailable ucol_getAvailable_3_2 -#define ucol_getBound ucol_getBound_3_2 -#define ucol_getCEGenerator ucol_getCEGenerator_3_2 -#define ucol_getCEStrengthDifference ucol_getCEStrengthDifference_3_2 -#define ucol_getContractions ucol_getContractions_3_2 -#define ucol_getDisplayName ucol_getDisplayName_3_2 -#define ucol_getFirstCE ucol_getFirstCE_3_2 -#define ucol_getFunctionalEquivalent ucol_getFunctionalEquivalent_3_2 -#define ucol_getKeywordValues ucol_getKeywordValues_3_2 -#define ucol_getKeywords ucol_getKeywords_3_2 -#define ucol_getLocale ucol_getLocale_3_2 -#define ucol_getLocaleByType ucol_getLocaleByType_3_2 -#define ucol_getMaxExpansion ucol_getMaxExpansion_3_2 -#define ucol_getNextCE ucol_getNextCE_3_2 -#define ucol_getNextGenerated ucol_getNextGenerated_3_2 -#define ucol_getOffset ucol_getOffset_3_2 -#define ucol_getPrevCE ucol_getPrevCE_3_2 -#define ucol_getRules ucol_getRules_3_2 -#define ucol_getRulesEx ucol_getRulesEx_3_2 -#define ucol_getShortDefinitionString ucol_getShortDefinitionString_3_2 -#define ucol_getSimpleCEGenerator ucol_getSimpleCEGenerator_3_2 -#define ucol_getSortKey ucol_getSortKey_3_2 -#define ucol_getSortKeySize ucol_getSortKeySize_3_2 -#define ucol_getSortKeyWithAllocation ucol_getSortKeyWithAllocation_3_2 -#define ucol_getStrength ucol_getStrength_3_2 -#define ucol_getTailoredSet ucol_getTailoredSet_3_2 -#define ucol_getUCAVersion ucol_getUCAVersion_3_2 -#define ucol_getUnsafeSet ucol_getUnsafeSet_3_2 -#define ucol_getVariableTop ucol_getVariableTop_3_2 -#define ucol_getVersion ucol_getVersion_3_2 -#define ucol_greater ucol_greater_3_2 -#define ucol_greaterOrEqual ucol_greaterOrEqual_3_2 -#define ucol_identifierToShortString ucol_identifierToShortString_3_2 -#define ucol_initBuffers ucol_initBuffers_3_2 -#define ucol_initCollator ucol_initCollator_3_2 -#define ucol_initInverseUCA ucol_initInverseUCA_3_2 -#define ucol_initUCA ucol_initUCA_3_2 -#define ucol_inv_getGapPositions ucol_inv_getGapPositions_3_2 -#define ucol_inv_getNextCE ucol_inv_getNextCE_3_2 -#define ucol_inv_getPrevCE ucol_inv_getPrevCE_3_2 -#define ucol_isTailored ucol_isTailored_3_2 -#define ucol_keyHashCode ucol_keyHashCode_3_2 -#define ucol_mergeSortkeys ucol_mergeSortkeys_3_2 -#define ucol_next ucol_next_3_2 -#define ucol_nextSortKeyPart ucol_nextSortKeyPart_3_2 -#define ucol_nextWeight ucol_nextWeight_3_2 -#define ucol_normalizeShortDefinitionString ucol_normalizeShortDefinitionString_3_2 -#define ucol_open ucol_open_3_2 -#define ucol_openAvailableLocales ucol_openAvailableLocales_3_2 -#define ucol_openBinary ucol_openBinary_3_2 -#define ucol_openElements ucol_openElements_3_2 -#define ucol_openFromIdentifier ucol_openFromIdentifier_3_2 -#define ucol_openFromShortString ucol_openFromShortString_3_2 -#define ucol_openRules ucol_openRules_3_2 -#define ucol_open_internal ucol_open_internal_3_2 -#define ucol_previous ucol_previous_3_2 -#define ucol_primaryOrder ucol_primaryOrder_3_2 -#define ucol_prv_getSpecialCE ucol_prv_getSpecialCE_3_2 -#define ucol_prv_getSpecialPrevCE ucol_prv_getSpecialPrevCE_3_2 -#define ucol_reset ucol_reset_3_2 -#define ucol_restoreVariableTop ucol_restoreVariableTop_3_2 -#define ucol_safeClone ucol_safeClone_3_2 -#define ucol_secondaryOrder ucol_secondaryOrder_3_2 -#define ucol_setAttribute ucol_setAttribute_3_2 -#define ucol_setOffset ucol_setOffset_3_2 -#define ucol_setOptionsFromHeader ucol_setOptionsFromHeader_3_2 -#define ucol_setReqValidLocales ucol_setReqValidLocales_3_2 -#define ucol_setStrength ucol_setStrength_3_2 -#define ucol_setText ucol_setText_3_2 -#define ucol_setVariableTop ucol_setVariableTop_3_2 -#define ucol_shortStringToIdentifier ucol_shortStringToIdentifier_3_2 -#define ucol_sortKeyToString ucol_sortKeyToString_3_2 -#define ucol_strcoll ucol_strcoll_3_2 -#define ucol_strcollIter ucol_strcollIter_3_2 -#define ucol_swap ucol_swap_3_2 -#define ucol_swapBinary ucol_swapBinary_3_2 -#define ucol_swapInverseUCA ucol_swapInverseUCA_3_2 -#define ucol_tertiaryOrder ucol_tertiaryOrder_3_2 -#define ucol_tok_assembleTokenList ucol_tok_assembleTokenList_3_2 -#define ucol_tok_closeTokenList ucol_tok_closeTokenList_3_2 -#define ucol_tok_getNextArgument ucol_tok_getNextArgument_3_2 -#define ucol_tok_initTokenList ucol_tok_initTokenList_3_2 -#define ucol_tok_parseNextToken ucol_tok_parseNextToken_3_2 -#define ucol_updateInternalState ucol_updateInternalState_3_2 -#define ucurr_forLocale ucurr_forLocale_3_2 -#define ucurr_getDefaultFractionDigits ucurr_getDefaultFractionDigits_3_2 -#define ucurr_getName ucurr_getName_3_2 -#define ucurr_getRoundingIncrement ucurr_getRoundingIncrement_3_2 -#define ucurr_register ucurr_register_3_2 -#define ucurr_unregister ucurr_unregister_3_2 -#define udat_applyPattern udat_applyPattern_3_2 -#define udat_clone udat_clone_3_2 -#define udat_close udat_close_3_2 -#define udat_countAvailable udat_countAvailable_3_2 -#define udat_countSymbols udat_countSymbols_3_2 -#define udat_format udat_format_3_2 -#define udat_get2DigitYearStart udat_get2DigitYearStart_3_2 -#define udat_getAvailable udat_getAvailable_3_2 -#define udat_getCalendar udat_getCalendar_3_2 -#define udat_getLocaleByType udat_getLocaleByType_3_2 -#define udat_getNumberFormat udat_getNumberFormat_3_2 -#define udat_getSymbols udat_getSymbols_3_2 -#define udat_isLenient udat_isLenient_3_2 -#define udat_open udat_open_3_2 -#define udat_parse udat_parse_3_2 -#define udat_parseCalendar udat_parseCalendar_3_2 -#define udat_set2DigitYearStart udat_set2DigitYearStart_3_2 -#define udat_setCalendar udat_setCalendar_3_2 -#define udat_setLenient udat_setLenient_3_2 -#define udat_setNumberFormat udat_setNumberFormat_3_2 -#define udat_setSymbols udat_setSymbols_3_2 -#define udat_toPattern udat_toPattern_3_2 -#define udata_checkCommonData udata_checkCommonData_3_2 -#define udata_close udata_close_3_2 -#define udata_closeSwapper udata_closeSwapper_3_2 -#define udata_getHeaderSize udata_getHeaderSize_3_2 -#define udata_getInfo udata_getInfo_3_2 -#define udata_getInfoSize udata_getInfoSize_3_2 -#define udata_getLength udata_getLength_3_2 -#define udata_getMemory udata_getMemory_3_2 -#define udata_getRawMemory udata_getRawMemory_3_2 -#define udata_open udata_open_3_2 -#define udata_openChoice udata_openChoice_3_2 -#define udata_openSwapper udata_openSwapper_3_2 -#define udata_openSwapperForInputData udata_openSwapperForInputData_3_2 -#define udata_printError udata_printError_3_2 -#define udata_readInt16 udata_readInt16_3_2 -#define udata_readInt32 udata_readInt32_3_2 -#define udata_setAppData udata_setAppData_3_2 -#define udata_setCommonData udata_setCommonData_3_2 -#define udata_swapDataHeader udata_swapDataHeader_3_2 -#define udata_swapInvStringBlock udata_swapInvStringBlock_3_2 -#define uenum_close uenum_close_3_2 -#define uenum_count uenum_count_3_2 -#define uenum_next uenum_next_3_2 -#define uenum_nextDefault uenum_nextDefault_3_2 -#define uenum_openCharStringsEnumeration uenum_openCharStringsEnumeration_3_2 -#define uenum_openStringEnumeration uenum_openStringEnumeration_3_2 -#define uenum_reset uenum_reset_3_2 -#define uenum_unext uenum_unext_3_2 -#define uenum_unextDefault uenum_unextDefault_3_2 -#define ufile_close_translit ufile_close_translit_3_2 -#define ufile_fill_uchar_buffer ufile_fill_uchar_buffer_3_2 -#define ufile_flush_translit ufile_flush_translit_3_2 -#define ufile_getch ufile_getch_3_2 -#define ufile_getch32 ufile_getch32_3_2 -#define ufmt_64tou ufmt_64tou_3_2 -#define ufmt_defaultCPToUnicode ufmt_defaultCPToUnicode_3_2 -#define ufmt_digitvalue ufmt_digitvalue_3_2 -#define ufmt_isdigit ufmt_isdigit_3_2 -#define ufmt_ptou ufmt_ptou_3_2 -#define ufmt_uto64 ufmt_uto64_3_2 -#define ufmt_utop ufmt_utop_3_2 -#define uhash_close uhash_close_3_2 -#define uhash_compareCaselessUnicodeString uhash_compareCaselessUnicodeString_3_2 -#define uhash_compareChars uhash_compareChars_3_2 -#define uhash_compareIChars uhash_compareIChars_3_2 -#define uhash_compareLong uhash_compareLong_3_2 -#define uhash_compareUChars uhash_compareUChars_3_2 -#define uhash_compareUnicodeString uhash_compareUnicodeString_3_2 -#define uhash_count uhash_count_3_2 -#define uhash_deleteHashtable uhash_deleteHashtable_3_2 -#define uhash_deleteUVector uhash_deleteUVector_3_2 -#define uhash_deleteUnicodeString uhash_deleteUnicodeString_3_2 -#define uhash_find uhash_find_3_2 -#define uhash_freeBlock uhash_freeBlock_3_2 -#define uhash_get uhash_get_3_2 -#define uhash_geti uhash_geti_3_2 -#define uhash_hashCaselessUnicodeString uhash_hashCaselessUnicodeString_3_2 -#define uhash_hashChars uhash_hashChars_3_2 -#define uhash_hashIChars uhash_hashIChars_3_2 -#define uhash_hashLong uhash_hashLong_3_2 -#define uhash_hashUChars uhash_hashUChars_3_2 -#define uhash_hashUCharsN uhash_hashUCharsN_3_2 -#define uhash_hashUnicodeString uhash_hashUnicodeString_3_2 -#define uhash_iget uhash_iget_3_2 -#define uhash_igeti uhash_igeti_3_2 -#define uhash_iput uhash_iput_3_2 -#define uhash_iputi uhash_iputi_3_2 -#define uhash_iremove uhash_iremove_3_2 -#define uhash_iremovei uhash_iremovei_3_2 -#define uhash_nextElement uhash_nextElement_3_2 -#define uhash_open uhash_open_3_2 -#define uhash_openSize uhash_openSize_3_2 -#define uhash_put uhash_put_3_2 -#define uhash_puti uhash_puti_3_2 -#define uhash_remove uhash_remove_3_2 -#define uhash_removeAll uhash_removeAll_3_2 -#define uhash_removeElement uhash_removeElement_3_2 -#define uhash_removei uhash_removei_3_2 -#define uhash_setKeyComparator uhash_setKeyComparator_3_2 -#define uhash_setKeyDeleter uhash_setKeyDeleter_3_2 -#define uhash_setKeyHasher uhash_setKeyHasher_3_2 -#define uhash_setResizePolicy uhash_setResizePolicy_3_2 -#define uhash_setValueDeleter uhash_setValueDeleter_3_2 -#define uhash_toki uhash_toki_3_2 -#define uhash_tokp uhash_tokp_3_2 -#define uhst_addPropertyStarts uhst_addPropertyStarts_3_2 -#define uidna_IDNToASCII uidna_IDNToASCII_3_2 -#define uidna_IDNToUnicode uidna_IDNToUnicode_3_2 -#define uidna_compare uidna_compare_3_2 -#define uidna_toASCII uidna_toASCII_3_2 -#define uidna_toUnicode uidna_toUnicode_3_2 -#define uiter_current32 uiter_current32_3_2 -#define uiter_getState uiter_getState_3_2 -#define uiter_next32 uiter_next32_3_2 -#define uiter_previous32 uiter_previous32_3_2 -#define uiter_setCharacterIterator uiter_setCharacterIterator_3_2 -#define uiter_setReplaceable uiter_setReplaceable_3_2 -#define uiter_setState uiter_setState_3_2 -#define uiter_setString uiter_setString_3_2 -#define uiter_setUTF16BE uiter_setUTF16BE_3_2 -#define uiter_setUTF8 uiter_setUTF8_3_2 -#define uloc_acceptLanguage uloc_acceptLanguage_3_2 -#define uloc_acceptLanguageFromHTTP uloc_acceptLanguageFromHTTP_3_2 -#define uloc_canonicalize uloc_canonicalize_3_2 -#define uloc_countAvailable uloc_countAvailable_3_2 -#define uloc_getAvailable uloc_getAvailable_3_2 -#define uloc_getBaseName uloc_getBaseName_3_2 -#define uloc_getCountry uloc_getCountry_3_2 -#define uloc_getDefault uloc_getDefault_3_2 -#define uloc_getDisplayCountry uloc_getDisplayCountry_3_2 -#define uloc_getDisplayKeyword uloc_getDisplayKeyword_3_2 -#define uloc_getDisplayKeywordValue uloc_getDisplayKeywordValue_3_2 -#define uloc_getDisplayLanguage uloc_getDisplayLanguage_3_2 -#define uloc_getDisplayName uloc_getDisplayName_3_2 -#define uloc_getDisplayScript uloc_getDisplayScript_3_2 -#define uloc_getDisplayVariant uloc_getDisplayVariant_3_2 -#define uloc_getISO3Country uloc_getISO3Country_3_2 -#define uloc_getISO3Language uloc_getISO3Language_3_2 -#define uloc_getISOCountries uloc_getISOCountries_3_2 -#define uloc_getISOLanguages uloc_getISOLanguages_3_2 -#define uloc_getKeywordValue uloc_getKeywordValue_3_2 -#define uloc_getLCID uloc_getLCID_3_2 -#define uloc_getLanguage uloc_getLanguage_3_2 -#define uloc_getName uloc_getName_3_2 -#define uloc_getParent uloc_getParent_3_2 -#define uloc_getScript uloc_getScript_3_2 -#define uloc_getVariant uloc_getVariant_3_2 -#define uloc_openKeywordList uloc_openKeywordList_3_2 -#define uloc_openKeywords uloc_openKeywords_3_2 -#define uloc_setDefault uloc_setDefault_3_2 -#define uloc_setKeywordValue uloc_setKeywordValue_3_2 -#define ulocdata_getExemplarSet ulocdata_getExemplarSet_3_2 -#define ulocdata_getMeasurementSystem ulocdata_getMeasurementSystem_3_2 -#define ulocdata_getPaperSize ulocdata_getPaperSize_3_2 -#define umsg_applyPattern umsg_applyPattern_3_2 -#define umsg_clone umsg_clone_3_2 -#define umsg_close umsg_close_3_2 -#define umsg_format umsg_format_3_2 -#define umsg_getLocale umsg_getLocale_3_2 -#define umsg_getLocaleByType umsg_getLocaleByType_3_2 -#define umsg_open umsg_open_3_2 -#define umsg_parse umsg_parse_3_2 -#define umsg_setLocale umsg_setLocale_3_2 -#define umsg_toPattern umsg_toPattern_3_2 -#define umsg_vformat umsg_vformat_3_2 -#define umsg_vparse umsg_vparse_3_2 -#define umtx_atomic_dec umtx_atomic_dec_3_2 -#define umtx_atomic_inc umtx_atomic_inc_3_2 -#define umtx_cleanup umtx_cleanup_3_2 -#define umtx_destroy umtx_destroy_3_2 -#define umtx_init umtx_init_3_2 -#define umtx_lock umtx_lock_3_2 -#define umtx_unlock umtx_unlock_3_2 -#define unorm_addPropertyStarts unorm_addPropertyStarts_3_2 -#define unorm_closeIter unorm_closeIter_3_2 -#define unorm_compare unorm_compare_3_2 -#define unorm_compose unorm_compose_3_2 -#define unorm_concatenate unorm_concatenate_3_2 -#define unorm_decompose unorm_decompose_3_2 -#define unorm_getCanonStartSet unorm_getCanonStartSet_3_2 -#define unorm_getCanonicalDecomposition unorm_getCanonicalDecomposition_3_2 -#define unorm_getDecomposition unorm_getDecomposition_3_2 -#define unorm_getFCD16FromCodePoint unorm_getFCD16FromCodePoint_3_2 -#define unorm_getFCDTrie unorm_getFCDTrie_3_2 -#define unorm_getNX unorm_getNX_3_2 -#define unorm_getQuickCheck unorm_getQuickCheck_3_2 -#define unorm_getUnicodeVersion unorm_getUnicodeVersion_3_2 -#define unorm_haveData unorm_haveData_3_2 -#define unorm_internalIsFullCompositionExclusion unorm_internalIsFullCompositionExclusion_3_2 -#define unorm_internalNormalize unorm_internalNormalize_3_2 -#define unorm_internalNormalizeWithNX unorm_internalNormalizeWithNX_3_2 -#define unorm_internalQuickCheck unorm_internalQuickCheck_3_2 -#define unorm_isCanonSafeStart unorm_isCanonSafeStart_3_2 -#define unorm_isNFSkippable unorm_isNFSkippable_3_2 -#define unorm_isNormalized unorm_isNormalized_3_2 -#define unorm_isNormalizedWithOptions unorm_isNormalizedWithOptions_3_2 -#define unorm_next unorm_next_3_2 -#define unorm_normalize unorm_normalize_3_2 -#define unorm_openIter unorm_openIter_3_2 -#define unorm_previous unorm_previous_3_2 -#define unorm_quickCheck unorm_quickCheck_3_2 -#define unorm_quickCheckWithOptions unorm_quickCheckWithOptions_3_2 -#define unorm_setIter unorm_setIter_3_2 -#define unorm_swap unorm_swap_3_2 -#define unum_applyPattern unum_applyPattern_3_2 -#define unum_clone unum_clone_3_2 -#define unum_close unum_close_3_2 -#define unum_countAvailable unum_countAvailable_3_2 -#define unum_format unum_format_3_2 -#define unum_formatDouble unum_formatDouble_3_2 -#define unum_formatDoubleCurrency unum_formatDoubleCurrency_3_2 -#define unum_formatInt64 unum_formatInt64_3_2 -#define unum_getAttribute unum_getAttribute_3_2 -#define unum_getAvailable unum_getAvailable_3_2 -#define unum_getDoubleAttribute unum_getDoubleAttribute_3_2 -#define unum_getLocaleByType unum_getLocaleByType_3_2 -#define unum_getSymbol unum_getSymbol_3_2 -#define unum_getTextAttribute unum_getTextAttribute_3_2 -#define unum_open unum_open_3_2 -#define unum_parse unum_parse_3_2 -#define unum_parseDouble unum_parseDouble_3_2 -#define unum_parseDoubleCurrency unum_parseDoubleCurrency_3_2 -#define unum_parseInt64 unum_parseInt64_3_2 -#define unum_setAttribute unum_setAttribute_3_2 -#define unum_setDoubleAttribute unum_setDoubleAttribute_3_2 -#define unum_setSymbol unum_setSymbol_3_2 -#define unum_setTextAttribute unum_setTextAttribute_3_2 -#define unum_toPattern unum_toPattern_3_2 -#define upname_swap upname_swap_3_2 -#define uprops_getSource uprops_getSource_3_2 -#define uprops_swap uprops_swap_3_2 -#define uprv_asciiFromEbcdic uprv_asciiFromEbcdic_3_2 -#define uprv_asciitolower uprv_asciitolower_3_2 -#define uprv_ceil uprv_ceil_3_2 -#define uprv_cnttab_addContraction uprv_cnttab_addContraction_3_2 -#define uprv_cnttab_changeContraction uprv_cnttab_changeContraction_3_2 -#define uprv_cnttab_changeLastCE uprv_cnttab_changeLastCE_3_2 -#define uprv_cnttab_clone uprv_cnttab_clone_3_2 -#define uprv_cnttab_close uprv_cnttab_close_3_2 -#define uprv_cnttab_constructTable uprv_cnttab_constructTable_3_2 -#define uprv_cnttab_findCE uprv_cnttab_findCE_3_2 -#define uprv_cnttab_findCP uprv_cnttab_findCP_3_2 -#define uprv_cnttab_getCE uprv_cnttab_getCE_3_2 -#define uprv_cnttab_insertContraction uprv_cnttab_insertContraction_3_2 -#define uprv_cnttab_isTailored uprv_cnttab_isTailored_3_2 -#define uprv_cnttab_open uprv_cnttab_open_3_2 -#define uprv_cnttab_setContraction uprv_cnttab_setContraction_3_2 -#define uprv_compareASCIIPropertyNames uprv_compareASCIIPropertyNames_3_2 -#define uprv_compareEBCDICPropertyNames uprv_compareEBCDICPropertyNames_3_2 -#define uprv_compareInvAscii uprv_compareInvAscii_3_2 -#define uprv_compareInvEbcdic uprv_compareInvEbcdic_3_2 -#define uprv_convertToLCID uprv_convertToLCID_3_2 -#define uprv_convertToPosix uprv_convertToPosix_3_2 -#define uprv_copyAscii uprv_copyAscii_3_2 -#define uprv_copyEbcdic uprv_copyEbcdic_3_2 -#define uprv_dtostr uprv_dtostr_3_2 -#define uprv_ebcdicFromAscii uprv_ebcdicFromAscii_3_2 -#define uprv_ebcdictolower uprv_ebcdictolower_3_2 -#define uprv_fabs uprv_fabs_3_2 -#define uprv_floor uprv_floor_3_2 -#define uprv_fmax uprv_fmax_3_2 -#define uprv_fmin uprv_fmin_3_2 -#define uprv_fmod uprv_fmod_3_2 -#define uprv_free uprv_free_3_2 -#define uprv_getCharNameCharacters uprv_getCharNameCharacters_3_2 -#define uprv_getDefaultCodepage uprv_getDefaultCodepage_3_2 -#define uprv_getDefaultLocaleID uprv_getDefaultLocaleID_3_2 -#define uprv_getInfinity uprv_getInfinity_3_2 -#define uprv_getMaxCharNameLength uprv_getMaxCharNameLength_3_2 -#define uprv_getMaxValues uprv_getMaxValues_3_2 -#define uprv_getNaN uprv_getNaN_3_2 -#define uprv_getStaticCurrencyName uprv_getStaticCurrencyName_3_2 -#define uprv_getUTCtime uprv_getUTCtime_3_2 -#define uprv_haveProperties uprv_haveProperties_3_2 -#define uprv_init_collIterate uprv_init_collIterate_3_2 -#define uprv_int32Comparator uprv_int32Comparator_3_2 -#define uprv_isInfinite uprv_isInfinite_3_2 -#define uprv_isInvariantString uprv_isInvariantString_3_2 -#define uprv_isInvariantUString uprv_isInvariantUString_3_2 -#define uprv_isNaN uprv_isNaN_3_2 -#define uprv_isNegativeInfinity uprv_isNegativeInfinity_3_2 -#define uprv_isPositiveInfinity uprv_isPositiveInfinity_3_2 -#define uprv_isRuleWhiteSpace uprv_isRuleWhiteSpace_3_2 -#define uprv_itou uprv_itou_3_2 -#define uprv_loadPropsData uprv_loadPropsData_3_2 -#define uprv_log uprv_log_3_2 -#define uprv_log10 uprv_log10_3_2 -#define uprv_malloc uprv_malloc_3_2 -#define uprv_mapFile uprv_mapFile_3_2 -#define uprv_max uprv_max_3_2 -#define uprv_maxMantissa uprv_maxMantissa_3_2 -#define uprv_min uprv_min_3_2 -#define uprv_modf uprv_modf_3_2 -#define uprv_openRuleWhiteSpaceSet uprv_openRuleWhiteSpaceSet_3_2 -#define uprv_pathIsAbsolute uprv_pathIsAbsolute_3_2 -#define uprv_pow uprv_pow_3_2 -#define uprv_pow10 uprv_pow10_3_2 -#define uprv_realloc uprv_realloc_3_2 -#define uprv_round uprv_round_3_2 -#define uprv_sortArray uprv_sortArray_3_2 -#define uprv_strCompare uprv_strCompare_3_2 -#define uprv_strdup uprv_strdup_3_2 -#define uprv_strndup uprv_strndup_3_2 -#define uprv_syntaxError uprv_syntaxError_3_2 -#define uprv_timezone uprv_timezone_3_2 -#define uprv_toupper uprv_toupper_3_2 -#define uprv_trunc uprv_trunc_3_2 -#define uprv_tzname uprv_tzname_3_2 -#define uprv_tzset uprv_tzset_3_2 -#define uprv_uca_addAnElement uprv_uca_addAnElement_3_2 -#define uprv_uca_assembleTable uprv_uca_assembleTable_3_2 -#define uprv_uca_canonicalClosure uprv_uca_canonicalClosure_3_2 -#define uprv_uca_cloneTempTable uprv_uca_cloneTempTable_3_2 -#define uprv_uca_closeTempTable uprv_uca_closeTempTable_3_2 -#define uprv_uca_getCodePointFromRaw uprv_uca_getCodePointFromRaw_3_2 -#define uprv_uca_getImplicitFromRaw uprv_uca_getImplicitFromRaw_3_2 -#define uprv_uca_getImplicitPrimary uprv_uca_getImplicitPrimary_3_2 -#define uprv_uca_getRawFromCodePoint uprv_uca_getRawFromCodePoint_3_2 -#define uprv_uca_getRawFromImplicit uprv_uca_getRawFromImplicit_3_2 -#define uprv_uca_initImplicitConstants uprv_uca_initImplicitConstants_3_2 -#define uprv_uca_initTempTable uprv_uca_initTempTable_3_2 -#define uprv_uint16Comparator uprv_uint16Comparator_3_2 -#define uprv_uint32Comparator uprv_uint32Comparator_3_2 -#define uprv_unmapFile uprv_unmapFile_3_2 -#define uregex_appendReplacement uregex_appendReplacement_3_2 -#define uregex_appendTail uregex_appendTail_3_2 -#define uregex_clone uregex_clone_3_2 -#define uregex_close uregex_close_3_2 -#define uregex_end uregex_end_3_2 -#define uregex_find uregex_find_3_2 -#define uregex_findNext uregex_findNext_3_2 -#define uregex_flags uregex_flags_3_2 -#define uregex_getText uregex_getText_3_2 -#define uregex_group uregex_group_3_2 -#define uregex_groupCount uregex_groupCount_3_2 -#define uregex_lookingAt uregex_lookingAt_3_2 -#define uregex_matches uregex_matches_3_2 -#define uregex_open uregex_open_3_2 -#define uregex_openC uregex_openC_3_2 -#define uregex_pattern uregex_pattern_3_2 -#define uregex_replaceAll uregex_replaceAll_3_2 -#define uregex_replaceFirst uregex_replaceFirst_3_2 -#define uregex_reset uregex_reset_3_2 -#define uregex_setText uregex_setText_3_2 -#define uregex_split uregex_split_3_2 -#define uregex_start uregex_start_3_2 -#define ures_appendResPath ures_appendResPath_3_2 -#define ures_close ures_close_3_2 -#define ures_copyResb ures_copyResb_3_2 -#define ures_countArrayItems ures_countArrayItems_3_2 -#define ures_findResource ures_findResource_3_2 -#define ures_findSubResource ures_findSubResource_3_2 -#define ures_freeResPath ures_freeResPath_3_2 -#define ures_getBinary ures_getBinary_3_2 -#define ures_getByIndex ures_getByIndex_3_2 -#define ures_getByKey ures_getByKey_3_2 -#define ures_getByKeyWithFallback ures_getByKeyWithFallback_3_2 -#define ures_getFunctionalEquivalent ures_getFunctionalEquivalent_3_2 -#define ures_getInt ures_getInt_3_2 -#define ures_getIntVector ures_getIntVector_3_2 -#define ures_getKey ures_getKey_3_2 -#define ures_getKeywordValues ures_getKeywordValues_3_2 -#define ures_getLocale ures_getLocale_3_2 -#define ures_getLocaleByType ures_getLocaleByType_3_2 -#define ures_getName ures_getName_3_2 -#define ures_getNextResource ures_getNextResource_3_2 -#define ures_getNextString ures_getNextString_3_2 -#define ures_getPath ures_getPath_3_2 -#define ures_getSize ures_getSize_3_2 -#define ures_getString ures_getString_3_2 -#define ures_getStringByIndex ures_getStringByIndex_3_2 -#define ures_getStringByKey ures_getStringByKey_3_2 -#define ures_getType ures_getType_3_2 -#define ures_getUInt ures_getUInt_3_2 -#define ures_getVersion ures_getVersion_3_2 -#define ures_getVersionNumber ures_getVersionNumber_3_2 -#define ures_hasNext ures_hasNext_3_2 -#define ures_initStackObject ures_initStackObject_3_2 -#define ures_open ures_open_3_2 -#define ures_openAvailableLocales ures_openAvailableLocales_3_2 -#define ures_openDirect ures_openDirect_3_2 -#define ures_openFillIn ures_openFillIn_3_2 -#define ures_openU ures_openU_3_2 -#define ures_resetIterator ures_resetIterator_3_2 -#define ures_swap ures_swap_3_2 -#define uscript_closeRun uscript_closeRun_3_2 -#define uscript_getCode uscript_getCode_3_2 -#define uscript_getName uscript_getName_3_2 -#define uscript_getScript uscript_getScript_3_2 -#define uscript_getShortName uscript_getShortName_3_2 -#define uscript_nextRun uscript_nextRun_3_2 -#define uscript_openRun uscript_openRun_3_2 -#define uscript_resetRun uscript_resetRun_3_2 -#define uscript_setRunText uscript_setRunText_3_2 -#define usearch_close usearch_close_3_2 -#define usearch_first usearch_first_3_2 -#define usearch_following usearch_following_3_2 -#define usearch_getAttribute usearch_getAttribute_3_2 -#define usearch_getBreakIterator usearch_getBreakIterator_3_2 -#define usearch_getCollator usearch_getCollator_3_2 -#define usearch_getMatchedLength usearch_getMatchedLength_3_2 -#define usearch_getMatchedStart usearch_getMatchedStart_3_2 -#define usearch_getMatchedText usearch_getMatchedText_3_2 -#define usearch_getOffset usearch_getOffset_3_2 -#define usearch_getPattern usearch_getPattern_3_2 -#define usearch_getText usearch_getText_3_2 -#define usearch_handleNextCanonical usearch_handleNextCanonical_3_2 -#define usearch_handleNextExact usearch_handleNextExact_3_2 -#define usearch_handlePreviousCanonical usearch_handlePreviousCanonical_3_2 -#define usearch_handlePreviousExact usearch_handlePreviousExact_3_2 -#define usearch_last usearch_last_3_2 -#define usearch_next usearch_next_3_2 -#define usearch_open usearch_open_3_2 -#define usearch_openFromCollator usearch_openFromCollator_3_2 -#define usearch_preceding usearch_preceding_3_2 -#define usearch_previous usearch_previous_3_2 -#define usearch_reset usearch_reset_3_2 -#define usearch_setAttribute usearch_setAttribute_3_2 -#define usearch_setBreakIterator usearch_setBreakIterator_3_2 -#define usearch_setCollator usearch_setCollator_3_2 -#define usearch_setOffset usearch_setOffset_3_2 -#define usearch_setPattern usearch_setPattern_3_2 -#define usearch_setText usearch_setText_3_2 -#define userv_deleteStringPair userv_deleteStringPair_3_2 -#define uset_add uset_add_3_2 -#define uset_addAll uset_addAll_3_2 -#define uset_addRange uset_addRange_3_2 -#define uset_addString uset_addString_3_2 -#define uset_applyIntPropertyValue uset_applyIntPropertyValue_3_2 -#define uset_applyPattern uset_applyPattern_3_2 -#define uset_applyPropertyAlias uset_applyPropertyAlias_3_2 -#define uset_charAt uset_charAt_3_2 -#define uset_clear uset_clear_3_2 -#define uset_close uset_close_3_2 -#define uset_compact uset_compact_3_2 -#define uset_complement uset_complement_3_2 -#define uset_complementAll uset_complementAll_3_2 -#define uset_contains uset_contains_3_2 -#define uset_containsAll uset_containsAll_3_2 -#define uset_containsNone uset_containsNone_3_2 -#define uset_containsRange uset_containsRange_3_2 -#define uset_containsSome uset_containsSome_3_2 -#define uset_containsString uset_containsString_3_2 -#define uset_equals uset_equals_3_2 -#define uset_getItem uset_getItem_3_2 -#define uset_getItemCount uset_getItemCount_3_2 -#define uset_getSerializedRange uset_getSerializedRange_3_2 -#define uset_getSerializedRangeCount uset_getSerializedRangeCount_3_2 -#define uset_getSerializedSet uset_getSerializedSet_3_2 -#define uset_indexOf uset_indexOf_3_2 -#define uset_isEmpty uset_isEmpty_3_2 -#define uset_open uset_open_3_2 -#define uset_openPattern uset_openPattern_3_2 -#define uset_openPatternOptions uset_openPatternOptions_3_2 -#define uset_remove uset_remove_3_2 -#define uset_removeAll uset_removeAll_3_2 -#define uset_removeRange uset_removeRange_3_2 -#define uset_removeString uset_removeString_3_2 -#define uset_resemblesPattern uset_resemblesPattern_3_2 -#define uset_retain uset_retain_3_2 -#define uset_retainAll uset_retainAll_3_2 -#define uset_serialize uset_serialize_3_2 -#define uset_serializedContains uset_serializedContains_3_2 -#define uset_set uset_set_3_2 -#define uset_setSerializedToOne uset_setSerializedToOne_3_2 -#define uset_size uset_size_3_2 -#define uset_toPattern uset_toPattern_3_2 -#define usprep_close usprep_close_3_2 -#define usprep_open usprep_open_3_2 -#define usprep_prepare usprep_prepare_3_2 -#define usprep_swap usprep_swap_3_2 -#define ustr_foldCase ustr_foldCase_3_2 -#define ustr_toLower ustr_toLower_3_2 -#define ustr_toTitle ustr_toTitle_3_2 -#define ustr_toUpper ustr_toUpper_3_2 -#define utf8_appendCharSafeBody utf8_appendCharSafeBody_3_2 -#define utf8_back1SafeBody utf8_back1SafeBody_3_2 -#define utf8_countTrailBytes utf8_countTrailBytes_3_2 -#define utf8_nextCharSafeBody utf8_nextCharSafeBody_3_2 -#define utf8_prevCharSafeBody utf8_prevCharSafeBody_3_2 -#define utmscale_fromInt64 utmscale_fromInt64_3_2 -#define utmscale_getTimeScaleValue utmscale_getTimeScaleValue_3_2 -#define utmscale_toInt64 utmscale_toInt64_3_2 -#define utrace_cleanup utrace_cleanup_3_2 -#define utrace_data utrace_data_3_2 -#define utrace_entry utrace_entry_3_2 -#define utrace_exit utrace_exit_3_2 -#define utrace_format utrace_format_3_2 -#define utrace_functionName utrace_functionName_3_2 -#define utrace_getFunctions utrace_getFunctions_3_2 -#define utrace_getLevel utrace_getLevel_3_2 -#define utrace_level utrace_level_3_2 -#define utrace_setFunctions utrace_setFunctions_3_2 -#define utrace_setLevel utrace_setLevel_3_2 -#define utrace_vformat utrace_vformat_3_2 -#define utrans_clone utrans_clone_3_2 -#define utrans_close utrans_close_3_2 -#define utrans_countAvailableIDs utrans_countAvailableIDs_3_2 -#define utrans_getAvailableID utrans_getAvailableID_3_2 -#define utrans_getID utrans_getID_3_2 -#define utrans_getUnicodeID utrans_getUnicodeID_3_2 -#define utrans_open utrans_open_3_2 -#define utrans_openIDs utrans_openIDs_3_2 -#define utrans_openInverse utrans_openInverse_3_2 -#define utrans_openU utrans_openU_3_2 -#define utrans_register utrans_register_3_2 -#define utrans_rep_caseContextIterator utrans_rep_caseContextIterator_3_2 -#define utrans_setFilter utrans_setFilter_3_2 -#define utrans_trans utrans_trans_3_2 -#define utrans_transIncremental utrans_transIncremental_3_2 -#define utrans_transIncrementalUChars utrans_transIncrementalUChars_3_2 -#define utrans_transUChars utrans_transUChars_3_2 -#define utrans_unregister utrans_unregister_3_2 -#define utrans_unregisterID utrans_unregisterID_3_2 -#define utrie_clone utrie_clone_3_2 -#define utrie_close utrie_close_3_2 -#define utrie_enum utrie_enum_3_2 -#define utrie_get32 utrie_get32_3_2 -#define utrie_getData utrie_getData_3_2 -#define utrie_open utrie_open_3_2 -#define utrie_serialize utrie_serialize_3_2 -#define utrie_set32 utrie_set32_3_2 -#define utrie_setRange32 utrie_setRange32_3_2 -#define utrie_swap utrie_swap_3_2 -#define utrie_unserialize utrie_unserialize_3_2 +#define DECPOWERS U_ICU_ENTRY_POINT_RENAME(DECPOWERS) +#define DECSTICKYTAB U_ICU_ENTRY_POINT_RENAME(DECSTICKYTAB) +#define LNnn U_ICU_ENTRY_POINT_RENAME(LNnn) +#define T_CString_int64ToString U_ICU_ENTRY_POINT_RENAME(T_CString_int64ToString) +#define T_CString_integerToString U_ICU_ENTRY_POINT_RENAME(T_CString_integerToString) +#define T_CString_stricmp U_ICU_ENTRY_POINT_RENAME(T_CString_stricmp) +#define T_CString_stringToInteger U_ICU_ENTRY_POINT_RENAME(T_CString_stringToInteger) +#define T_CString_strnicmp U_ICU_ENTRY_POINT_RENAME(T_CString_strnicmp) +#define T_CString_toLowerCase U_ICU_ENTRY_POINT_RENAME(T_CString_toLowerCase) +#define T_CString_toUpperCase U_ICU_ENTRY_POINT_RENAME(T_CString_toUpperCase) +#define UCNV_FROM_U_CALLBACK_ESCAPE U_ICU_ENTRY_POINT_RENAME(UCNV_FROM_U_CALLBACK_ESCAPE) +#define UCNV_FROM_U_CALLBACK_SKIP U_ICU_ENTRY_POINT_RENAME(UCNV_FROM_U_CALLBACK_SKIP) +#define UCNV_FROM_U_CALLBACK_STOP U_ICU_ENTRY_POINT_RENAME(UCNV_FROM_U_CALLBACK_STOP) +#define UCNV_FROM_U_CALLBACK_SUBSTITUTE U_ICU_ENTRY_POINT_RENAME(UCNV_FROM_U_CALLBACK_SUBSTITUTE) +#define UCNV_TO_U_CALLBACK_ESCAPE U_ICU_ENTRY_POINT_RENAME(UCNV_TO_U_CALLBACK_ESCAPE) +#define UCNV_TO_U_CALLBACK_SKIP U_ICU_ENTRY_POINT_RENAME(UCNV_TO_U_CALLBACK_SKIP) +#define UCNV_TO_U_CALLBACK_STOP U_ICU_ENTRY_POINT_RENAME(UCNV_TO_U_CALLBACK_STOP) +#define UCNV_TO_U_CALLBACK_SUBSTITUTE U_ICU_ENTRY_POINT_RENAME(UCNV_TO_U_CALLBACK_SUBSTITUTE) +#define UDataMemory_createNewInstance U_ICU_ENTRY_POINT_RENAME(UDataMemory_createNewInstance) +#define UDataMemory_init U_ICU_ENTRY_POINT_RENAME(UDataMemory_init) +#define UDataMemory_isLoaded U_ICU_ENTRY_POINT_RENAME(UDataMemory_isLoaded) +#define UDataMemory_normalizeDataPointer U_ICU_ENTRY_POINT_RENAME(UDataMemory_normalizeDataPointer) +#define UDataMemory_setData U_ICU_ENTRY_POINT_RENAME(UDataMemory_setData) +#define UDatamemory_assign U_ICU_ENTRY_POINT_RENAME(UDatamemory_assign) +#define _ASCIIData U_ICU_ENTRY_POINT_RENAME(_ASCIIData) +#define _Bocu1Data U_ICU_ENTRY_POINT_RENAME(_Bocu1Data) +#define _CESU8Data U_ICU_ENTRY_POINT_RENAME(_CESU8Data) +#define _HZData U_ICU_ENTRY_POINT_RENAME(_HZData) +#define _IMAPData U_ICU_ENTRY_POINT_RENAME(_IMAPData) +#define _ISCIIData U_ICU_ENTRY_POINT_RENAME(_ISCIIData) +#define _ISO2022Data U_ICU_ENTRY_POINT_RENAME(_ISO2022Data) +#define _LMBCSData1 U_ICU_ENTRY_POINT_RENAME(_LMBCSData1) +#define _LMBCSData11 U_ICU_ENTRY_POINT_RENAME(_LMBCSData11) +#define _LMBCSData16 U_ICU_ENTRY_POINT_RENAME(_LMBCSData16) +#define _LMBCSData17 U_ICU_ENTRY_POINT_RENAME(_LMBCSData17) +#define _LMBCSData18 U_ICU_ENTRY_POINT_RENAME(_LMBCSData18) +#define _LMBCSData19 U_ICU_ENTRY_POINT_RENAME(_LMBCSData19) +#define _LMBCSData2 U_ICU_ENTRY_POINT_RENAME(_LMBCSData2) +#define _LMBCSData3 U_ICU_ENTRY_POINT_RENAME(_LMBCSData3) +#define _LMBCSData4 U_ICU_ENTRY_POINT_RENAME(_LMBCSData4) +#define _LMBCSData5 U_ICU_ENTRY_POINT_RENAME(_LMBCSData5) +#define _LMBCSData6 U_ICU_ENTRY_POINT_RENAME(_LMBCSData6) +#define _LMBCSData8 U_ICU_ENTRY_POINT_RENAME(_LMBCSData8) +#define _Latin1Data U_ICU_ENTRY_POINT_RENAME(_Latin1Data) +#define _MBCSData U_ICU_ENTRY_POINT_RENAME(_MBCSData) +#define _SCSUData U_ICU_ENTRY_POINT_RENAME(_SCSUData) +#define _UTF16BEData U_ICU_ENTRY_POINT_RENAME(_UTF16BEData) +#define _UTF16Data U_ICU_ENTRY_POINT_RENAME(_UTF16Data) +#define _UTF16LEData U_ICU_ENTRY_POINT_RENAME(_UTF16LEData) +#define _UTF32BEData U_ICU_ENTRY_POINT_RENAME(_UTF32BEData) +#define _UTF32Data U_ICU_ENTRY_POINT_RENAME(_UTF32Data) +#define _UTF32LEData U_ICU_ENTRY_POINT_RENAME(_UTF32LEData) +#define _UTF7Data U_ICU_ENTRY_POINT_RENAME(_UTF7Data) +#define _UTF8Data U_ICU_ENTRY_POINT_RENAME(_UTF8Data) +#define bms_close U_ICU_ENTRY_POINT_RENAME(bms_close) +#define bms_empty U_ICU_ENTRY_POINT_RENAME(bms_empty) +#define bms_getData U_ICU_ENTRY_POINT_RENAME(bms_getData) +#define bms_open U_ICU_ENTRY_POINT_RENAME(bms_open) +#define bms_search U_ICU_ENTRY_POINT_RENAME(bms_search) +#define bms_setTargetString U_ICU_ENTRY_POINT_RENAME(bms_setTargetString) +#define buildWSConfusableData U_ICU_ENTRY_POINT_RENAME(buildWSConfusableData) +#define cmemory_cleanup U_ICU_ENTRY_POINT_RENAME(cmemory_cleanup) +#define cmemory_inUse U_ICU_ENTRY_POINT_RENAME(cmemory_inUse) +#define d2utable U_ICU_ENTRY_POINT_RENAME(d2utable) +#define deleteCEList U_ICU_ENTRY_POINT_RENAME(deleteCEList) +#define deleteChars U_ICU_ENTRY_POINT_RENAME(deleteChars) +#define deleteCollDataCacheEntry U_ICU_ENTRY_POINT_RENAME(deleteCollDataCacheEntry) +#define deleteStringList U_ICU_ENTRY_POINT_RENAME(deleteStringList) +#define deleteUnicodeStringKey U_ICU_ENTRY_POINT_RENAME(deleteUnicodeStringKey) +#define izrule_clone U_ICU_ENTRY_POINT_RENAME(izrule_clone) +#define izrule_close U_ICU_ENTRY_POINT_RENAME(izrule_close) +#define izrule_equals U_ICU_ENTRY_POINT_RENAME(izrule_equals) +#define izrule_getDSTSavings U_ICU_ENTRY_POINT_RENAME(izrule_getDSTSavings) +#define izrule_getDynamicClassID U_ICU_ENTRY_POINT_RENAME(izrule_getDynamicClassID) +#define izrule_getFinalStart U_ICU_ENTRY_POINT_RENAME(izrule_getFinalStart) +#define izrule_getFirstStart U_ICU_ENTRY_POINT_RENAME(izrule_getFirstStart) +#define izrule_getName U_ICU_ENTRY_POINT_RENAME(izrule_getName) +#define izrule_getNextStart U_ICU_ENTRY_POINT_RENAME(izrule_getNextStart) +#define izrule_getPreviousStart U_ICU_ENTRY_POINT_RENAME(izrule_getPreviousStart) +#define izrule_getRawOffset U_ICU_ENTRY_POINT_RENAME(izrule_getRawOffset) +#define izrule_getStaticClassID U_ICU_ENTRY_POINT_RENAME(izrule_getStaticClassID) +#define izrule_isEquivalentTo U_ICU_ENTRY_POINT_RENAME(izrule_isEquivalentTo) +#define izrule_open U_ICU_ENTRY_POINT_RENAME(izrule_open) +#define le_close U_ICU_ENTRY_POINT_RENAME(le_close) +#define le_create U_ICU_ENTRY_POINT_RENAME(le_create) +#define le_getCharIndices U_ICU_ENTRY_POINT_RENAME(le_getCharIndices) +#define le_getCharIndicesWithBase U_ICU_ENTRY_POINT_RENAME(le_getCharIndicesWithBase) +#define le_getGlyphCount U_ICU_ENTRY_POINT_RENAME(le_getGlyphCount) +#define le_getGlyphPosition U_ICU_ENTRY_POINT_RENAME(le_getGlyphPosition) +#define le_getGlyphPositions U_ICU_ENTRY_POINT_RENAME(le_getGlyphPositions) +#define le_getGlyphs U_ICU_ENTRY_POINT_RENAME(le_getGlyphs) +#define le_layoutChars U_ICU_ENTRY_POINT_RENAME(le_layoutChars) +#define le_reset U_ICU_ENTRY_POINT_RENAME(le_reset) +#define locale_getKeywords U_ICU_ENTRY_POINT_RENAME(locale_getKeywords) +#define locale_getKeywordsStart U_ICU_ENTRY_POINT_RENAME(locale_getKeywordsStart) +#define locale_get_default U_ICU_ENTRY_POINT_RENAME(locale_get_default) +#define locale_set_default U_ICU_ENTRY_POINT_RENAME(locale_set_default) +#define pl_addFontRun U_ICU_ENTRY_POINT_RENAME(pl_addFontRun) +#define pl_addLocaleRun U_ICU_ENTRY_POINT_RENAME(pl_addLocaleRun) +#define pl_addValueRun U_ICU_ENTRY_POINT_RENAME(pl_addValueRun) +#define pl_close U_ICU_ENTRY_POINT_RENAME(pl_close) +#define pl_closeFontRuns U_ICU_ENTRY_POINT_RENAME(pl_closeFontRuns) +#define pl_closeLine U_ICU_ENTRY_POINT_RENAME(pl_closeLine) +#define pl_closeLocaleRuns U_ICU_ENTRY_POINT_RENAME(pl_closeLocaleRuns) +#define pl_closeValueRuns U_ICU_ENTRY_POINT_RENAME(pl_closeValueRuns) +#define pl_countLineRuns U_ICU_ENTRY_POINT_RENAME(pl_countLineRuns) +#define pl_create U_ICU_ENTRY_POINT_RENAME(pl_create) +#define pl_getAscent U_ICU_ENTRY_POINT_RENAME(pl_getAscent) +#define pl_getDescent U_ICU_ENTRY_POINT_RENAME(pl_getDescent) +#define pl_getFontRunCount U_ICU_ENTRY_POINT_RENAME(pl_getFontRunCount) +#define pl_getFontRunFont U_ICU_ENTRY_POINT_RENAME(pl_getFontRunFont) +#define pl_getFontRunLastLimit U_ICU_ENTRY_POINT_RENAME(pl_getFontRunLastLimit) +#define pl_getFontRunLimit U_ICU_ENTRY_POINT_RENAME(pl_getFontRunLimit) +#define pl_getLeading U_ICU_ENTRY_POINT_RENAME(pl_getLeading) +#define pl_getLineAscent U_ICU_ENTRY_POINT_RENAME(pl_getLineAscent) +#define pl_getLineDescent U_ICU_ENTRY_POINT_RENAME(pl_getLineDescent) +#define pl_getLineLeading U_ICU_ENTRY_POINT_RENAME(pl_getLineLeading) +#define pl_getLineVisualRun U_ICU_ENTRY_POINT_RENAME(pl_getLineVisualRun) +#define pl_getLineWidth U_ICU_ENTRY_POINT_RENAME(pl_getLineWidth) +#define pl_getLocaleRunCount U_ICU_ENTRY_POINT_RENAME(pl_getLocaleRunCount) +#define pl_getLocaleRunLastLimit U_ICU_ENTRY_POINT_RENAME(pl_getLocaleRunLastLimit) +#define pl_getLocaleRunLimit U_ICU_ENTRY_POINT_RENAME(pl_getLocaleRunLimit) +#define pl_getLocaleRunLocale U_ICU_ENTRY_POINT_RENAME(pl_getLocaleRunLocale) +#define pl_getParagraphLevel U_ICU_ENTRY_POINT_RENAME(pl_getParagraphLevel) +#define pl_getTextDirection U_ICU_ENTRY_POINT_RENAME(pl_getTextDirection) +#define pl_getValueRunCount U_ICU_ENTRY_POINT_RENAME(pl_getValueRunCount) +#define pl_getValueRunLastLimit U_ICU_ENTRY_POINT_RENAME(pl_getValueRunLastLimit) +#define pl_getValueRunLimit U_ICU_ENTRY_POINT_RENAME(pl_getValueRunLimit) +#define pl_getValueRunValue U_ICU_ENTRY_POINT_RENAME(pl_getValueRunValue) +#define pl_getVisualRunAscent U_ICU_ENTRY_POINT_RENAME(pl_getVisualRunAscent) +#define pl_getVisualRunDescent U_ICU_ENTRY_POINT_RENAME(pl_getVisualRunDescent) +#define pl_getVisualRunDirection U_ICU_ENTRY_POINT_RENAME(pl_getVisualRunDirection) +#define pl_getVisualRunFont U_ICU_ENTRY_POINT_RENAME(pl_getVisualRunFont) +#define pl_getVisualRunGlyphCount U_ICU_ENTRY_POINT_RENAME(pl_getVisualRunGlyphCount) +#define pl_getVisualRunGlyphToCharMap U_ICU_ENTRY_POINT_RENAME(pl_getVisualRunGlyphToCharMap) +#define pl_getVisualRunGlyphs U_ICU_ENTRY_POINT_RENAME(pl_getVisualRunGlyphs) +#define pl_getVisualRunLeading U_ICU_ENTRY_POINT_RENAME(pl_getVisualRunLeading) +#define pl_getVisualRunPositions U_ICU_ENTRY_POINT_RENAME(pl_getVisualRunPositions) +#define pl_isComplex U_ICU_ENTRY_POINT_RENAME(pl_isComplex) +#define pl_nextLine U_ICU_ENTRY_POINT_RENAME(pl_nextLine) +#define pl_openEmptyFontRuns U_ICU_ENTRY_POINT_RENAME(pl_openEmptyFontRuns) +#define pl_openEmptyLocaleRuns U_ICU_ENTRY_POINT_RENAME(pl_openEmptyLocaleRuns) +#define pl_openEmptyValueRuns U_ICU_ENTRY_POINT_RENAME(pl_openEmptyValueRuns) +#define pl_openFontRuns U_ICU_ENTRY_POINT_RENAME(pl_openFontRuns) +#define pl_openLocaleRuns U_ICU_ENTRY_POINT_RENAME(pl_openLocaleRuns) +#define pl_openValueRuns U_ICU_ENTRY_POINT_RENAME(pl_openValueRuns) +#define pl_reflow U_ICU_ENTRY_POINT_RENAME(pl_reflow) +#define pl_resetFontRuns U_ICU_ENTRY_POINT_RENAME(pl_resetFontRuns) +#define pl_resetLocaleRuns U_ICU_ENTRY_POINT_RENAME(pl_resetLocaleRuns) +#define pl_resetValueRuns U_ICU_ENTRY_POINT_RENAME(pl_resetValueRuns) +#define res_countArrayItems U_ICU_ENTRY_POINT_RENAME(res_countArrayItems) +#define res_findResource U_ICU_ENTRY_POINT_RENAME(res_findResource) +#define res_getAlias U_ICU_ENTRY_POINT_RENAME(res_getAlias) +#define res_getArrayItem U_ICU_ENTRY_POINT_RENAME(res_getArrayItem) +#define res_getBinary U_ICU_ENTRY_POINT_RENAME(res_getBinary) +#define res_getIntVector U_ICU_ENTRY_POINT_RENAME(res_getIntVector) +#define res_getPublicType U_ICU_ENTRY_POINT_RENAME(res_getPublicType) +#define res_getResource U_ICU_ENTRY_POINT_RENAME(res_getResource) +#define res_getString U_ICU_ENTRY_POINT_RENAME(res_getString) +#define res_getTableItemByIndex U_ICU_ENTRY_POINT_RENAME(res_getTableItemByIndex) +#define res_getTableItemByKey U_ICU_ENTRY_POINT_RENAME(res_getTableItemByKey) +#define res_load U_ICU_ENTRY_POINT_RENAME(res_load) +#define res_read U_ICU_ENTRY_POINT_RENAME(res_read) +#define res_unload U_ICU_ENTRY_POINT_RENAME(res_unload) +#define tmutfmtHashTableValueComparator U_ICU_ENTRY_POINT_RENAME(tmutfmtHashTableValueComparator) +#define triedict_swap U_ICU_ENTRY_POINT_RENAME(triedict_swap) +#define u_UCharsToChars U_ICU_ENTRY_POINT_RENAME(u_UCharsToChars) +#define u_austrcpy U_ICU_ENTRY_POINT_RENAME(u_austrcpy) +#define u_austrncpy U_ICU_ENTRY_POINT_RENAME(u_austrncpy) +#define u_catclose U_ICU_ENTRY_POINT_RENAME(u_catclose) +#define u_catgets U_ICU_ENTRY_POINT_RENAME(u_catgets) +#define u_catopen U_ICU_ENTRY_POINT_RENAME(u_catopen) +#define u_charAge U_ICU_ENTRY_POINT_RENAME(u_charAge) +#define u_charDigitValue U_ICU_ENTRY_POINT_RENAME(u_charDigitValue) +#define u_charDirection U_ICU_ENTRY_POINT_RENAME(u_charDirection) +#define u_charFromName U_ICU_ENTRY_POINT_RENAME(u_charFromName) +#define u_charMirror U_ICU_ENTRY_POINT_RENAME(u_charMirror) +#define u_charName U_ICU_ENTRY_POINT_RENAME(u_charName) +#define u_charType U_ICU_ENTRY_POINT_RENAME(u_charType) +#define u_charsToUChars U_ICU_ENTRY_POINT_RENAME(u_charsToUChars) +#define u_cleanup U_ICU_ENTRY_POINT_RENAME(u_cleanup) +#define u_countChar32 U_ICU_ENTRY_POINT_RENAME(u_countChar32) +#define u_digit U_ICU_ENTRY_POINT_RENAME(u_digit) +#define u_enumCharNames U_ICU_ENTRY_POINT_RENAME(u_enumCharNames) +#define u_enumCharTypes U_ICU_ENTRY_POINT_RENAME(u_enumCharTypes) +#define u_errorName U_ICU_ENTRY_POINT_RENAME(u_errorName) +#define u_fadopt U_ICU_ENTRY_POINT_RENAME(u_fadopt) +#define u_fclose U_ICU_ENTRY_POINT_RENAME(u_fclose) +#define u_feof U_ICU_ENTRY_POINT_RENAME(u_feof) +#define u_fflush U_ICU_ENTRY_POINT_RENAME(u_fflush) +#define u_fgetConverter U_ICU_ENTRY_POINT_RENAME(u_fgetConverter) +#define u_fgetc U_ICU_ENTRY_POINT_RENAME(u_fgetc) +#define u_fgetcodepage U_ICU_ENTRY_POINT_RENAME(u_fgetcodepage) +#define u_fgetcx U_ICU_ENTRY_POINT_RENAME(u_fgetcx) +#define u_fgetfile U_ICU_ENTRY_POINT_RENAME(u_fgetfile) +#define u_fgetlocale U_ICU_ENTRY_POINT_RENAME(u_fgetlocale) +#define u_fgets U_ICU_ENTRY_POINT_RENAME(u_fgets) +#define u_file_read U_ICU_ENTRY_POINT_RENAME(u_file_read) +#define u_file_write U_ICU_ENTRY_POINT_RENAME(u_file_write) +#define u_file_write_flush U_ICU_ENTRY_POINT_RENAME(u_file_write_flush) +#define u_finit U_ICU_ENTRY_POINT_RENAME(u_finit) +#define u_flushDefaultConverter U_ICU_ENTRY_POINT_RENAME(u_flushDefaultConverter) +#define u_foldCase U_ICU_ENTRY_POINT_RENAME(u_foldCase) +#define u_fopen U_ICU_ENTRY_POINT_RENAME(u_fopen) +#define u_forDigit U_ICU_ENTRY_POINT_RENAME(u_forDigit) +#define u_formatMessage U_ICU_ENTRY_POINT_RENAME(u_formatMessage) +#define u_formatMessageWithError U_ICU_ENTRY_POINT_RENAME(u_formatMessageWithError) +#define u_fprintf U_ICU_ENTRY_POINT_RENAME(u_fprintf) +#define u_fprintf_u U_ICU_ENTRY_POINT_RENAME(u_fprintf_u) +#define u_fputc U_ICU_ENTRY_POINT_RENAME(u_fputc) +#define u_fputs U_ICU_ENTRY_POINT_RENAME(u_fputs) +#define u_frewind U_ICU_ENTRY_POINT_RENAME(u_frewind) +#define u_fscanf U_ICU_ENTRY_POINT_RENAME(u_fscanf) +#define u_fscanf_u U_ICU_ENTRY_POINT_RENAME(u_fscanf_u) +#define u_fsetcodepage U_ICU_ENTRY_POINT_RENAME(u_fsetcodepage) +#define u_fsetlocale U_ICU_ENTRY_POINT_RENAME(u_fsetlocale) +#define u_fsettransliterator U_ICU_ENTRY_POINT_RENAME(u_fsettransliterator) +#define u_fstropen U_ICU_ENTRY_POINT_RENAME(u_fstropen) +#define u_fungetc U_ICU_ENTRY_POINT_RENAME(u_fungetc) +#define u_getCombiningClass U_ICU_ENTRY_POINT_RENAME(u_getCombiningClass) +#define u_getDataDirectory U_ICU_ENTRY_POINT_RENAME(u_getDataDirectory) +#define u_getDataVersion U_ICU_ENTRY_POINT_RENAME(u_getDataVersion) +#define u_getDefaultConverter U_ICU_ENTRY_POINT_RENAME(u_getDefaultConverter) +#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_getIntPropertyMaxValue U_ICU_ENTRY_POINT_RENAME(u_getIntPropertyMaxValue) +#define u_getIntPropertyMinValue U_ICU_ENTRY_POINT_RENAME(u_getIntPropertyMinValue) +#define u_getIntPropertyValue U_ICU_ENTRY_POINT_RENAME(u_getIntPropertyValue) +#define u_getNumericValue U_ICU_ENTRY_POINT_RENAME(u_getNumericValue) +#define u_getPropertyEnum U_ICU_ENTRY_POINT_RENAME(u_getPropertyEnum) +#define u_getPropertyName U_ICU_ENTRY_POINT_RENAME(u_getPropertyName) +#define u_getPropertyValueEnum U_ICU_ENTRY_POINT_RENAME(u_getPropertyValueEnum) +#define u_getPropertyValueName U_ICU_ENTRY_POINT_RENAME(u_getPropertyValueName) +#define u_getUnicodeProperties U_ICU_ENTRY_POINT_RENAME(u_getUnicodeProperties) +#define u_getUnicodeVersion U_ICU_ENTRY_POINT_RENAME(u_getUnicodeVersion) +#define u_getVersion U_ICU_ENTRY_POINT_RENAME(u_getVersion) +#define u_hasBinaryProperty U_ICU_ENTRY_POINT_RENAME(u_hasBinaryProperty) +#define u_init U_ICU_ENTRY_POINT_RENAME(u_init) +#define u_isDataOlder U_ICU_ENTRY_POINT_RENAME(u_isDataOlder) +#define u_isIDIgnorable U_ICU_ENTRY_POINT_RENAME(u_isIDIgnorable) +#define u_isIDPart U_ICU_ENTRY_POINT_RENAME(u_isIDPart) +#define u_isIDStart U_ICU_ENTRY_POINT_RENAME(u_isIDStart) +#define u_isISOControl U_ICU_ENTRY_POINT_RENAME(u_isISOControl) +#define u_isJavaIDPart U_ICU_ENTRY_POINT_RENAME(u_isJavaIDPart) +#define u_isJavaIDStart U_ICU_ENTRY_POINT_RENAME(u_isJavaIDStart) +#define u_isJavaSpaceChar U_ICU_ENTRY_POINT_RENAME(u_isJavaSpaceChar) +#define u_isMirrored U_ICU_ENTRY_POINT_RENAME(u_isMirrored) +#define u_isUAlphabetic U_ICU_ENTRY_POINT_RENAME(u_isUAlphabetic) +#define u_isULowercase U_ICU_ENTRY_POINT_RENAME(u_isULowercase) +#define u_isUUppercase U_ICU_ENTRY_POINT_RENAME(u_isUUppercase) +#define u_isUWhiteSpace U_ICU_ENTRY_POINT_RENAME(u_isUWhiteSpace) +#define u_isWhitespace U_ICU_ENTRY_POINT_RENAME(u_isWhitespace) +#define u_isalnum U_ICU_ENTRY_POINT_RENAME(u_isalnum) +#define u_isalnumPOSIX U_ICU_ENTRY_POINT_RENAME(u_isalnumPOSIX) +#define u_isalpha U_ICU_ENTRY_POINT_RENAME(u_isalpha) +#define u_isbase U_ICU_ENTRY_POINT_RENAME(u_isbase) +#define u_isblank U_ICU_ENTRY_POINT_RENAME(u_isblank) +#define u_iscntrl U_ICU_ENTRY_POINT_RENAME(u_iscntrl) +#define u_isdefined U_ICU_ENTRY_POINT_RENAME(u_isdefined) +#define u_isdigit U_ICU_ENTRY_POINT_RENAME(u_isdigit) +#define u_isgraph U_ICU_ENTRY_POINT_RENAME(u_isgraph) +#define u_isgraphPOSIX U_ICU_ENTRY_POINT_RENAME(u_isgraphPOSIX) +#define u_islower U_ICU_ENTRY_POINT_RENAME(u_islower) +#define u_isprint U_ICU_ENTRY_POINT_RENAME(u_isprint) +#define u_isprintPOSIX U_ICU_ENTRY_POINT_RENAME(u_isprintPOSIX) +#define u_ispunct U_ICU_ENTRY_POINT_RENAME(u_ispunct) +#define u_isspace U_ICU_ENTRY_POINT_RENAME(u_isspace) +#define u_istitle U_ICU_ENTRY_POINT_RENAME(u_istitle) +#define u_isupper U_ICU_ENTRY_POINT_RENAME(u_isupper) +#define u_isxdigit U_ICU_ENTRY_POINT_RENAME(u_isxdigit) +#define u_lengthOfIdenticalLevelRun U_ICU_ENTRY_POINT_RENAME(u_lengthOfIdenticalLevelRun) +#define u_locbund_close U_ICU_ENTRY_POINT_RENAME(u_locbund_close) +#define u_locbund_getNumberFormat U_ICU_ENTRY_POINT_RENAME(u_locbund_getNumberFormat) +#define u_locbund_init U_ICU_ENTRY_POINT_RENAME(u_locbund_init) +#define u_memcasecmp U_ICU_ENTRY_POINT_RENAME(u_memcasecmp) +#define u_memchr U_ICU_ENTRY_POINT_RENAME(u_memchr) +#define u_memchr32 U_ICU_ENTRY_POINT_RENAME(u_memchr32) +#define u_memcmp U_ICU_ENTRY_POINT_RENAME(u_memcmp) +#define u_memcmpCodePointOrder U_ICU_ENTRY_POINT_RENAME(u_memcmpCodePointOrder) +#define u_memcpy U_ICU_ENTRY_POINT_RENAME(u_memcpy) +#define u_memmove U_ICU_ENTRY_POINT_RENAME(u_memmove) +#define u_memrchr U_ICU_ENTRY_POINT_RENAME(u_memrchr) +#define u_memrchr32 U_ICU_ENTRY_POINT_RENAME(u_memrchr32) +#define u_memset U_ICU_ENTRY_POINT_RENAME(u_memset) +#define u_parseMessage U_ICU_ENTRY_POINT_RENAME(u_parseMessage) +#define u_parseMessageWithError U_ICU_ENTRY_POINT_RENAME(u_parseMessageWithError) +#define u_printf_parse U_ICU_ENTRY_POINT_RENAME(u_printf_parse) +#define u_releaseDefaultConverter U_ICU_ENTRY_POINT_RENAME(u_releaseDefaultConverter) +#define u_scanf_parse U_ICU_ENTRY_POINT_RENAME(u_scanf_parse) +#define u_setAtomicIncDecFunctions U_ICU_ENTRY_POINT_RENAME(u_setAtomicIncDecFunctions) +#define u_setDataDirectory U_ICU_ENTRY_POINT_RENAME(u_setDataDirectory) +#define u_setMemoryFunctions U_ICU_ENTRY_POINT_RENAME(u_setMemoryFunctions) +#define u_setMutexFunctions U_ICU_ENTRY_POINT_RENAME(u_setMutexFunctions) +#define u_shapeArabic U_ICU_ENTRY_POINT_RENAME(u_shapeArabic) +#define u_snprintf U_ICU_ENTRY_POINT_RENAME(u_snprintf) +#define u_snprintf_u U_ICU_ENTRY_POINT_RENAME(u_snprintf_u) +#define u_sprintf U_ICU_ENTRY_POINT_RENAME(u_sprintf) +#define u_sprintf_u U_ICU_ENTRY_POINT_RENAME(u_sprintf_u) +#define u_sscanf U_ICU_ENTRY_POINT_RENAME(u_sscanf) +#define u_sscanf_u U_ICU_ENTRY_POINT_RENAME(u_sscanf_u) +#define u_strCaseCompare U_ICU_ENTRY_POINT_RENAME(u_strCaseCompare) +#define u_strCompare U_ICU_ENTRY_POINT_RENAME(u_strCompare) +#define u_strCompareIter U_ICU_ENTRY_POINT_RENAME(u_strCompareIter) +#define u_strFindFirst U_ICU_ENTRY_POINT_RENAME(u_strFindFirst) +#define u_strFindLast U_ICU_ENTRY_POINT_RENAME(u_strFindLast) +#define u_strFoldCase U_ICU_ENTRY_POINT_RENAME(u_strFoldCase) +#define u_strFromJavaModifiedUTF8WithSub U_ICU_ENTRY_POINT_RENAME(u_strFromJavaModifiedUTF8WithSub) +#define u_strFromPunycode U_ICU_ENTRY_POINT_RENAME(u_strFromPunycode) +#define u_strFromUTF32 U_ICU_ENTRY_POINT_RENAME(u_strFromUTF32) +#define u_strFromUTF32WithSub U_ICU_ENTRY_POINT_RENAME(u_strFromUTF32WithSub) +#define u_strFromUTF8 U_ICU_ENTRY_POINT_RENAME(u_strFromUTF8) +#define u_strFromUTF8Lenient U_ICU_ENTRY_POINT_RENAME(u_strFromUTF8Lenient) +#define u_strFromUTF8WithSub U_ICU_ENTRY_POINT_RENAME(u_strFromUTF8WithSub) +#define u_strFromWCS U_ICU_ENTRY_POINT_RENAME(u_strFromWCS) +#define u_strHasMoreChar32Than U_ICU_ENTRY_POINT_RENAME(u_strHasMoreChar32Than) +#define u_strToJavaModifiedUTF8 U_ICU_ENTRY_POINT_RENAME(u_strToJavaModifiedUTF8) +#define u_strToLower U_ICU_ENTRY_POINT_RENAME(u_strToLower) +#define u_strToPunycode U_ICU_ENTRY_POINT_RENAME(u_strToPunycode) +#define u_strToTitle U_ICU_ENTRY_POINT_RENAME(u_strToTitle) +#define u_strToUTF32 U_ICU_ENTRY_POINT_RENAME(u_strToUTF32) +#define u_strToUTF32WithSub U_ICU_ENTRY_POINT_RENAME(u_strToUTF32WithSub) +#define u_strToUTF8 U_ICU_ENTRY_POINT_RENAME(u_strToUTF8) +#define u_strToUTF8WithSub U_ICU_ENTRY_POINT_RENAME(u_strToUTF8WithSub) +#define u_strToUpper U_ICU_ENTRY_POINT_RENAME(u_strToUpper) +#define u_strToWCS U_ICU_ENTRY_POINT_RENAME(u_strToWCS) +#define u_strcasecmp U_ICU_ENTRY_POINT_RENAME(u_strcasecmp) +#define u_strcat U_ICU_ENTRY_POINT_RENAME(u_strcat) +#define u_strchr U_ICU_ENTRY_POINT_RENAME(u_strchr) +#define u_strchr32 U_ICU_ENTRY_POINT_RENAME(u_strchr32) +#define u_strcmp U_ICU_ENTRY_POINT_RENAME(u_strcmp) +#define u_strcmpCodePointOrder U_ICU_ENTRY_POINT_RENAME(u_strcmpCodePointOrder) +#define u_strcmpFold U_ICU_ENTRY_POINT_RENAME(u_strcmpFold) +#define u_strcpy U_ICU_ENTRY_POINT_RENAME(u_strcpy) +#define u_strcspn U_ICU_ENTRY_POINT_RENAME(u_strcspn) +#define u_strlen U_ICU_ENTRY_POINT_RENAME(u_strlen) +#define u_strncasecmp U_ICU_ENTRY_POINT_RENAME(u_strncasecmp) +#define u_strncat U_ICU_ENTRY_POINT_RENAME(u_strncat) +#define u_strncmp U_ICU_ENTRY_POINT_RENAME(u_strncmp) +#define u_strncmpCodePointOrder U_ICU_ENTRY_POINT_RENAME(u_strncmpCodePointOrder) +#define u_strncpy U_ICU_ENTRY_POINT_RENAME(u_strncpy) +#define u_strpbrk U_ICU_ENTRY_POINT_RENAME(u_strpbrk) +#define u_strrchr U_ICU_ENTRY_POINT_RENAME(u_strrchr) +#define u_strrchr32 U_ICU_ENTRY_POINT_RENAME(u_strrchr32) +#define u_strrstr U_ICU_ENTRY_POINT_RENAME(u_strrstr) +#define u_strspn U_ICU_ENTRY_POINT_RENAME(u_strspn) +#define u_strstr U_ICU_ENTRY_POINT_RENAME(u_strstr) +#define u_strtok_r U_ICU_ENTRY_POINT_RENAME(u_strtok_r) +#define u_terminateChars U_ICU_ENTRY_POINT_RENAME(u_terminateChars) +#define u_terminateUChar32s U_ICU_ENTRY_POINT_RENAME(u_terminateUChar32s) +#define u_terminateUChars U_ICU_ENTRY_POINT_RENAME(u_terminateUChars) +#define u_terminateWChars U_ICU_ENTRY_POINT_RENAME(u_terminateWChars) +#define u_tolower U_ICU_ENTRY_POINT_RENAME(u_tolower) +#define u_totitle U_ICU_ENTRY_POINT_RENAME(u_totitle) +#define u_toupper U_ICU_ENTRY_POINT_RENAME(u_toupper) +#define u_uastrcpy U_ICU_ENTRY_POINT_RENAME(u_uastrcpy) +#define u_uastrncpy U_ICU_ENTRY_POINT_RENAME(u_uastrncpy) +#define u_unescape U_ICU_ENTRY_POINT_RENAME(u_unescape) +#define u_unescapeAt U_ICU_ENTRY_POINT_RENAME(u_unescapeAt) +#define u_versionFromString U_ICU_ENTRY_POINT_RENAME(u_versionFromString) +#define u_versionFromUString U_ICU_ENTRY_POINT_RENAME(u_versionFromUString) +#define u_versionToString U_ICU_ENTRY_POINT_RENAME(u_versionToString) +#define u_vformatMessage U_ICU_ENTRY_POINT_RENAME(u_vformatMessage) +#define u_vformatMessageWithError U_ICU_ENTRY_POINT_RENAME(u_vformatMessageWithError) +#define u_vfprintf U_ICU_ENTRY_POINT_RENAME(u_vfprintf) +#define u_vfprintf_u U_ICU_ENTRY_POINT_RENAME(u_vfprintf_u) +#define u_vfscanf U_ICU_ENTRY_POINT_RENAME(u_vfscanf) +#define u_vfscanf_u U_ICU_ENTRY_POINT_RENAME(u_vfscanf_u) +#define u_vparseMessage U_ICU_ENTRY_POINT_RENAME(u_vparseMessage) +#define u_vparseMessageWithError U_ICU_ENTRY_POINT_RENAME(u_vparseMessageWithError) +#define u_vsnprintf U_ICU_ENTRY_POINT_RENAME(u_vsnprintf) +#define u_vsnprintf_u U_ICU_ENTRY_POINT_RENAME(u_vsnprintf_u) +#define u_vsprintf U_ICU_ENTRY_POINT_RENAME(u_vsprintf) +#define u_vsprintf_u U_ICU_ENTRY_POINT_RENAME(u_vsprintf_u) +#define u_vsscanf U_ICU_ENTRY_POINT_RENAME(u_vsscanf) +#define u_vsscanf_u U_ICU_ENTRY_POINT_RENAME(u_vsscanf_u) +#define u_writeDiff U_ICU_ENTRY_POINT_RENAME(u_writeDiff) +#define u_writeIdenticalLevelRun U_ICU_ENTRY_POINT_RENAME(u_writeIdenticalLevelRun) +#define u_writeIdenticalLevelRunTwoChars U_ICU_ENTRY_POINT_RENAME(u_writeIdenticalLevelRunTwoChars) +#define ubidi_addPropertyStarts U_ICU_ENTRY_POINT_RENAME(ubidi_addPropertyStarts) +#define ubidi_close U_ICU_ENTRY_POINT_RENAME(ubidi_close) +#define ubidi_countParagraphs U_ICU_ENTRY_POINT_RENAME(ubidi_countParagraphs) +#define ubidi_countRuns U_ICU_ENTRY_POINT_RENAME(ubidi_countRuns) +#define ubidi_getBaseDirection U_ICU_ENTRY_POINT_RENAME(ubidi_getBaseDirection) +#define ubidi_getClass U_ICU_ENTRY_POINT_RENAME(ubidi_getClass) +#define ubidi_getClassCallback U_ICU_ENTRY_POINT_RENAME(ubidi_getClassCallback) +#define ubidi_getCustomizedClass U_ICU_ENTRY_POINT_RENAME(ubidi_getCustomizedClass) +#define ubidi_getDirection U_ICU_ENTRY_POINT_RENAME(ubidi_getDirection) +#define ubidi_getJoiningGroup U_ICU_ENTRY_POINT_RENAME(ubidi_getJoiningGroup) +#define ubidi_getJoiningType U_ICU_ENTRY_POINT_RENAME(ubidi_getJoiningType) +#define ubidi_getLength U_ICU_ENTRY_POINT_RENAME(ubidi_getLength) +#define ubidi_getLevelAt U_ICU_ENTRY_POINT_RENAME(ubidi_getLevelAt) +#define ubidi_getLevels U_ICU_ENTRY_POINT_RENAME(ubidi_getLevels) +#define ubidi_getLogicalIndex U_ICU_ENTRY_POINT_RENAME(ubidi_getLogicalIndex) +#define ubidi_getLogicalMap U_ICU_ENTRY_POINT_RENAME(ubidi_getLogicalMap) +#define ubidi_getLogicalRun U_ICU_ENTRY_POINT_RENAME(ubidi_getLogicalRun) +#define ubidi_getMaxValue U_ICU_ENTRY_POINT_RENAME(ubidi_getMaxValue) +#define ubidi_getMemory U_ICU_ENTRY_POINT_RENAME(ubidi_getMemory) +#define ubidi_getMirror U_ICU_ENTRY_POINT_RENAME(ubidi_getMirror) +#define ubidi_getParaLevel U_ICU_ENTRY_POINT_RENAME(ubidi_getParaLevel) +#define ubidi_getParagraph U_ICU_ENTRY_POINT_RENAME(ubidi_getParagraph) +#define ubidi_getParagraphByIndex U_ICU_ENTRY_POINT_RENAME(ubidi_getParagraphByIndex) +#define ubidi_getProcessedLength U_ICU_ENTRY_POINT_RENAME(ubidi_getProcessedLength) +#define ubidi_getReorderingMode U_ICU_ENTRY_POINT_RENAME(ubidi_getReorderingMode) +#define ubidi_getReorderingOptions U_ICU_ENTRY_POINT_RENAME(ubidi_getReorderingOptions) +#define ubidi_getResultLength U_ICU_ENTRY_POINT_RENAME(ubidi_getResultLength) +#define ubidi_getRuns U_ICU_ENTRY_POINT_RENAME(ubidi_getRuns) +#define ubidi_getSingleton U_ICU_ENTRY_POINT_RENAME(ubidi_getSingleton) +#define ubidi_getText U_ICU_ENTRY_POINT_RENAME(ubidi_getText) +#define ubidi_getVisualIndex U_ICU_ENTRY_POINT_RENAME(ubidi_getVisualIndex) +#define ubidi_getVisualMap U_ICU_ENTRY_POINT_RENAME(ubidi_getVisualMap) +#define ubidi_getVisualRun U_ICU_ENTRY_POINT_RENAME(ubidi_getVisualRun) +#define ubidi_invertMap U_ICU_ENTRY_POINT_RENAME(ubidi_invertMap) +#define ubidi_isBidiControl U_ICU_ENTRY_POINT_RENAME(ubidi_isBidiControl) +#define ubidi_isInverse U_ICU_ENTRY_POINT_RENAME(ubidi_isInverse) +#define ubidi_isJoinControl U_ICU_ENTRY_POINT_RENAME(ubidi_isJoinControl) +#define ubidi_isMirrored U_ICU_ENTRY_POINT_RENAME(ubidi_isMirrored) +#define ubidi_isOrderParagraphsLTR U_ICU_ENTRY_POINT_RENAME(ubidi_isOrderParagraphsLTR) +#define ubidi_open U_ICU_ENTRY_POINT_RENAME(ubidi_open) +#define ubidi_openSized U_ICU_ENTRY_POINT_RENAME(ubidi_openSized) +#define ubidi_orderParagraphsLTR U_ICU_ENTRY_POINT_RENAME(ubidi_orderParagraphsLTR) +#define ubidi_reorderLogical U_ICU_ENTRY_POINT_RENAME(ubidi_reorderLogical) +#define ubidi_reorderVisual U_ICU_ENTRY_POINT_RENAME(ubidi_reorderVisual) +#define ubidi_setClassCallback U_ICU_ENTRY_POINT_RENAME(ubidi_setClassCallback) +#define ubidi_setInverse U_ICU_ENTRY_POINT_RENAME(ubidi_setInverse) +#define ubidi_setLine U_ICU_ENTRY_POINT_RENAME(ubidi_setLine) +#define ubidi_setPara U_ICU_ENTRY_POINT_RENAME(ubidi_setPara) +#define ubidi_setReorderingMode U_ICU_ENTRY_POINT_RENAME(ubidi_setReorderingMode) +#define ubidi_setReorderingOptions U_ICU_ENTRY_POINT_RENAME(ubidi_setReorderingOptions) +#define ubidi_writeReordered U_ICU_ENTRY_POINT_RENAME(ubidi_writeReordered) +#define ubidi_writeReverse U_ICU_ENTRY_POINT_RENAME(ubidi_writeReverse) +#define ublock_getCode U_ICU_ENTRY_POINT_RENAME(ublock_getCode) +#define ubrk_close U_ICU_ENTRY_POINT_RENAME(ubrk_close) +#define ubrk_countAvailable U_ICU_ENTRY_POINT_RENAME(ubrk_countAvailable) +#define ubrk_current U_ICU_ENTRY_POINT_RENAME(ubrk_current) +#define ubrk_first U_ICU_ENTRY_POINT_RENAME(ubrk_first) +#define ubrk_following U_ICU_ENTRY_POINT_RENAME(ubrk_following) +#define ubrk_getAvailable U_ICU_ENTRY_POINT_RENAME(ubrk_getAvailable) +#define ubrk_getLocaleByType U_ICU_ENTRY_POINT_RENAME(ubrk_getLocaleByType) +#define ubrk_getRuleStatus U_ICU_ENTRY_POINT_RENAME(ubrk_getRuleStatus) +#define ubrk_getRuleStatusVec U_ICU_ENTRY_POINT_RENAME(ubrk_getRuleStatusVec) +#define ubrk_isBoundary U_ICU_ENTRY_POINT_RENAME(ubrk_isBoundary) +#define ubrk_last U_ICU_ENTRY_POINT_RENAME(ubrk_last) +#define ubrk_next U_ICU_ENTRY_POINT_RENAME(ubrk_next) +#define ubrk_open U_ICU_ENTRY_POINT_RENAME(ubrk_open) +#define ubrk_openRules U_ICU_ENTRY_POINT_RENAME(ubrk_openRules) +#define ubrk_preceding U_ICU_ENTRY_POINT_RENAME(ubrk_preceding) +#define ubrk_previous U_ICU_ENTRY_POINT_RENAME(ubrk_previous) +#define ubrk_safeClone U_ICU_ENTRY_POINT_RENAME(ubrk_safeClone) +#define ubrk_setText U_ICU_ENTRY_POINT_RENAME(ubrk_setText) +#define ubrk_setUText U_ICU_ENTRY_POINT_RENAME(ubrk_setUText) +#define ubrk_swap U_ICU_ENTRY_POINT_RENAME(ubrk_swap) +#define ucal_add U_ICU_ENTRY_POINT_RENAME(ucal_add) +#define ucal_clear U_ICU_ENTRY_POINT_RENAME(ucal_clear) +#define ucal_clearField U_ICU_ENTRY_POINT_RENAME(ucal_clearField) +#define ucal_clone U_ICU_ENTRY_POINT_RENAME(ucal_clone) +#define ucal_close U_ICU_ENTRY_POINT_RENAME(ucal_close) +#define ucal_countAvailable U_ICU_ENTRY_POINT_RENAME(ucal_countAvailable) +#define ucal_equivalentTo U_ICU_ENTRY_POINT_RENAME(ucal_equivalentTo) +#define ucal_get U_ICU_ENTRY_POINT_RENAME(ucal_get) +#define ucal_getAttribute U_ICU_ENTRY_POINT_RENAME(ucal_getAttribute) +#define ucal_getAvailable U_ICU_ENTRY_POINT_RENAME(ucal_getAvailable) +#define ucal_getCanonicalTimeZoneID U_ICU_ENTRY_POINT_RENAME(ucal_getCanonicalTimeZoneID) +#define ucal_getDSTSavings U_ICU_ENTRY_POINT_RENAME(ucal_getDSTSavings) +#define ucal_getDayOfWeekType U_ICU_ENTRY_POINT_RENAME(ucal_getDayOfWeekType) +#define ucal_getDefaultTimeZone U_ICU_ENTRY_POINT_RENAME(ucal_getDefaultTimeZone) +#define ucal_getGregorianChange U_ICU_ENTRY_POINT_RENAME(ucal_getGregorianChange) +#define ucal_getKeywordValuesForLocale U_ICU_ENTRY_POINT_RENAME(ucal_getKeywordValuesForLocale) +#define ucal_getLimit U_ICU_ENTRY_POINT_RENAME(ucal_getLimit) +#define ucal_getLocaleByType U_ICU_ENTRY_POINT_RENAME(ucal_getLocaleByType) +#define ucal_getMillis U_ICU_ENTRY_POINT_RENAME(ucal_getMillis) +#define ucal_getNow U_ICU_ENTRY_POINT_RENAME(ucal_getNow) +#define ucal_getTZDataVersion U_ICU_ENTRY_POINT_RENAME(ucal_getTZDataVersion) +#define ucal_getTimeZoneDisplayName U_ICU_ENTRY_POINT_RENAME(ucal_getTimeZoneDisplayName) +#define ucal_getType U_ICU_ENTRY_POINT_RENAME(ucal_getType) +#define ucal_getWeekendTransition U_ICU_ENTRY_POINT_RENAME(ucal_getWeekendTransition) +#define ucal_inDaylightTime U_ICU_ENTRY_POINT_RENAME(ucal_inDaylightTime) +#define ucal_isSet U_ICU_ENTRY_POINT_RENAME(ucal_isSet) +#define ucal_isWeekend U_ICU_ENTRY_POINT_RENAME(ucal_isWeekend) +#define ucal_open U_ICU_ENTRY_POINT_RENAME(ucal_open) +#define ucal_openCountryTimeZones U_ICU_ENTRY_POINT_RENAME(ucal_openCountryTimeZones) +#define ucal_openTimeZones U_ICU_ENTRY_POINT_RENAME(ucal_openTimeZones) +#define ucal_roll U_ICU_ENTRY_POINT_RENAME(ucal_roll) +#define ucal_set U_ICU_ENTRY_POINT_RENAME(ucal_set) +#define ucal_setAttribute U_ICU_ENTRY_POINT_RENAME(ucal_setAttribute) +#define ucal_setDate U_ICU_ENTRY_POINT_RENAME(ucal_setDate) +#define ucal_setDateTime U_ICU_ENTRY_POINT_RENAME(ucal_setDateTime) +#define ucal_setDefaultTimeZone U_ICU_ENTRY_POINT_RENAME(ucal_setDefaultTimeZone) +#define ucal_setGregorianChange U_ICU_ENTRY_POINT_RENAME(ucal_setGregorianChange) +#define ucal_setMillis U_ICU_ENTRY_POINT_RENAME(ucal_setMillis) +#define ucal_setTimeZone U_ICU_ENTRY_POINT_RENAME(ucal_setTimeZone) +#define ucase_addCaseClosure U_ICU_ENTRY_POINT_RENAME(ucase_addCaseClosure) +#define ucase_addPropertyStarts U_ICU_ENTRY_POINT_RENAME(ucase_addPropertyStarts) +#define ucase_addStringCaseClosure U_ICU_ENTRY_POINT_RENAME(ucase_addStringCaseClosure) +#define ucase_fold U_ICU_ENTRY_POINT_RENAME(ucase_fold) +#define ucase_getCaseLocale U_ICU_ENTRY_POINT_RENAME(ucase_getCaseLocale) +#define ucase_getSingleton U_ICU_ENTRY_POINT_RENAME(ucase_getSingleton) +#define ucase_getType U_ICU_ENTRY_POINT_RENAME(ucase_getType) +#define ucase_getTypeOrIgnorable U_ICU_ENTRY_POINT_RENAME(ucase_getTypeOrIgnorable) +#define ucase_hasBinaryProperty U_ICU_ENTRY_POINT_RENAME(ucase_hasBinaryProperty) +#define ucase_isCaseSensitive U_ICU_ENTRY_POINT_RENAME(ucase_isCaseSensitive) +#define ucase_isSoftDotted U_ICU_ENTRY_POINT_RENAME(ucase_isSoftDotted) +#define ucase_toFullFolding U_ICU_ENTRY_POINT_RENAME(ucase_toFullFolding) +#define ucase_toFullLower U_ICU_ENTRY_POINT_RENAME(ucase_toFullLower) +#define ucase_toFullTitle U_ICU_ENTRY_POINT_RENAME(ucase_toFullTitle) +#define ucase_toFullUpper U_ICU_ENTRY_POINT_RENAME(ucase_toFullUpper) +#define ucase_tolower U_ICU_ENTRY_POINT_RENAME(ucase_tolower) +#define ucase_totitle U_ICU_ENTRY_POINT_RENAME(ucase_totitle) +#define ucase_toupper U_ICU_ENTRY_POINT_RENAME(ucase_toupper) +#define ucasemap_close U_ICU_ENTRY_POINT_RENAME(ucasemap_close) +#define ucasemap_getBreakIterator U_ICU_ENTRY_POINT_RENAME(ucasemap_getBreakIterator) +#define ucasemap_getLocale U_ICU_ENTRY_POINT_RENAME(ucasemap_getLocale) +#define ucasemap_getOptions U_ICU_ENTRY_POINT_RENAME(ucasemap_getOptions) +#define ucasemap_open U_ICU_ENTRY_POINT_RENAME(ucasemap_open) +#define ucasemap_setBreakIterator U_ICU_ENTRY_POINT_RENAME(ucasemap_setBreakIterator) +#define ucasemap_setLocale U_ICU_ENTRY_POINT_RENAME(ucasemap_setLocale) +#define ucasemap_setOptions U_ICU_ENTRY_POINT_RENAME(ucasemap_setOptions) +#define ucasemap_toTitle U_ICU_ENTRY_POINT_RENAME(ucasemap_toTitle) +#define ucasemap_utf8FoldCase U_ICU_ENTRY_POINT_RENAME(ucasemap_utf8FoldCase) +#define ucasemap_utf8ToLower U_ICU_ENTRY_POINT_RENAME(ucasemap_utf8ToLower) +#define ucasemap_utf8ToTitle U_ICU_ENTRY_POINT_RENAME(ucasemap_utf8ToTitle) +#define ucasemap_utf8ToUpper U_ICU_ENTRY_POINT_RENAME(ucasemap_utf8ToUpper) +#define ucd_close U_ICU_ENTRY_POINT_RENAME(ucd_close) +#define ucd_flushCache U_ICU_ENTRY_POINT_RENAME(ucd_flushCache) +#define ucd_freeCache U_ICU_ENTRY_POINT_RENAME(ucd_freeCache) +#define ucd_getCollator U_ICU_ENTRY_POINT_RENAME(ucd_getCollator) +#define ucd_open U_ICU_ENTRY_POINT_RENAME(ucd_open) +#define uchar_addPropertyStarts U_ICU_ENTRY_POINT_RENAME(uchar_addPropertyStarts) +#define uchar_swapNames U_ICU_ENTRY_POINT_RENAME(uchar_swapNames) +#define ucln_cleanupOne U_ICU_ENTRY_POINT_RENAME(ucln_cleanupOne) +#define ucln_common_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_common_registerCleanup) +#define ucln_i18n_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_i18n_registerCleanup) +#define ucln_io_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_io_registerCleanup) +#define ucln_lib_cleanup U_ICU_ENTRY_POINT_RENAME(ucln_lib_cleanup) +#define ucln_registerCleanup U_ICU_ENTRY_POINT_RENAME(ucln_registerCleanup) +#define ucnv_MBCSFromUChar32 U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSFromUChar32) +#define ucnv_MBCSFromUnicodeWithOffsets U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSFromUnicodeWithOffsets) +#define ucnv_MBCSGetFilteredUnicodeSetForUnicode U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSGetFilteredUnicodeSetForUnicode) +#define ucnv_MBCSGetType U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSGetType) +#define ucnv_MBCSGetUnicodeSetForUnicode U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSGetUnicodeSetForUnicode) +#define ucnv_MBCSIsLeadByte U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSIsLeadByte) +#define ucnv_MBCSSimpleGetNextUChar U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSSimpleGetNextUChar) +#define ucnv_MBCSToUnicodeWithOffsets U_ICU_ENTRY_POINT_RENAME(ucnv_MBCSToUnicodeWithOffsets) +#define ucnv_bld_countAvailableConverters U_ICU_ENTRY_POINT_RENAME(ucnv_bld_countAvailableConverters) +#define ucnv_bld_getAvailableConverter U_ICU_ENTRY_POINT_RENAME(ucnv_bld_getAvailableConverter) +#define ucnv_canCreateConverter U_ICU_ENTRY_POINT_RENAME(ucnv_canCreateConverter) +#define ucnv_cbFromUWriteBytes U_ICU_ENTRY_POINT_RENAME(ucnv_cbFromUWriteBytes) +#define ucnv_cbFromUWriteSub U_ICU_ENTRY_POINT_RENAME(ucnv_cbFromUWriteSub) +#define ucnv_cbFromUWriteUChars U_ICU_ENTRY_POINT_RENAME(ucnv_cbFromUWriteUChars) +#define ucnv_cbToUWriteSub U_ICU_ENTRY_POINT_RENAME(ucnv_cbToUWriteSub) +#define ucnv_cbToUWriteUChars U_ICU_ENTRY_POINT_RENAME(ucnv_cbToUWriteUChars) +#define ucnv_close U_ICU_ENTRY_POINT_RENAME(ucnv_close) +#define ucnv_compareNames U_ICU_ENTRY_POINT_RENAME(ucnv_compareNames) +#define ucnv_convert U_ICU_ENTRY_POINT_RENAME(ucnv_convert) +#define ucnv_convertEx U_ICU_ENTRY_POINT_RENAME(ucnv_convertEx) +#define ucnv_countAliases U_ICU_ENTRY_POINT_RENAME(ucnv_countAliases) +#define ucnv_countAvailable U_ICU_ENTRY_POINT_RENAME(ucnv_countAvailable) +#define ucnv_countStandards U_ICU_ENTRY_POINT_RENAME(ucnv_countStandards) +#define ucnv_createAlgorithmicConverter U_ICU_ENTRY_POINT_RENAME(ucnv_createAlgorithmicConverter) +#define ucnv_createConverter U_ICU_ENTRY_POINT_RENAME(ucnv_createConverter) +#define ucnv_createConverterFromPackage U_ICU_ENTRY_POINT_RENAME(ucnv_createConverterFromPackage) +#define ucnv_createConverterFromSharedData U_ICU_ENTRY_POINT_RENAME(ucnv_createConverterFromSharedData) +#define ucnv_detectUnicodeSignature U_ICU_ENTRY_POINT_RENAME(ucnv_detectUnicodeSignature) +#define ucnv_extContinueMatchFromU U_ICU_ENTRY_POINT_RENAME(ucnv_extContinueMatchFromU) +#define ucnv_extContinueMatchToU U_ICU_ENTRY_POINT_RENAME(ucnv_extContinueMatchToU) +#define ucnv_extGetUnicodeSet U_ICU_ENTRY_POINT_RENAME(ucnv_extGetUnicodeSet) +#define ucnv_extInitialMatchFromU U_ICU_ENTRY_POINT_RENAME(ucnv_extInitialMatchFromU) +#define ucnv_extInitialMatchToU U_ICU_ENTRY_POINT_RENAME(ucnv_extInitialMatchToU) +#define ucnv_extSimpleMatchFromU U_ICU_ENTRY_POINT_RENAME(ucnv_extSimpleMatchFromU) +#define ucnv_extSimpleMatchToU U_ICU_ENTRY_POINT_RENAME(ucnv_extSimpleMatchToU) +#define ucnv_fixFileSeparator U_ICU_ENTRY_POINT_RENAME(ucnv_fixFileSeparator) +#define ucnv_flushCache U_ICU_ENTRY_POINT_RENAME(ucnv_flushCache) +#define ucnv_fromAlgorithmic U_ICU_ENTRY_POINT_RENAME(ucnv_fromAlgorithmic) +#define ucnv_fromUChars U_ICU_ENTRY_POINT_RENAME(ucnv_fromUChars) +#define ucnv_fromUCountPending U_ICU_ENTRY_POINT_RENAME(ucnv_fromUCountPending) +#define ucnv_fromUWriteBytes U_ICU_ENTRY_POINT_RENAME(ucnv_fromUWriteBytes) +#define ucnv_fromUnicode U_ICU_ENTRY_POINT_RENAME(ucnv_fromUnicode) +#define ucnv_fromUnicode_UTF8 U_ICU_ENTRY_POINT_RENAME(ucnv_fromUnicode_UTF8) +#define ucnv_fromUnicode_UTF8_OFFSETS_LOGIC U_ICU_ENTRY_POINT_RENAME(ucnv_fromUnicode_UTF8_OFFSETS_LOGIC) +#define ucnv_getAlias U_ICU_ENTRY_POINT_RENAME(ucnv_getAlias) +#define ucnv_getAliases U_ICU_ENTRY_POINT_RENAME(ucnv_getAliases) +#define ucnv_getAvailableName U_ICU_ENTRY_POINT_RENAME(ucnv_getAvailableName) +#define ucnv_getCCSID U_ICU_ENTRY_POINT_RENAME(ucnv_getCCSID) +#define ucnv_getCanonicalName U_ICU_ENTRY_POINT_RENAME(ucnv_getCanonicalName) +#define ucnv_getCompleteUnicodeSet U_ICU_ENTRY_POINT_RENAME(ucnv_getCompleteUnicodeSet) +#define ucnv_getDefaultName U_ICU_ENTRY_POINT_RENAME(ucnv_getDefaultName) +#define ucnv_getDisplayName U_ICU_ENTRY_POINT_RENAME(ucnv_getDisplayName) +#define ucnv_getFromUCallBack U_ICU_ENTRY_POINT_RENAME(ucnv_getFromUCallBack) +#define ucnv_getInvalidChars U_ICU_ENTRY_POINT_RENAME(ucnv_getInvalidChars) +#define ucnv_getInvalidUChars U_ICU_ENTRY_POINT_RENAME(ucnv_getInvalidUChars) +#define ucnv_getMaxCharSize U_ICU_ENTRY_POINT_RENAME(ucnv_getMaxCharSize) +#define ucnv_getMinCharSize U_ICU_ENTRY_POINT_RENAME(ucnv_getMinCharSize) +#define ucnv_getName U_ICU_ENTRY_POINT_RENAME(ucnv_getName) +#define ucnv_getNextUChar U_ICU_ENTRY_POINT_RENAME(ucnv_getNextUChar) +#define ucnv_getNonSurrogateUnicodeSet U_ICU_ENTRY_POINT_RENAME(ucnv_getNonSurrogateUnicodeSet) +#define ucnv_getPlatform U_ICU_ENTRY_POINT_RENAME(ucnv_getPlatform) +#define ucnv_getStandard U_ICU_ENTRY_POINT_RENAME(ucnv_getStandard) +#define ucnv_getStandardName U_ICU_ENTRY_POINT_RENAME(ucnv_getStandardName) +#define ucnv_getStarters U_ICU_ENTRY_POINT_RENAME(ucnv_getStarters) +#define ucnv_getSubstChars U_ICU_ENTRY_POINT_RENAME(ucnv_getSubstChars) +#define ucnv_getToUCallBack U_ICU_ENTRY_POINT_RENAME(ucnv_getToUCallBack) +#define ucnv_getType U_ICU_ENTRY_POINT_RENAME(ucnv_getType) +#define ucnv_getUnicodeSet U_ICU_ENTRY_POINT_RENAME(ucnv_getUnicodeSet) +#define ucnv_incrementRefCount U_ICU_ENTRY_POINT_RENAME(ucnv_incrementRefCount) +#define ucnv_io_countKnownConverters U_ICU_ENTRY_POINT_RENAME(ucnv_io_countKnownConverters) +#define ucnv_io_getConverterName U_ICU_ENTRY_POINT_RENAME(ucnv_io_getConverterName) +#define ucnv_io_stripASCIIForCompare U_ICU_ENTRY_POINT_RENAME(ucnv_io_stripASCIIForCompare) +#define ucnv_io_stripEBCDICForCompare U_ICU_ENTRY_POINT_RENAME(ucnv_io_stripEBCDICForCompare) +#define ucnv_isAmbiguous U_ICU_ENTRY_POINT_RENAME(ucnv_isAmbiguous) +#define ucnv_load U_ICU_ENTRY_POINT_RENAME(ucnv_load) +#define ucnv_loadSharedData U_ICU_ENTRY_POINT_RENAME(ucnv_loadSharedData) +#define ucnv_open U_ICU_ENTRY_POINT_RENAME(ucnv_open) +#define ucnv_openAllNames U_ICU_ENTRY_POINT_RENAME(ucnv_openAllNames) +#define ucnv_openCCSID U_ICU_ENTRY_POINT_RENAME(ucnv_openCCSID) +#define ucnv_openPackage U_ICU_ENTRY_POINT_RENAME(ucnv_openPackage) +#define ucnv_openStandardNames U_ICU_ENTRY_POINT_RENAME(ucnv_openStandardNames) +#define ucnv_openU U_ICU_ENTRY_POINT_RENAME(ucnv_openU) +#define ucnv_reset U_ICU_ENTRY_POINT_RENAME(ucnv_reset) +#define ucnv_resetFromUnicode U_ICU_ENTRY_POINT_RENAME(ucnv_resetFromUnicode) +#define ucnv_resetToUnicode U_ICU_ENTRY_POINT_RENAME(ucnv_resetToUnicode) +#define ucnv_safeClone U_ICU_ENTRY_POINT_RENAME(ucnv_safeClone) +#define ucnv_setDefaultName U_ICU_ENTRY_POINT_RENAME(ucnv_setDefaultName) +#define ucnv_setFallback U_ICU_ENTRY_POINT_RENAME(ucnv_setFallback) +#define ucnv_setFromUCallBack U_ICU_ENTRY_POINT_RENAME(ucnv_setFromUCallBack) +#define ucnv_setSubstChars U_ICU_ENTRY_POINT_RENAME(ucnv_setSubstChars) +#define ucnv_setSubstString U_ICU_ENTRY_POINT_RENAME(ucnv_setSubstString) +#define ucnv_setToUCallBack U_ICU_ENTRY_POINT_RENAME(ucnv_setToUCallBack) +#define ucnv_swap U_ICU_ENTRY_POINT_RENAME(ucnv_swap) +#define ucnv_swapAliases U_ICU_ENTRY_POINT_RENAME(ucnv_swapAliases) +#define ucnv_toAlgorithmic U_ICU_ENTRY_POINT_RENAME(ucnv_toAlgorithmic) +#define ucnv_toUChars U_ICU_ENTRY_POINT_RENAME(ucnv_toUChars) +#define ucnv_toUCountPending U_ICU_ENTRY_POINT_RENAME(ucnv_toUCountPending) +#define ucnv_toUWriteCodePoint U_ICU_ENTRY_POINT_RENAME(ucnv_toUWriteCodePoint) +#define ucnv_toUWriteUChars U_ICU_ENTRY_POINT_RENAME(ucnv_toUWriteUChars) +#define ucnv_toUnicode U_ICU_ENTRY_POINT_RENAME(ucnv_toUnicode) +#define ucnv_unload U_ICU_ENTRY_POINT_RENAME(ucnv_unload) +#define ucnv_unloadSharedDataIfReady U_ICU_ENTRY_POINT_RENAME(ucnv_unloadSharedDataIfReady) +#define ucnv_usesFallback U_ICU_ENTRY_POINT_RENAME(ucnv_usesFallback) +#define ucnvsel_close U_ICU_ENTRY_POINT_RENAME(ucnvsel_close) +#define ucnvsel_open U_ICU_ENTRY_POINT_RENAME(ucnvsel_open) +#define ucnvsel_openFromSerialized U_ICU_ENTRY_POINT_RENAME(ucnvsel_openFromSerialized) +#define ucnvsel_selectForString U_ICU_ENTRY_POINT_RENAME(ucnvsel_selectForString) +#define ucnvsel_selectForUTF8 U_ICU_ENTRY_POINT_RENAME(ucnvsel_selectForUTF8) +#define ucnvsel_serialize U_ICU_ENTRY_POINT_RENAME(ucnvsel_serialize) +#define ucol_allocWeights U_ICU_ENTRY_POINT_RENAME(ucol_allocWeights) +#define ucol_assembleTailoringTable U_ICU_ENTRY_POINT_RENAME(ucol_assembleTailoringTable) +#define ucol_buildPermutationTable U_ICU_ENTRY_POINT_RENAME(ucol_buildPermutationTable) +#define ucol_calcSortKey U_ICU_ENTRY_POINT_RENAME(ucol_calcSortKey) +#define ucol_calcSortKeySimpleTertiary U_ICU_ENTRY_POINT_RENAME(ucol_calcSortKeySimpleTertiary) +#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_closeElements U_ICU_ENTRY_POINT_RENAME(ucol_closeElements) +#define ucol_countAvailable U_ICU_ENTRY_POINT_RENAME(ucol_countAvailable) +#define ucol_createElements U_ICU_ENTRY_POINT_RENAME(ucol_createElements) +#define ucol_doCE U_ICU_ENTRY_POINT_RENAME(ucol_doCE) +#define ucol_equal U_ICU_ENTRY_POINT_RENAME(ucol_equal) +#define ucol_equals U_ICU_ENTRY_POINT_RENAME(ucol_equals) +#define ucol_findReorderingEntry U_ICU_ENTRY_POINT_RENAME(ucol_findReorderingEntry) +#define ucol_forceHanImplicit U_ICU_ENTRY_POINT_RENAME(ucol_forceHanImplicit) +#define ucol_forgetUCA U_ICU_ENTRY_POINT_RENAME(ucol_forgetUCA) +#define ucol_freeOffsetBuffer U_ICU_ENTRY_POINT_RENAME(ucol_freeOffsetBuffer) +#define ucol_getAttribute U_ICU_ENTRY_POINT_RENAME(ucol_getAttribute) +#define ucol_getAttributeOrDefault U_ICU_ENTRY_POINT_RENAME(ucol_getAttributeOrDefault) +#define ucol_getAvailable U_ICU_ENTRY_POINT_RENAME(ucol_getAvailable) +#define ucol_getBound U_ICU_ENTRY_POINT_RENAME(ucol_getBound) +#define ucol_getCEStrengthDifference U_ICU_ENTRY_POINT_RENAME(ucol_getCEStrengthDifference) +#define ucol_getContractions U_ICU_ENTRY_POINT_RENAME(ucol_getContractions) +#define ucol_getContractionsAndExpansions U_ICU_ENTRY_POINT_RENAME(ucol_getContractionsAndExpansions) +#define ucol_getDisplayName U_ICU_ENTRY_POINT_RENAME(ucol_getDisplayName) +#define ucol_getFirstCE U_ICU_ENTRY_POINT_RENAME(ucol_getFirstCE) +#define ucol_getFunctionalEquivalent U_ICU_ENTRY_POINT_RENAME(ucol_getFunctionalEquivalent) +#define ucol_getKeywordValues U_ICU_ENTRY_POINT_RENAME(ucol_getKeywordValues) +#define ucol_getKeywordValuesForLocale U_ICU_ENTRY_POINT_RENAME(ucol_getKeywordValuesForLocale) +#define ucol_getKeywords U_ICU_ENTRY_POINT_RENAME(ucol_getKeywords) +#define ucol_getLeadBytesForReorderCode U_ICU_ENTRY_POINT_RENAME(ucol_getLeadBytesForReorderCode) +#define ucol_getLocale U_ICU_ENTRY_POINT_RENAME(ucol_getLocale) +#define ucol_getLocaleByType U_ICU_ENTRY_POINT_RENAME(ucol_getLocaleByType) +#define ucol_getMaxExpansion U_ICU_ENTRY_POINT_RENAME(ucol_getMaxExpansion) +#define ucol_getNextCE U_ICU_ENTRY_POINT_RENAME(ucol_getNextCE) +#define ucol_getOffset U_ICU_ENTRY_POINT_RENAME(ucol_getOffset) +#define ucol_getPrevCE U_ICU_ENTRY_POINT_RENAME(ucol_getPrevCE) +#define ucol_getReorderCodes U_ICU_ENTRY_POINT_RENAME(ucol_getReorderCodes) +#define ucol_getReorderCodesForLeadByte U_ICU_ENTRY_POINT_RENAME(ucol_getReorderCodesForLeadByte) +#define ucol_getRules U_ICU_ENTRY_POINT_RENAME(ucol_getRules) +#define ucol_getRulesEx U_ICU_ENTRY_POINT_RENAME(ucol_getRulesEx) +#define ucol_getShortDefinitionString U_ICU_ENTRY_POINT_RENAME(ucol_getShortDefinitionString) +#define ucol_getSortKey U_ICU_ENTRY_POINT_RENAME(ucol_getSortKey) +#define ucol_getSortKeySize U_ICU_ENTRY_POINT_RENAME(ucol_getSortKeySize) +#define ucol_getSortKeyWithAllocation U_ICU_ENTRY_POINT_RENAME(ucol_getSortKeyWithAllocation) +#define ucol_getStrength U_ICU_ENTRY_POINT_RENAME(ucol_getStrength) +#define ucol_getTailoredSet U_ICU_ENTRY_POINT_RENAME(ucol_getTailoredSet) +#define ucol_getUCAVersion U_ICU_ENTRY_POINT_RENAME(ucol_getUCAVersion) +#define ucol_getUnsafeSet U_ICU_ENTRY_POINT_RENAME(ucol_getUnsafeSet) +#define ucol_getVariableTop U_ICU_ENTRY_POINT_RENAME(ucol_getVariableTop) +#define ucol_getVersion U_ICU_ENTRY_POINT_RENAME(ucol_getVersion) +#define ucol_greater U_ICU_ENTRY_POINT_RENAME(ucol_greater) +#define ucol_greaterOrEqual U_ICU_ENTRY_POINT_RENAME(ucol_greaterOrEqual) +#define ucol_initBuffers U_ICU_ENTRY_POINT_RENAME(ucol_initBuffers) +#define ucol_initCollator U_ICU_ENTRY_POINT_RENAME(ucol_initCollator) +#define ucol_initInverseUCA U_ICU_ENTRY_POINT_RENAME(ucol_initInverseUCA) +#define ucol_initUCA U_ICU_ENTRY_POINT_RENAME(ucol_initUCA) +#define ucol_inv_getNextCE U_ICU_ENTRY_POINT_RENAME(ucol_inv_getNextCE) +#define ucol_inv_getPrevCE U_ICU_ENTRY_POINT_RENAME(ucol_inv_getPrevCE) +#define ucol_isTailored U_ICU_ENTRY_POINT_RENAME(ucol_isTailored) +#define ucol_keyHashCode U_ICU_ENTRY_POINT_RENAME(ucol_keyHashCode) +#define ucol_looksLikeCollationBinary U_ICU_ENTRY_POINT_RENAME(ucol_looksLikeCollationBinary) +#define ucol_mergeSortkeys U_ICU_ENTRY_POINT_RENAME(ucol_mergeSortkeys) +#define ucol_next U_ICU_ENTRY_POINT_RENAME(ucol_next) +#define ucol_nextProcessed U_ICU_ENTRY_POINT_RENAME(ucol_nextProcessed) +#define ucol_nextSortKeyPart U_ICU_ENTRY_POINT_RENAME(ucol_nextSortKeyPart) +#define ucol_nextWeight U_ICU_ENTRY_POINT_RENAME(ucol_nextWeight) +#define ucol_normalizeShortDefinitionString U_ICU_ENTRY_POINT_RENAME(ucol_normalizeShortDefinitionString) +#define ucol_open U_ICU_ENTRY_POINT_RENAME(ucol_open) +#define ucol_openAvailableLocales U_ICU_ENTRY_POINT_RENAME(ucol_openAvailableLocales) +#define ucol_openBinary U_ICU_ENTRY_POINT_RENAME(ucol_openBinary) +#define ucol_openElements U_ICU_ENTRY_POINT_RENAME(ucol_openElements) +#define ucol_openFromShortString U_ICU_ENTRY_POINT_RENAME(ucol_openFromShortString) +#define ucol_openRules U_ICU_ENTRY_POINT_RENAME(ucol_openRules) +#define ucol_openRulesForImport U_ICU_ENTRY_POINT_RENAME(ucol_openRulesForImport) +#define ucol_open_internal U_ICU_ENTRY_POINT_RENAME(ucol_open_internal) +#define ucol_prepareShortStringOpen U_ICU_ENTRY_POINT_RENAME(ucol_prepareShortStringOpen) +#define ucol_previous U_ICU_ENTRY_POINT_RENAME(ucol_previous) +#define ucol_previousProcessed U_ICU_ENTRY_POINT_RENAME(ucol_previousProcessed) +#define ucol_primaryOrder U_ICU_ENTRY_POINT_RENAME(ucol_primaryOrder) +#define ucol_prv_getSpecialCE U_ICU_ENTRY_POINT_RENAME(ucol_prv_getSpecialCE) +#define ucol_prv_getSpecialPrevCE U_ICU_ENTRY_POINT_RENAME(ucol_prv_getSpecialPrevCE) +#define ucol_reset U_ICU_ENTRY_POINT_RENAME(ucol_reset) +#define ucol_restoreVariableTop U_ICU_ENTRY_POINT_RENAME(ucol_restoreVariableTop) +#define ucol_safeClone U_ICU_ENTRY_POINT_RENAME(ucol_safeClone) +#define ucol_secondaryOrder U_ICU_ENTRY_POINT_RENAME(ucol_secondaryOrder) +#define ucol_setAttribute U_ICU_ENTRY_POINT_RENAME(ucol_setAttribute) +#define ucol_setOffset U_ICU_ENTRY_POINT_RENAME(ucol_setOffset) +#define ucol_setOptionsFromHeader U_ICU_ENTRY_POINT_RENAME(ucol_setOptionsFromHeader) +#define ucol_setReorderCodes U_ICU_ENTRY_POINT_RENAME(ucol_setReorderCodes) +#define ucol_setReqValidLocales U_ICU_ENTRY_POINT_RENAME(ucol_setReqValidLocales) +#define ucol_setStrength U_ICU_ENTRY_POINT_RENAME(ucol_setStrength) +#define ucol_setText U_ICU_ENTRY_POINT_RENAME(ucol_setText) +#define ucol_setVariableTop U_ICU_ENTRY_POINT_RENAME(ucol_setVariableTop) +#define ucol_strcoll U_ICU_ENTRY_POINT_RENAME(ucol_strcoll) +#define ucol_strcollIter U_ICU_ENTRY_POINT_RENAME(ucol_strcollIter) +#define ucol_swap U_ICU_ENTRY_POINT_RENAME(ucol_swap) +#define ucol_swapBinary U_ICU_ENTRY_POINT_RENAME(ucol_swapBinary) +#define ucol_swapInverseUCA U_ICU_ENTRY_POINT_RENAME(ucol_swapInverseUCA) +#define ucol_tertiaryOrder U_ICU_ENTRY_POINT_RENAME(ucol_tertiaryOrder) +#define ucol_tok_assembleTokenList U_ICU_ENTRY_POINT_RENAME(ucol_tok_assembleTokenList) +#define ucol_tok_closeTokenList U_ICU_ENTRY_POINT_RENAME(ucol_tok_closeTokenList) +#define ucol_tok_getNextArgument U_ICU_ENTRY_POINT_RENAME(ucol_tok_getNextArgument) +#define ucol_tok_getRulesFromBundle U_ICU_ENTRY_POINT_RENAME(ucol_tok_getRulesFromBundle) +#define ucol_tok_initTokenList U_ICU_ENTRY_POINT_RENAME(ucol_tok_initTokenList) +#define ucol_tok_parseNextToken U_ICU_ENTRY_POINT_RENAME(ucol_tok_parseNextToken) +#define ucol_updateInternalState U_ICU_ENTRY_POINT_RENAME(ucol_updateInternalState) +#define ucsdet_close U_ICU_ENTRY_POINT_RENAME(ucsdet_close) +#define ucsdet_detect U_ICU_ENTRY_POINT_RENAME(ucsdet_detect) +#define ucsdet_detectAll U_ICU_ENTRY_POINT_RENAME(ucsdet_detectAll) +#define ucsdet_enableInputFilter U_ICU_ENTRY_POINT_RENAME(ucsdet_enableInputFilter) +#define ucsdet_getAllDetectableCharsets U_ICU_ENTRY_POINT_RENAME(ucsdet_getAllDetectableCharsets) +#define ucsdet_getConfidence U_ICU_ENTRY_POINT_RENAME(ucsdet_getConfidence) +#define ucsdet_getLanguage U_ICU_ENTRY_POINT_RENAME(ucsdet_getLanguage) +#define ucsdet_getName U_ICU_ENTRY_POINT_RENAME(ucsdet_getName) +#define ucsdet_getUChars U_ICU_ENTRY_POINT_RENAME(ucsdet_getUChars) +#define ucsdet_isInputFilterEnabled U_ICU_ENTRY_POINT_RENAME(ucsdet_isInputFilterEnabled) +#define ucsdet_open U_ICU_ENTRY_POINT_RENAME(ucsdet_open) +#define ucsdet_setDeclaredEncoding U_ICU_ENTRY_POINT_RENAME(ucsdet_setDeclaredEncoding) +#define ucsdet_setText U_ICU_ENTRY_POINT_RENAME(ucsdet_setText) +#define ucurr_countCurrencies U_ICU_ENTRY_POINT_RENAME(ucurr_countCurrencies) +#define ucurr_forLocale U_ICU_ENTRY_POINT_RENAME(ucurr_forLocale) +#define ucurr_forLocaleAndDate U_ICU_ENTRY_POINT_RENAME(ucurr_forLocaleAndDate) +#define ucurr_getDefaultFractionDigits U_ICU_ENTRY_POINT_RENAME(ucurr_getDefaultFractionDigits) +#define ucurr_getKeywordValuesForLocale U_ICU_ENTRY_POINT_RENAME(ucurr_getKeywordValuesForLocale) +#define ucurr_getName U_ICU_ENTRY_POINT_RENAME(ucurr_getName) +#define ucurr_getPluralName U_ICU_ENTRY_POINT_RENAME(ucurr_getPluralName) +#define ucurr_getRoundingIncrement U_ICU_ENTRY_POINT_RENAME(ucurr_getRoundingIncrement) +#define ucurr_openISOCurrencies U_ICU_ENTRY_POINT_RENAME(ucurr_openISOCurrencies) +#define ucurr_register U_ICU_ENTRY_POINT_RENAME(ucurr_register) +#define ucurr_unregister U_ICU_ENTRY_POINT_RENAME(ucurr_unregister) +#define udat_applyPattern U_ICU_ENTRY_POINT_RENAME(udat_applyPattern) +#define udat_applyPatternRelative U_ICU_ENTRY_POINT_RENAME(udat_applyPatternRelative) +#define udat_clone U_ICU_ENTRY_POINT_RENAME(udat_clone) +#define udat_close U_ICU_ENTRY_POINT_RENAME(udat_close) +#define udat_countAvailable U_ICU_ENTRY_POINT_RENAME(udat_countAvailable) +#define udat_countSymbols U_ICU_ENTRY_POINT_RENAME(udat_countSymbols) +#define udat_format U_ICU_ENTRY_POINT_RENAME(udat_format) +#define udat_get2DigitYearStart U_ICU_ENTRY_POINT_RENAME(udat_get2DigitYearStart) +#define udat_getAvailable U_ICU_ENTRY_POINT_RENAME(udat_getAvailable) +#define udat_getCalendar U_ICU_ENTRY_POINT_RENAME(udat_getCalendar) +#define udat_getLocaleByType U_ICU_ENTRY_POINT_RENAME(udat_getLocaleByType) +#define udat_getNumberFormat U_ICU_ENTRY_POINT_RENAME(udat_getNumberFormat) +#define udat_getSymbols U_ICU_ENTRY_POINT_RENAME(udat_getSymbols) +#define udat_isLenient U_ICU_ENTRY_POINT_RENAME(udat_isLenient) +#define udat_open U_ICU_ENTRY_POINT_RENAME(udat_open) +#define udat_parse U_ICU_ENTRY_POINT_RENAME(udat_parse) +#define udat_parseCalendar U_ICU_ENTRY_POINT_RENAME(udat_parseCalendar) +#define udat_set2DigitYearStart U_ICU_ENTRY_POINT_RENAME(udat_set2DigitYearStart) +#define udat_setCalendar U_ICU_ENTRY_POINT_RENAME(udat_setCalendar) +#define udat_setLenient U_ICU_ENTRY_POINT_RENAME(udat_setLenient) +#define udat_setNumberFormat U_ICU_ENTRY_POINT_RENAME(udat_setNumberFormat) +#define udat_setSymbols U_ICU_ENTRY_POINT_RENAME(udat_setSymbols) +#define udat_toCalendarDateField U_ICU_ENTRY_POINT_RENAME(udat_toCalendarDateField) +#define udat_toPattern U_ICU_ENTRY_POINT_RENAME(udat_toPattern) +#define udat_toPatternRelativeDate U_ICU_ENTRY_POINT_RENAME(udat_toPatternRelativeDate) +#define udat_toPatternRelativeTime U_ICU_ENTRY_POINT_RENAME(udat_toPatternRelativeTime) +#define udata_checkCommonData U_ICU_ENTRY_POINT_RENAME(udata_checkCommonData) +#define udata_close U_ICU_ENTRY_POINT_RENAME(udata_close) +#define udata_closeSwapper U_ICU_ENTRY_POINT_RENAME(udata_closeSwapper) +#define udata_getHeaderSize U_ICU_ENTRY_POINT_RENAME(udata_getHeaderSize) +#define udata_getInfo U_ICU_ENTRY_POINT_RENAME(udata_getInfo) +#define udata_getInfoSize U_ICU_ENTRY_POINT_RENAME(udata_getInfoSize) +#define udata_getLength U_ICU_ENTRY_POINT_RENAME(udata_getLength) +#define udata_getMemory U_ICU_ENTRY_POINT_RENAME(udata_getMemory) +#define udata_getRawMemory U_ICU_ENTRY_POINT_RENAME(udata_getRawMemory) +#define udata_open U_ICU_ENTRY_POINT_RENAME(udata_open) +#define udata_openChoice U_ICU_ENTRY_POINT_RENAME(udata_openChoice) +#define udata_openSwapper U_ICU_ENTRY_POINT_RENAME(udata_openSwapper) +#define udata_openSwapperForInputData U_ICU_ENTRY_POINT_RENAME(udata_openSwapperForInputData) +#define udata_printError U_ICU_ENTRY_POINT_RENAME(udata_printError) +#define udata_readInt16 U_ICU_ENTRY_POINT_RENAME(udata_readInt16) +#define udata_readInt32 U_ICU_ENTRY_POINT_RENAME(udata_readInt32) +#define udata_setAppData U_ICU_ENTRY_POINT_RENAME(udata_setAppData) +#define udata_setCommonData U_ICU_ENTRY_POINT_RENAME(udata_setCommonData) +#define udata_setFileAccess U_ICU_ENTRY_POINT_RENAME(udata_setFileAccess) +#define udata_swapDataHeader U_ICU_ENTRY_POINT_RENAME(udata_swapDataHeader) +#define udata_swapInvStringBlock U_ICU_ENTRY_POINT_RENAME(udata_swapInvStringBlock) +#define udatpg_addPattern U_ICU_ENTRY_POINT_RENAME(udatpg_addPattern) +#define udatpg_clone U_ICU_ENTRY_POINT_RENAME(udatpg_clone) +#define udatpg_close U_ICU_ENTRY_POINT_RENAME(udatpg_close) +#define udatpg_getAppendItemFormat U_ICU_ENTRY_POINT_RENAME(udatpg_getAppendItemFormat) +#define udatpg_getAppendItemName U_ICU_ENTRY_POINT_RENAME(udatpg_getAppendItemName) +#define udatpg_getBaseSkeleton U_ICU_ENTRY_POINT_RENAME(udatpg_getBaseSkeleton) +#define udatpg_getBestPattern U_ICU_ENTRY_POINT_RENAME(udatpg_getBestPattern) +#define udatpg_getBestPatternWithOptions U_ICU_ENTRY_POINT_RENAME(udatpg_getBestPatternWithOptions) +#define udatpg_getDateTimeFormat U_ICU_ENTRY_POINT_RENAME(udatpg_getDateTimeFormat) +#define udatpg_getDecimal U_ICU_ENTRY_POINT_RENAME(udatpg_getDecimal) +#define udatpg_getPatternForSkeleton U_ICU_ENTRY_POINT_RENAME(udatpg_getPatternForSkeleton) +#define udatpg_getSkeleton U_ICU_ENTRY_POINT_RENAME(udatpg_getSkeleton) +#define udatpg_open U_ICU_ENTRY_POINT_RENAME(udatpg_open) +#define udatpg_openBaseSkeletons U_ICU_ENTRY_POINT_RENAME(udatpg_openBaseSkeletons) +#define udatpg_openEmpty U_ICU_ENTRY_POINT_RENAME(udatpg_openEmpty) +#define udatpg_openSkeletons U_ICU_ENTRY_POINT_RENAME(udatpg_openSkeletons) +#define udatpg_replaceFieldTypes U_ICU_ENTRY_POINT_RENAME(udatpg_replaceFieldTypes) +#define udatpg_replaceFieldTypesWithOptions U_ICU_ENTRY_POINT_RENAME(udatpg_replaceFieldTypesWithOptions) +#define udatpg_setAppendItemFormat U_ICU_ENTRY_POINT_RENAME(udatpg_setAppendItemFormat) +#define udatpg_setAppendItemName U_ICU_ENTRY_POINT_RENAME(udatpg_setAppendItemName) +#define udatpg_setDateTimeFormat U_ICU_ENTRY_POINT_RENAME(udatpg_setDateTimeFormat) +#define udatpg_setDecimal U_ICU_ENTRY_POINT_RENAME(udatpg_setDecimal) +#define uenum_close U_ICU_ENTRY_POINT_RENAME(uenum_close) +#define uenum_count U_ICU_ENTRY_POINT_RENAME(uenum_count) +#define uenum_next U_ICU_ENTRY_POINT_RENAME(uenum_next) +#define uenum_nextDefault U_ICU_ENTRY_POINT_RENAME(uenum_nextDefault) +#define uenum_openCharStringsEnumeration U_ICU_ENTRY_POINT_RENAME(uenum_openCharStringsEnumeration) +#define uenum_openFromStringEnumeration U_ICU_ENTRY_POINT_RENAME(uenum_openFromStringEnumeration) +#define uenum_reset U_ICU_ENTRY_POINT_RENAME(uenum_reset) +#define uenum_unext U_ICU_ENTRY_POINT_RENAME(uenum_unext) +#define uenum_unextDefault U_ICU_ENTRY_POINT_RENAME(uenum_unextDefault) +#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_buffer) +#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_getch U_ICU_ENTRY_POINT_RENAME(ufile_getch) +#define ufile_getch32 U_ICU_ENTRY_POINT_RENAME(ufile_getch32) +#define ufmt_64tou U_ICU_ENTRY_POINT_RENAME(ufmt_64tou) +#define ufmt_defaultCPToUnicode U_ICU_ENTRY_POINT_RENAME(ufmt_defaultCPToUnicode) +#define ufmt_digitvalue U_ICU_ENTRY_POINT_RENAME(ufmt_digitvalue) +#define ufmt_isdigit U_ICU_ENTRY_POINT_RENAME(ufmt_isdigit) +#define ufmt_ptou U_ICU_ENTRY_POINT_RENAME(ufmt_ptou) +#define ufmt_uto64 U_ICU_ENTRY_POINT_RENAME(ufmt_uto64) +#define ufmt_utop U_ICU_ENTRY_POINT_RENAME(ufmt_utop) +#define uhash_close U_ICU_ENTRY_POINT_RENAME(uhash_close) +#define uhash_compareCaselessUnicodeString U_ICU_ENTRY_POINT_RENAME(uhash_compareCaselessUnicodeString) +#define uhash_compareChars U_ICU_ENTRY_POINT_RENAME(uhash_compareChars) +#define uhash_compareIChars U_ICU_ENTRY_POINT_RENAME(uhash_compareIChars) +#define uhash_compareLong U_ICU_ENTRY_POINT_RENAME(uhash_compareLong) +#define uhash_compareUChars U_ICU_ENTRY_POINT_RENAME(uhash_compareUChars) +#define uhash_compareUnicodeString U_ICU_ENTRY_POINT_RENAME(uhash_compareUnicodeString) +#define uhash_count U_ICU_ENTRY_POINT_RENAME(uhash_count) +#define uhash_deleteHashtable U_ICU_ENTRY_POINT_RENAME(uhash_deleteHashtable) +#define uhash_deleteUObject U_ICU_ENTRY_POINT_RENAME(uhash_deleteUObject) +#define uhash_deleteUnicodeString U_ICU_ENTRY_POINT_RENAME(uhash_deleteUnicodeString) +#define uhash_equals U_ICU_ENTRY_POINT_RENAME(uhash_equals) +#define uhash_find U_ICU_ENTRY_POINT_RENAME(uhash_find) +#define uhash_freeBlock U_ICU_ENTRY_POINT_RENAME(uhash_freeBlock) +#define uhash_get U_ICU_ENTRY_POINT_RENAME(uhash_get) +#define uhash_geti U_ICU_ENTRY_POINT_RENAME(uhash_geti) +#define uhash_hashCaselessUnicodeString U_ICU_ENTRY_POINT_RENAME(uhash_hashCaselessUnicodeString) +#define uhash_hashChars U_ICU_ENTRY_POINT_RENAME(uhash_hashChars) +#define uhash_hashIChars U_ICU_ENTRY_POINT_RENAME(uhash_hashIChars) +#define uhash_hashLong U_ICU_ENTRY_POINT_RENAME(uhash_hashLong) +#define uhash_hashUChars U_ICU_ENTRY_POINT_RENAME(uhash_hashUChars) +#define uhash_hashUCharsN U_ICU_ENTRY_POINT_RENAME(uhash_hashUCharsN) +#define uhash_hashUnicodeString U_ICU_ENTRY_POINT_RENAME(uhash_hashUnicodeString) +#define uhash_iget U_ICU_ENTRY_POINT_RENAME(uhash_iget) +#define uhash_igeti U_ICU_ENTRY_POINT_RENAME(uhash_igeti) +#define uhash_init U_ICU_ENTRY_POINT_RENAME(uhash_init) +#define uhash_iput U_ICU_ENTRY_POINT_RENAME(uhash_iput) +#define uhash_iputi U_ICU_ENTRY_POINT_RENAME(uhash_iputi) +#define uhash_iremove U_ICU_ENTRY_POINT_RENAME(uhash_iremove) +#define uhash_iremovei U_ICU_ENTRY_POINT_RENAME(uhash_iremovei) +#define uhash_nextElement U_ICU_ENTRY_POINT_RENAME(uhash_nextElement) +#define uhash_open U_ICU_ENTRY_POINT_RENAME(uhash_open) +#define uhash_openSize U_ICU_ENTRY_POINT_RENAME(uhash_openSize) +#define uhash_put U_ICU_ENTRY_POINT_RENAME(uhash_put) +#define uhash_puti U_ICU_ENTRY_POINT_RENAME(uhash_puti) +#define uhash_remove U_ICU_ENTRY_POINT_RENAME(uhash_remove) +#define uhash_removeAll U_ICU_ENTRY_POINT_RENAME(uhash_removeAll) +#define uhash_removeElement U_ICU_ENTRY_POINT_RENAME(uhash_removeElement) +#define uhash_removei U_ICU_ENTRY_POINT_RENAME(uhash_removei) +#define uhash_setKeyComparator U_ICU_ENTRY_POINT_RENAME(uhash_setKeyComparator) +#define uhash_setKeyDeleter U_ICU_ENTRY_POINT_RENAME(uhash_setKeyDeleter) +#define uhash_setKeyHasher U_ICU_ENTRY_POINT_RENAME(uhash_setKeyHasher) +#define uhash_setResizePolicy U_ICU_ENTRY_POINT_RENAME(uhash_setResizePolicy) +#define uhash_setValueComparator U_ICU_ENTRY_POINT_RENAME(uhash_setValueComparator) +#define uhash_setValueDeleter U_ICU_ENTRY_POINT_RENAME(uhash_setValueDeleter) +#define uidna_IDNToASCII U_ICU_ENTRY_POINT_RENAME(uidna_IDNToASCII) +#define uidna_IDNToUnicode U_ICU_ENTRY_POINT_RENAME(uidna_IDNToUnicode) +#define uidna_close U_ICU_ENTRY_POINT_RENAME(uidna_close) +#define uidna_compare U_ICU_ENTRY_POINT_RENAME(uidna_compare) +#define uidna_labelToASCII U_ICU_ENTRY_POINT_RENAME(uidna_labelToASCII) +#define uidna_labelToASCII_UTF8 U_ICU_ENTRY_POINT_RENAME(uidna_labelToASCII_UTF8) +#define uidna_labelToUnicode U_ICU_ENTRY_POINT_RENAME(uidna_labelToUnicode) +#define uidna_labelToUnicodeUTF8 U_ICU_ENTRY_POINT_RENAME(uidna_labelToUnicodeUTF8) +#define uidna_nameToASCII U_ICU_ENTRY_POINT_RENAME(uidna_nameToASCII) +#define uidna_nameToASCII_UTF8 U_ICU_ENTRY_POINT_RENAME(uidna_nameToASCII_UTF8) +#define uidna_nameToUnicode U_ICU_ENTRY_POINT_RENAME(uidna_nameToUnicode) +#define uidna_nameToUnicodeUTF8 U_ICU_ENTRY_POINT_RENAME(uidna_nameToUnicodeUTF8) +#define uidna_openUTS46 U_ICU_ENTRY_POINT_RENAME(uidna_openUTS46) +#define uidna_toASCII U_ICU_ENTRY_POINT_RENAME(uidna_toASCII) +#define uidna_toUnicode U_ICU_ENTRY_POINT_RENAME(uidna_toUnicode) +#define uiter_current32 U_ICU_ENTRY_POINT_RENAME(uiter_current32) +#define uiter_getState U_ICU_ENTRY_POINT_RENAME(uiter_getState) +#define uiter_next32 U_ICU_ENTRY_POINT_RENAME(uiter_next32) +#define uiter_previous32 U_ICU_ENTRY_POINT_RENAME(uiter_previous32) +#define uiter_setCharacterIterator U_ICU_ENTRY_POINT_RENAME(uiter_setCharacterIterator) +#define uiter_setReplaceable U_ICU_ENTRY_POINT_RENAME(uiter_setReplaceable) +#define uiter_setState U_ICU_ENTRY_POINT_RENAME(uiter_setState) +#define uiter_setString U_ICU_ENTRY_POINT_RENAME(uiter_setString) +#define uiter_setUTF16BE U_ICU_ENTRY_POINT_RENAME(uiter_setUTF16BE) +#define uiter_setUTF8 U_ICU_ENTRY_POINT_RENAME(uiter_setUTF8) +#define uldn_close U_ICU_ENTRY_POINT_RENAME(uldn_close) +#define uldn_getDialectHandling U_ICU_ENTRY_POINT_RENAME(uldn_getDialectHandling) +#define uldn_getLocale U_ICU_ENTRY_POINT_RENAME(uldn_getLocale) +#define uldn_keyDisplayName U_ICU_ENTRY_POINT_RENAME(uldn_keyDisplayName) +#define uldn_keyValueDisplayName U_ICU_ENTRY_POINT_RENAME(uldn_keyValueDisplayName) +#define uldn_languageDisplayName U_ICU_ENTRY_POINT_RENAME(uldn_languageDisplayName) +#define uldn_localeDisplayName U_ICU_ENTRY_POINT_RENAME(uldn_localeDisplayName) +#define uldn_open U_ICU_ENTRY_POINT_RENAME(uldn_open) +#define uldn_regionDisplayName U_ICU_ENTRY_POINT_RENAME(uldn_regionDisplayName) +#define uldn_scriptCodeDisplayName U_ICU_ENTRY_POINT_RENAME(uldn_scriptCodeDisplayName) +#define uldn_scriptDisplayName U_ICU_ENTRY_POINT_RENAME(uldn_scriptDisplayName) +#define uldn_variantDisplayName U_ICU_ENTRY_POINT_RENAME(uldn_variantDisplayName) +#define ulist_addItemBeginList U_ICU_ENTRY_POINT_RENAME(ulist_addItemBeginList) +#define ulist_addItemEndList U_ICU_ENTRY_POINT_RENAME(ulist_addItemEndList) +#define ulist_close_keyword_values_iterator U_ICU_ENTRY_POINT_RENAME(ulist_close_keyword_values_iterator) +#define ulist_containsString U_ICU_ENTRY_POINT_RENAME(ulist_containsString) +#define ulist_count_keyword_values U_ICU_ENTRY_POINT_RENAME(ulist_count_keyword_values) +#define ulist_createEmptyList U_ICU_ENTRY_POINT_RENAME(ulist_createEmptyList) +#define ulist_deleteList U_ICU_ENTRY_POINT_RENAME(ulist_deleteList) +#define ulist_getListFromEnum U_ICU_ENTRY_POINT_RENAME(ulist_getListFromEnum) +#define ulist_getListSize U_ICU_ENTRY_POINT_RENAME(ulist_getListSize) +#define ulist_getNext U_ICU_ENTRY_POINT_RENAME(ulist_getNext) +#define ulist_next_keyword_value U_ICU_ENTRY_POINT_RENAME(ulist_next_keyword_value) +#define ulist_resetList U_ICU_ENTRY_POINT_RENAME(ulist_resetList) +#define ulist_reset_keyword_values_iterator U_ICU_ENTRY_POINT_RENAME(ulist_reset_keyword_values_iterator) +#define uloc_acceptLanguage U_ICU_ENTRY_POINT_RENAME(uloc_acceptLanguage) +#define uloc_acceptLanguageFromHTTP U_ICU_ENTRY_POINT_RENAME(uloc_acceptLanguageFromHTTP) +#define uloc_addLikelySubtags U_ICU_ENTRY_POINT_RENAME(uloc_addLikelySubtags) +#define uloc_canonicalize U_ICU_ENTRY_POINT_RENAME(uloc_canonicalize) +#define uloc_countAvailable U_ICU_ENTRY_POINT_RENAME(uloc_countAvailable) +#define uloc_forLanguageTag U_ICU_ENTRY_POINT_RENAME(uloc_forLanguageTag) +#define uloc_getAvailable U_ICU_ENTRY_POINT_RENAME(uloc_getAvailable) +#define uloc_getBaseName U_ICU_ENTRY_POINT_RENAME(uloc_getBaseName) +#define uloc_getCharacterOrientation U_ICU_ENTRY_POINT_RENAME(uloc_getCharacterOrientation) +#define uloc_getCountry U_ICU_ENTRY_POINT_RENAME(uloc_getCountry) +#define uloc_getCurrentCountryID U_ICU_ENTRY_POINT_RENAME(uloc_getCurrentCountryID) +#define uloc_getCurrentLanguageID U_ICU_ENTRY_POINT_RENAME(uloc_getCurrentLanguageID) +#define uloc_getDefault U_ICU_ENTRY_POINT_RENAME(uloc_getDefault) +#define uloc_getDisplayCountry U_ICU_ENTRY_POINT_RENAME(uloc_getDisplayCountry) +#define uloc_getDisplayKeyword U_ICU_ENTRY_POINT_RENAME(uloc_getDisplayKeyword) +#define uloc_getDisplayKeywordValue U_ICU_ENTRY_POINT_RENAME(uloc_getDisplayKeywordValue) +#define uloc_getDisplayLanguage U_ICU_ENTRY_POINT_RENAME(uloc_getDisplayLanguage) +#define uloc_getDisplayName U_ICU_ENTRY_POINT_RENAME(uloc_getDisplayName) +#define uloc_getDisplayScript U_ICU_ENTRY_POINT_RENAME(uloc_getDisplayScript) +#define uloc_getDisplayVariant U_ICU_ENTRY_POINT_RENAME(uloc_getDisplayVariant) +#define uloc_getISO3Country U_ICU_ENTRY_POINT_RENAME(uloc_getISO3Country) +#define uloc_getISO3Language U_ICU_ENTRY_POINT_RENAME(uloc_getISO3Language) +#define uloc_getISOCountries U_ICU_ENTRY_POINT_RENAME(uloc_getISOCountries) +#define uloc_getISOLanguages U_ICU_ENTRY_POINT_RENAME(uloc_getISOLanguages) +#define uloc_getKeywordValue U_ICU_ENTRY_POINT_RENAME(uloc_getKeywordValue) +#define uloc_getLCID U_ICU_ENTRY_POINT_RENAME(uloc_getLCID) +#define uloc_getLanguage U_ICU_ENTRY_POINT_RENAME(uloc_getLanguage) +#define uloc_getLineOrientation U_ICU_ENTRY_POINT_RENAME(uloc_getLineOrientation) +#define uloc_getLocaleForLCID U_ICU_ENTRY_POINT_RENAME(uloc_getLocaleForLCID) +#define uloc_getName U_ICU_ENTRY_POINT_RENAME(uloc_getName) +#define uloc_getParent U_ICU_ENTRY_POINT_RENAME(uloc_getParent) +#define uloc_getScript U_ICU_ENTRY_POINT_RENAME(uloc_getScript) +#define uloc_getTableStringWithFallback U_ICU_ENTRY_POINT_RENAME(uloc_getTableStringWithFallback) +#define uloc_getVariant U_ICU_ENTRY_POINT_RENAME(uloc_getVariant) +#define uloc_minimizeSubtags U_ICU_ENTRY_POINT_RENAME(uloc_minimizeSubtags) +#define uloc_openKeywordList U_ICU_ENTRY_POINT_RENAME(uloc_openKeywordList) +#define uloc_openKeywords U_ICU_ENTRY_POINT_RENAME(uloc_openKeywords) +#define uloc_setDefault U_ICU_ENTRY_POINT_RENAME(uloc_setDefault) +#define uloc_setKeywordValue U_ICU_ENTRY_POINT_RENAME(uloc_setKeywordValue) +#define uloc_toLanguageTag U_ICU_ENTRY_POINT_RENAME(uloc_toLanguageTag) +#define ulocdata_close U_ICU_ENTRY_POINT_RENAME(ulocdata_close) +#define ulocdata_getCLDRVersion U_ICU_ENTRY_POINT_RENAME(ulocdata_getCLDRVersion) +#define ulocdata_getDelimiter U_ICU_ENTRY_POINT_RENAME(ulocdata_getDelimiter) +#define ulocdata_getExemplarSet U_ICU_ENTRY_POINT_RENAME(ulocdata_getExemplarSet) +#define ulocdata_getLocaleDisplayPattern U_ICU_ENTRY_POINT_RENAME(ulocdata_getLocaleDisplayPattern) +#define ulocdata_getLocaleSeparator U_ICU_ENTRY_POINT_RENAME(ulocdata_getLocaleSeparator) +#define ulocdata_getMeasurementSystem U_ICU_ENTRY_POINT_RENAME(ulocdata_getMeasurementSystem) +#define ulocdata_getNoSubstitute U_ICU_ENTRY_POINT_RENAME(ulocdata_getNoSubstitute) +#define ulocdata_getPaperSize U_ICU_ENTRY_POINT_RENAME(ulocdata_getPaperSize) +#define ulocdata_open U_ICU_ENTRY_POINT_RENAME(ulocdata_open) +#define ulocdata_setNoSubstitute U_ICU_ENTRY_POINT_RENAME(ulocdata_setNoSubstitute) +#define ulocimp_getCountry U_ICU_ENTRY_POINT_RENAME(ulocimp_getCountry) +#define ulocimp_getLanguage U_ICU_ENTRY_POINT_RENAME(ulocimp_getLanguage) +#define ulocimp_getScript U_ICU_ENTRY_POINT_RENAME(ulocimp_getScript) +#define umsg_applyPattern U_ICU_ENTRY_POINT_RENAME(umsg_applyPattern) +#define umsg_autoQuoteApostrophe U_ICU_ENTRY_POINT_RENAME(umsg_autoQuoteApostrophe) +#define umsg_clone U_ICU_ENTRY_POINT_RENAME(umsg_clone) +#define umsg_close U_ICU_ENTRY_POINT_RENAME(umsg_close) +#define umsg_format U_ICU_ENTRY_POINT_RENAME(umsg_format) +#define umsg_getLocale U_ICU_ENTRY_POINT_RENAME(umsg_getLocale) +#define umsg_open U_ICU_ENTRY_POINT_RENAME(umsg_open) +#define umsg_parse U_ICU_ENTRY_POINT_RENAME(umsg_parse) +#define umsg_setLocale U_ICU_ENTRY_POINT_RENAME(umsg_setLocale) +#define umsg_toPattern U_ICU_ENTRY_POINT_RENAME(umsg_toPattern) +#define umsg_vformat U_ICU_ENTRY_POINT_RENAME(umsg_vformat) +#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_destroy U_ICU_ENTRY_POINT_RENAME(umtx_destroy) +#define umtx_init U_ICU_ENTRY_POINT_RENAME(umtx_init) +#define umtx_lock U_ICU_ENTRY_POINT_RENAME(umtx_lock) +#define umtx_unlock U_ICU_ENTRY_POINT_RENAME(umtx_unlock) +#define uniset_getUnicode32Instance U_ICU_ENTRY_POINT_RENAME(uniset_getUnicode32Instance) +#define unorm2_append U_ICU_ENTRY_POINT_RENAME(unorm2_append) +#define unorm2_close U_ICU_ENTRY_POINT_RENAME(unorm2_close) +#define unorm2_getDecomposition U_ICU_ENTRY_POINT_RENAME(unorm2_getDecomposition) +#define unorm2_getInstance U_ICU_ENTRY_POINT_RENAME(unorm2_getInstance) +#define unorm2_hasBoundaryAfter U_ICU_ENTRY_POINT_RENAME(unorm2_hasBoundaryAfter) +#define unorm2_hasBoundaryBefore U_ICU_ENTRY_POINT_RENAME(unorm2_hasBoundaryBefore) +#define unorm2_isInert U_ICU_ENTRY_POINT_RENAME(unorm2_isInert) +#define unorm2_isNormalized U_ICU_ENTRY_POINT_RENAME(unorm2_isNormalized) +#define unorm2_normalize U_ICU_ENTRY_POINT_RENAME(unorm2_normalize) +#define unorm2_normalizeSecondAndAppend U_ICU_ENTRY_POINT_RENAME(unorm2_normalizeSecondAndAppend) +#define unorm2_openFiltered U_ICU_ENTRY_POINT_RENAME(unorm2_openFiltered) +#define unorm2_quickCheck U_ICU_ENTRY_POINT_RENAME(unorm2_quickCheck) +#define unorm2_spanQuickCheckYes U_ICU_ENTRY_POINT_RENAME(unorm2_spanQuickCheckYes) +#define unorm2_swap U_ICU_ENTRY_POINT_RENAME(unorm2_swap) +#define unorm_closeIter U_ICU_ENTRY_POINT_RENAME(unorm_closeIter) +#define unorm_compare U_ICU_ENTRY_POINT_RENAME(unorm_compare) +#define unorm_concatenate U_ICU_ENTRY_POINT_RENAME(unorm_concatenate) +#define unorm_getFCDTrieIndex U_ICU_ENTRY_POINT_RENAME(unorm_getFCDTrieIndex) +#define unorm_getQuickCheck U_ICU_ENTRY_POINT_RENAME(unorm_getQuickCheck) +#define unorm_isNormalized U_ICU_ENTRY_POINT_RENAME(unorm_isNormalized) +#define unorm_isNormalizedWithOptions U_ICU_ENTRY_POINT_RENAME(unorm_isNormalizedWithOptions) +#define unorm_next U_ICU_ENTRY_POINT_RENAME(unorm_next) +#define unorm_normalize U_ICU_ENTRY_POINT_RENAME(unorm_normalize) +#define unorm_openIter U_ICU_ENTRY_POINT_RENAME(unorm_openIter) +#define unorm_previous U_ICU_ENTRY_POINT_RENAME(unorm_previous) +#define unorm_quickCheck U_ICU_ENTRY_POINT_RENAME(unorm_quickCheck) +#define unorm_quickCheckWithOptions U_ICU_ENTRY_POINT_RENAME(unorm_quickCheckWithOptions) +#define unorm_setIter U_ICU_ENTRY_POINT_RENAME(unorm_setIter) +#define unum_applyPattern U_ICU_ENTRY_POINT_RENAME(unum_applyPattern) +#define unum_clone U_ICU_ENTRY_POINT_RENAME(unum_clone) +#define unum_close U_ICU_ENTRY_POINT_RENAME(unum_close) +#define unum_countAvailable U_ICU_ENTRY_POINT_RENAME(unum_countAvailable) +#define unum_format U_ICU_ENTRY_POINT_RENAME(unum_format) +#define unum_formatDecimal U_ICU_ENTRY_POINT_RENAME(unum_formatDecimal) +#define unum_formatDouble U_ICU_ENTRY_POINT_RENAME(unum_formatDouble) +#define unum_formatDoubleCurrency U_ICU_ENTRY_POINT_RENAME(unum_formatDoubleCurrency) +#define unum_formatInt64 U_ICU_ENTRY_POINT_RENAME(unum_formatInt64) +#define unum_getAttribute U_ICU_ENTRY_POINT_RENAME(unum_getAttribute) +#define unum_getAvailable U_ICU_ENTRY_POINT_RENAME(unum_getAvailable) +#define unum_getDoubleAttribute U_ICU_ENTRY_POINT_RENAME(unum_getDoubleAttribute) +#define unum_getLocaleByType U_ICU_ENTRY_POINT_RENAME(unum_getLocaleByType) +#define unum_getSymbol U_ICU_ENTRY_POINT_RENAME(unum_getSymbol) +#define unum_getTextAttribute U_ICU_ENTRY_POINT_RENAME(unum_getTextAttribute) +#define unum_open U_ICU_ENTRY_POINT_RENAME(unum_open) +#define unum_parse U_ICU_ENTRY_POINT_RENAME(unum_parse) +#define unum_parseDecimal U_ICU_ENTRY_POINT_RENAME(unum_parseDecimal) +#define unum_parseDouble U_ICU_ENTRY_POINT_RENAME(unum_parseDouble) +#define unum_parseDoubleCurrency U_ICU_ENTRY_POINT_RENAME(unum_parseDoubleCurrency) +#define unum_parseInt64 U_ICU_ENTRY_POINT_RENAME(unum_parseInt64) +#define unum_setAttribute U_ICU_ENTRY_POINT_RENAME(unum_setAttribute) +#define unum_setDoubleAttribute U_ICU_ENTRY_POINT_RENAME(unum_setDoubleAttribute) +#define unum_setSymbol U_ICU_ENTRY_POINT_RENAME(unum_setSymbol) +#define unum_setTextAttribute U_ICU_ENTRY_POINT_RENAME(unum_setTextAttribute) +#define unum_toPattern U_ICU_ENTRY_POINT_RENAME(unum_toPattern) +#define uplug_closeLibrary U_ICU_ENTRY_POINT_RENAME(uplug_closeLibrary) +#define uplug_findLibrary U_ICU_ENTRY_POINT_RENAME(uplug_findLibrary) +#define uplug_getConfiguration U_ICU_ENTRY_POINT_RENAME(uplug_getConfiguration) +#define uplug_getContext U_ICU_ENTRY_POINT_RENAME(uplug_getContext) +#define uplug_getCurrentLevel U_ICU_ENTRY_POINT_RENAME(uplug_getCurrentLevel) +#define uplug_getLibrary U_ICU_ENTRY_POINT_RENAME(uplug_getLibrary) +#define uplug_getLibraryName U_ICU_ENTRY_POINT_RENAME(uplug_getLibraryName) +#define uplug_getPlugInternal U_ICU_ENTRY_POINT_RENAME(uplug_getPlugInternal) +#define uplug_getPlugLevel U_ICU_ENTRY_POINT_RENAME(uplug_getPlugLevel) +#define uplug_getPlugLoadStatus U_ICU_ENTRY_POINT_RENAME(uplug_getPlugLoadStatus) +#define uplug_getPlugName U_ICU_ENTRY_POINT_RENAME(uplug_getPlugName) +#define uplug_getPluginFile U_ICU_ENTRY_POINT_RENAME(uplug_getPluginFile) +#define uplug_getSymbolName U_ICU_ENTRY_POINT_RENAME(uplug_getSymbolName) +#define uplug_init U_ICU_ENTRY_POINT_RENAME(uplug_init) +#define uplug_loadPlugFromEntrypoint U_ICU_ENTRY_POINT_RENAME(uplug_loadPlugFromEntrypoint) +#define uplug_loadPlugFromLibrary U_ICU_ENTRY_POINT_RENAME(uplug_loadPlugFromLibrary) +#define uplug_nextPlug U_ICU_ENTRY_POINT_RENAME(uplug_nextPlug) +#define uplug_openLibrary U_ICU_ENTRY_POINT_RENAME(uplug_openLibrary) +#define uplug_removePlug U_ICU_ENTRY_POINT_RENAME(uplug_removePlug) +#define uplug_setContext U_ICU_ENTRY_POINT_RENAME(uplug_setContext) +#define uplug_setPlugLevel U_ICU_ENTRY_POINT_RENAME(uplug_setPlugLevel) +#define uplug_setPlugName U_ICU_ENTRY_POINT_RENAME(uplug_setPlugName) +#define uplug_setPlugNoUnload U_ICU_ENTRY_POINT_RENAME(uplug_setPlugNoUnload) +#define upname_swap U_ICU_ENTRY_POINT_RENAME(upname_swap) +#define uprops_getSource U_ICU_ENTRY_POINT_RENAME(uprops_getSource) +#define upropsvec_addPropertyStarts U_ICU_ENTRY_POINT_RENAME(upropsvec_addPropertyStarts) +#define uprv_aestrncpy U_ICU_ENTRY_POINT_RENAME(uprv_aestrncpy) +#define uprv_asciiFromEbcdic U_ICU_ENTRY_POINT_RENAME(uprv_asciiFromEbcdic) +#define uprv_asciitolower U_ICU_ENTRY_POINT_RENAME(uprv_asciitolower) +#define uprv_ceil U_ICU_ENTRY_POINT_RENAME(uprv_ceil) +#define uprv_cnttab_addContraction U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_addContraction) +#define uprv_cnttab_changeContraction U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_changeContraction) +#define uprv_cnttab_changeLastCE U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_changeLastCE) +#define uprv_cnttab_clone U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_clone) +#define uprv_cnttab_close U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_close) +#define uprv_cnttab_constructTable U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_constructTable) +#define uprv_cnttab_findCE U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_findCE) +#define uprv_cnttab_findCP U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_findCP) +#define uprv_cnttab_getCE U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_getCE) +#define uprv_cnttab_insertContraction U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_insertContraction) +#define uprv_cnttab_isTailored U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_isTailored) +#define uprv_cnttab_open U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_open) +#define uprv_cnttab_setContraction U_ICU_ENTRY_POINT_RENAME(uprv_cnttab_setContraction) +#define uprv_collIterateAtEnd U_ICU_ENTRY_POINT_RENAME(uprv_collIterateAtEnd) +#define uprv_compareASCIIPropertyNames U_ICU_ENTRY_POINT_RENAME(uprv_compareASCIIPropertyNames) +#define uprv_compareEBCDICPropertyNames U_ICU_ENTRY_POINT_RENAME(uprv_compareEBCDICPropertyNames) +#define uprv_compareInvAscii U_ICU_ENTRY_POINT_RENAME(uprv_compareInvAscii) +#define uprv_compareInvEbcdic U_ICU_ENTRY_POINT_RENAME(uprv_compareInvEbcdic) +#define uprv_compareInvEbcdicAsAscii U_ICU_ENTRY_POINT_RENAME(uprv_compareInvEbcdicAsAscii) +#define uprv_convertToLCID U_ICU_ENTRY_POINT_RENAME(uprv_convertToLCID) +#define uprv_convertToPosix U_ICU_ENTRY_POINT_RENAME(uprv_convertToPosix) +#define uprv_copyAscii U_ICU_ENTRY_POINT_RENAME(uprv_copyAscii) +#define uprv_copyEbcdic U_ICU_ENTRY_POINT_RENAME(uprv_copyEbcdic) +#define uprv_decContextClearStatus U_ICU_ENTRY_POINT_RENAME(uprv_decContextClearStatus) +#define uprv_decContextDefault U_ICU_ENTRY_POINT_RENAME(uprv_decContextDefault) +#define uprv_decContextGetRounding U_ICU_ENTRY_POINT_RENAME(uprv_decContextGetRounding) +#define uprv_decContextGetStatus U_ICU_ENTRY_POINT_RENAME(uprv_decContextGetStatus) +#define uprv_decContextRestoreStatus U_ICU_ENTRY_POINT_RENAME(uprv_decContextRestoreStatus) +#define uprv_decContextSaveStatus U_ICU_ENTRY_POINT_RENAME(uprv_decContextSaveStatus) +#define uprv_decContextSetRounding U_ICU_ENTRY_POINT_RENAME(uprv_decContextSetRounding) +#define uprv_decContextSetStatus U_ICU_ENTRY_POINT_RENAME(uprv_decContextSetStatus) +#define uprv_decContextSetStatusFromString U_ICU_ENTRY_POINT_RENAME(uprv_decContextSetStatusFromString) +#define uprv_decContextSetStatusFromStringQuiet U_ICU_ENTRY_POINT_RENAME(uprv_decContextSetStatusFromStringQuiet) +#define uprv_decContextSetStatusQuiet U_ICU_ENTRY_POINT_RENAME(uprv_decContextSetStatusQuiet) +#define uprv_decContextStatusToString U_ICU_ENTRY_POINT_RENAME(uprv_decContextStatusToString) +#define uprv_decContextTestEndian U_ICU_ENTRY_POINT_RENAME(uprv_decContextTestEndian) +#define uprv_decContextTestSavedStatus U_ICU_ENTRY_POINT_RENAME(uprv_decContextTestSavedStatus) +#define uprv_decContextTestStatus U_ICU_ENTRY_POINT_RENAME(uprv_decContextTestStatus) +#define uprv_decContextZeroStatus U_ICU_ENTRY_POINT_RENAME(uprv_decContextZeroStatus) +#define uprv_decNumberAbs U_ICU_ENTRY_POINT_RENAME(uprv_decNumberAbs) +#define uprv_decNumberAdd U_ICU_ENTRY_POINT_RENAME(uprv_decNumberAdd) +#define uprv_decNumberAnd U_ICU_ENTRY_POINT_RENAME(uprv_decNumberAnd) +#define uprv_decNumberClass U_ICU_ENTRY_POINT_RENAME(uprv_decNumberClass) +#define uprv_decNumberClassToString U_ICU_ENTRY_POINT_RENAME(uprv_decNumberClassToString) +#define uprv_decNumberCompare U_ICU_ENTRY_POINT_RENAME(uprv_decNumberCompare) +#define uprv_decNumberCompareSignal U_ICU_ENTRY_POINT_RENAME(uprv_decNumberCompareSignal) +#define uprv_decNumberCompareTotal U_ICU_ENTRY_POINT_RENAME(uprv_decNumberCompareTotal) +#define uprv_decNumberCompareTotalMag U_ICU_ENTRY_POINT_RENAME(uprv_decNumberCompareTotalMag) +#define uprv_decNumberCopy U_ICU_ENTRY_POINT_RENAME(uprv_decNumberCopy) +#define uprv_decNumberCopyAbs U_ICU_ENTRY_POINT_RENAME(uprv_decNumberCopyAbs) +#define uprv_decNumberCopyNegate U_ICU_ENTRY_POINT_RENAME(uprv_decNumberCopyNegate) +#define uprv_decNumberCopySign U_ICU_ENTRY_POINT_RENAME(uprv_decNumberCopySign) +#define uprv_decNumberDivide U_ICU_ENTRY_POINT_RENAME(uprv_decNumberDivide) +#define uprv_decNumberDivideInteger U_ICU_ENTRY_POINT_RENAME(uprv_decNumberDivideInteger) +#define uprv_decNumberExp U_ICU_ENTRY_POINT_RENAME(uprv_decNumberExp) +#define uprv_decNumberFMA U_ICU_ENTRY_POINT_RENAME(uprv_decNumberFMA) +#define uprv_decNumberFromInt32 U_ICU_ENTRY_POINT_RENAME(uprv_decNumberFromInt32) +#define uprv_decNumberFromString U_ICU_ENTRY_POINT_RENAME(uprv_decNumberFromString) +#define uprv_decNumberFromUInt32 U_ICU_ENTRY_POINT_RENAME(uprv_decNumberFromUInt32) +#define uprv_decNumberGetBCD U_ICU_ENTRY_POINT_RENAME(uprv_decNumberGetBCD) +#define uprv_decNumberInvert U_ICU_ENTRY_POINT_RENAME(uprv_decNumberInvert) +#define uprv_decNumberIsNormal U_ICU_ENTRY_POINT_RENAME(uprv_decNumberIsNormal) +#define uprv_decNumberIsSubnormal U_ICU_ENTRY_POINT_RENAME(uprv_decNumberIsSubnormal) +#define uprv_decNumberLn U_ICU_ENTRY_POINT_RENAME(uprv_decNumberLn) +#define uprv_decNumberLog10 U_ICU_ENTRY_POINT_RENAME(uprv_decNumberLog10) +#define uprv_decNumberLogB U_ICU_ENTRY_POINT_RENAME(uprv_decNumberLogB) +#define uprv_decNumberMax U_ICU_ENTRY_POINT_RENAME(uprv_decNumberMax) +#define uprv_decNumberMaxMag U_ICU_ENTRY_POINT_RENAME(uprv_decNumberMaxMag) +#define uprv_decNumberMin U_ICU_ENTRY_POINT_RENAME(uprv_decNumberMin) +#define uprv_decNumberMinMag U_ICU_ENTRY_POINT_RENAME(uprv_decNumberMinMag) +#define uprv_decNumberMinus U_ICU_ENTRY_POINT_RENAME(uprv_decNumberMinus) +#define uprv_decNumberMultiply U_ICU_ENTRY_POINT_RENAME(uprv_decNumberMultiply) +#define uprv_decNumberNextMinus U_ICU_ENTRY_POINT_RENAME(uprv_decNumberNextMinus) +#define uprv_decNumberNextPlus U_ICU_ENTRY_POINT_RENAME(uprv_decNumberNextPlus) +#define uprv_decNumberNextToward U_ICU_ENTRY_POINT_RENAME(uprv_decNumberNextToward) +#define uprv_decNumberNormalize U_ICU_ENTRY_POINT_RENAME(uprv_decNumberNormalize) +#define uprv_decNumberOr U_ICU_ENTRY_POINT_RENAME(uprv_decNumberOr) +#define uprv_decNumberPlus U_ICU_ENTRY_POINT_RENAME(uprv_decNumberPlus) +#define uprv_decNumberPower U_ICU_ENTRY_POINT_RENAME(uprv_decNumberPower) +#define uprv_decNumberQuantize U_ICU_ENTRY_POINT_RENAME(uprv_decNumberQuantize) +#define uprv_decNumberReduce U_ICU_ENTRY_POINT_RENAME(uprv_decNumberReduce) +#define uprv_decNumberRemainder U_ICU_ENTRY_POINT_RENAME(uprv_decNumberRemainder) +#define uprv_decNumberRemainderNear U_ICU_ENTRY_POINT_RENAME(uprv_decNumberRemainderNear) +#define uprv_decNumberRescale U_ICU_ENTRY_POINT_RENAME(uprv_decNumberRescale) +#define uprv_decNumberRotate U_ICU_ENTRY_POINT_RENAME(uprv_decNumberRotate) +#define uprv_decNumberSameQuantum U_ICU_ENTRY_POINT_RENAME(uprv_decNumberSameQuantum) +#define uprv_decNumberScaleB U_ICU_ENTRY_POINT_RENAME(uprv_decNumberScaleB) +#define uprv_decNumberSetBCD U_ICU_ENTRY_POINT_RENAME(uprv_decNumberSetBCD) +#define uprv_decNumberShift U_ICU_ENTRY_POINT_RENAME(uprv_decNumberShift) +#define uprv_decNumberSquareRoot U_ICU_ENTRY_POINT_RENAME(uprv_decNumberSquareRoot) +#define uprv_decNumberSubtract U_ICU_ENTRY_POINT_RENAME(uprv_decNumberSubtract) +#define uprv_decNumberToEngString U_ICU_ENTRY_POINT_RENAME(uprv_decNumberToEngString) +#define uprv_decNumberToInt32 U_ICU_ENTRY_POINT_RENAME(uprv_decNumberToInt32) +#define uprv_decNumberToIntegralExact U_ICU_ENTRY_POINT_RENAME(uprv_decNumberToIntegralExact) +#define uprv_decNumberToIntegralValue U_ICU_ENTRY_POINT_RENAME(uprv_decNumberToIntegralValue) +#define uprv_decNumberToString U_ICU_ENTRY_POINT_RENAME(uprv_decNumberToString) +#define uprv_decNumberToUInt32 U_ICU_ENTRY_POINT_RENAME(uprv_decNumberToUInt32) +#define uprv_decNumberTrim U_ICU_ENTRY_POINT_RENAME(uprv_decNumberTrim) +#define uprv_decNumberVersion U_ICU_ENTRY_POINT_RENAME(uprv_decNumberVersion) +#define uprv_decNumberXor U_ICU_ENTRY_POINT_RENAME(uprv_decNumberXor) +#define uprv_decNumberZero U_ICU_ENTRY_POINT_RENAME(uprv_decNumberZero) +#define uprv_delete_collIterate U_ICU_ENTRY_POINT_RENAME(uprv_delete_collIterate) +#define uprv_dl_close U_ICU_ENTRY_POINT_RENAME(uprv_dl_close) +#define uprv_dl_open U_ICU_ENTRY_POINT_RENAME(uprv_dl_open) +#define uprv_dl_sym U_ICU_ENTRY_POINT_RENAME(uprv_dl_sym) +#define uprv_eastrncpy U_ICU_ENTRY_POINT_RENAME(uprv_eastrncpy) +#define uprv_ebcdicFromAscii U_ICU_ENTRY_POINT_RENAME(uprv_ebcdicFromAscii) +#define uprv_ebcdictolower U_ICU_ENTRY_POINT_RENAME(uprv_ebcdictolower) +#define uprv_fabs U_ICU_ENTRY_POINT_RENAME(uprv_fabs) +#define uprv_floor U_ICU_ENTRY_POINT_RENAME(uprv_floor) +#define uprv_fmax U_ICU_ENTRY_POINT_RENAME(uprv_fmax) +#define uprv_fmin U_ICU_ENTRY_POINT_RENAME(uprv_fmin) +#define uprv_fmod U_ICU_ENTRY_POINT_RENAME(uprv_fmod) +#define uprv_free U_ICU_ENTRY_POINT_RENAME(uprv_free) +#define uprv_getCharNameCharacters U_ICU_ENTRY_POINT_RENAME(uprv_getCharNameCharacters) +#define uprv_getDefaultCodepage U_ICU_ENTRY_POINT_RENAME(uprv_getDefaultCodepage) +#define uprv_getDefaultLocaleID U_ICU_ENTRY_POINT_RENAME(uprv_getDefaultLocaleID) +#define uprv_getInfinity U_ICU_ENTRY_POINT_RENAME(uprv_getInfinity) +#define uprv_getMaxCharNameLength U_ICU_ENTRY_POINT_RENAME(uprv_getMaxCharNameLength) +#define uprv_getMaxValues U_ICU_ENTRY_POINT_RENAME(uprv_getMaxValues) +#define uprv_getNaN U_ICU_ENTRY_POINT_RENAME(uprv_getNaN) +#define uprv_getRawUTCtime U_ICU_ENTRY_POINT_RENAME(uprv_getRawUTCtime) +#define uprv_getStaticCurrencyName U_ICU_ENTRY_POINT_RENAME(uprv_getStaticCurrencyName) +#define uprv_getUTCtime U_ICU_ENTRY_POINT_RENAME(uprv_getUTCtime) +#define uprv_haveProperties U_ICU_ENTRY_POINT_RENAME(uprv_haveProperties) +#define uprv_init_collIterate U_ICU_ENTRY_POINT_RENAME(uprv_init_collIterate) +#define uprv_init_pce U_ICU_ENTRY_POINT_RENAME(uprv_init_pce) +#define uprv_int32Comparator U_ICU_ENTRY_POINT_RENAME(uprv_int32Comparator) +#define uprv_isInfinite U_ICU_ENTRY_POINT_RENAME(uprv_isInfinite) +#define uprv_isInvariantString U_ICU_ENTRY_POINT_RENAME(uprv_isInvariantString) +#define uprv_isInvariantUString U_ICU_ENTRY_POINT_RENAME(uprv_isInvariantUString) +#define uprv_isNaN U_ICU_ENTRY_POINT_RENAME(uprv_isNaN) +#define uprv_isNegativeInfinity U_ICU_ENTRY_POINT_RENAME(uprv_isNegativeInfinity) +#define uprv_isPositiveInfinity U_ICU_ENTRY_POINT_RENAME(uprv_isPositiveInfinity) +#define uprv_isRuleWhiteSpace U_ICU_ENTRY_POINT_RENAME(uprv_isRuleWhiteSpace) +#define uprv_itou U_ICU_ENTRY_POINT_RENAME(uprv_itou) +#define uprv_log U_ICU_ENTRY_POINT_RENAME(uprv_log) +#define uprv_malloc U_ICU_ENTRY_POINT_RENAME(uprv_malloc) +#define uprv_mapFile U_ICU_ENTRY_POINT_RENAME(uprv_mapFile) +#define uprv_max U_ICU_ENTRY_POINT_RENAME(uprv_max) +#define uprv_maxMantissa U_ICU_ENTRY_POINT_RENAME(uprv_maxMantissa) +#define uprv_maximumPtr U_ICU_ENTRY_POINT_RENAME(uprv_maximumPtr) +#define uprv_min U_ICU_ENTRY_POINT_RENAME(uprv_min) +#define uprv_modf U_ICU_ENTRY_POINT_RENAME(uprv_modf) +#define uprv_new_collIterate U_ICU_ENTRY_POINT_RENAME(uprv_new_collIterate) +#define uprv_openRuleWhiteSpaceSet U_ICU_ENTRY_POINT_RENAME(uprv_openRuleWhiteSpaceSet) +#define uprv_parseCurrency U_ICU_ENTRY_POINT_RENAME(uprv_parseCurrency) +#define uprv_pathIsAbsolute U_ICU_ENTRY_POINT_RENAME(uprv_pathIsAbsolute) +#define uprv_pow U_ICU_ENTRY_POINT_RENAME(uprv_pow) +#define uprv_pow10 U_ICU_ENTRY_POINT_RENAME(uprv_pow10) +#define uprv_realloc U_ICU_ENTRY_POINT_RENAME(uprv_realloc) +#define uprv_round U_ICU_ENTRY_POINT_RENAME(uprv_round) +#define uprv_sortArray U_ICU_ENTRY_POINT_RENAME(uprv_sortArray) +#define uprv_strCompare U_ICU_ENTRY_POINT_RENAME(uprv_strCompare) +#define uprv_strdup U_ICU_ENTRY_POINT_RENAME(uprv_strdup) +#define uprv_strndup U_ICU_ENTRY_POINT_RENAME(uprv_strndup) +#define uprv_syntaxError U_ICU_ENTRY_POINT_RENAME(uprv_syntaxError) +#define uprv_timezone U_ICU_ENTRY_POINT_RENAME(uprv_timezone) +#define uprv_toupper U_ICU_ENTRY_POINT_RENAME(uprv_toupper) +#define uprv_trunc U_ICU_ENTRY_POINT_RENAME(uprv_trunc) +#define uprv_tzname U_ICU_ENTRY_POINT_RENAME(uprv_tzname) +#define uprv_tzset U_ICU_ENTRY_POINT_RENAME(uprv_tzset) +#define uprv_uca_addAnElement U_ICU_ENTRY_POINT_RENAME(uprv_uca_addAnElement) +#define uprv_uca_assembleTable U_ICU_ENTRY_POINT_RENAME(uprv_uca_assembleTable) +#define uprv_uca_canonicalClosure U_ICU_ENTRY_POINT_RENAME(uprv_uca_canonicalClosure) +#define uprv_uca_closeTempTable U_ICU_ENTRY_POINT_RENAME(uprv_uca_closeTempTable) +#define uprv_uca_getCodePointFromRaw U_ICU_ENTRY_POINT_RENAME(uprv_uca_getCodePointFromRaw) +#define uprv_uca_getImplicitFromRaw U_ICU_ENTRY_POINT_RENAME(uprv_uca_getImplicitFromRaw) +#define uprv_uca_getRawFromCodePoint U_ICU_ENTRY_POINT_RENAME(uprv_uca_getRawFromCodePoint) +#define uprv_uca_getRawFromImplicit U_ICU_ENTRY_POINT_RENAME(uprv_uca_getRawFromImplicit) +#define uprv_uca_initImplicitConstants U_ICU_ENTRY_POINT_RENAME(uprv_uca_initImplicitConstants) +#define uprv_uca_initTempTable U_ICU_ENTRY_POINT_RENAME(uprv_uca_initTempTable) +#define uprv_uint16Comparator U_ICU_ENTRY_POINT_RENAME(uprv_uint16Comparator) +#define uprv_uint32Comparator U_ICU_ENTRY_POINT_RENAME(uprv_uint32Comparator) +#define uprv_unmapFile U_ICU_ENTRY_POINT_RENAME(uprv_unmapFile) +#define upvec_cloneArray U_ICU_ENTRY_POINT_RENAME(upvec_cloneArray) +#define upvec_close U_ICU_ENTRY_POINT_RENAME(upvec_close) +#define upvec_compact U_ICU_ENTRY_POINT_RENAME(upvec_compact) +#define upvec_compactToUTrie2Handler U_ICU_ENTRY_POINT_RENAME(upvec_compactToUTrie2Handler) +#define upvec_compactToUTrie2WithRowIndexes U_ICU_ENTRY_POINT_RENAME(upvec_compactToUTrie2WithRowIndexes) +#define upvec_getArray U_ICU_ENTRY_POINT_RENAME(upvec_getArray) +#define upvec_getRow U_ICU_ENTRY_POINT_RENAME(upvec_getRow) +#define upvec_getValue U_ICU_ENTRY_POINT_RENAME(upvec_getValue) +#define upvec_open U_ICU_ENTRY_POINT_RENAME(upvec_open) +#define upvec_setValue U_ICU_ENTRY_POINT_RENAME(upvec_setValue) +#define uregex_appendReplacement U_ICU_ENTRY_POINT_RENAME(uregex_appendReplacement) +#define uregex_appendReplacementUText U_ICU_ENTRY_POINT_RENAME(uregex_appendReplacementUText) +#define uregex_appendTail U_ICU_ENTRY_POINT_RENAME(uregex_appendTail) +#define uregex_appendTailUText U_ICU_ENTRY_POINT_RENAME(uregex_appendTailUText) +#define uregex_clone U_ICU_ENTRY_POINT_RENAME(uregex_clone) +#define uregex_close U_ICU_ENTRY_POINT_RENAME(uregex_close) +#define uregex_end U_ICU_ENTRY_POINT_RENAME(uregex_end) +#define uregex_end64 U_ICU_ENTRY_POINT_RENAME(uregex_end64) +#define uregex_find U_ICU_ENTRY_POINT_RENAME(uregex_find) +#define uregex_find64 U_ICU_ENTRY_POINT_RENAME(uregex_find64) +#define uregex_findNext U_ICU_ENTRY_POINT_RENAME(uregex_findNext) +#define uregex_flags U_ICU_ENTRY_POINT_RENAME(uregex_flags) +#define uregex_getFindProgressCallback U_ICU_ENTRY_POINT_RENAME(uregex_getFindProgressCallback) +#define uregex_getMatchCallback U_ICU_ENTRY_POINT_RENAME(uregex_getMatchCallback) +#define uregex_getStackLimit U_ICU_ENTRY_POINT_RENAME(uregex_getStackLimit) +#define uregex_getText U_ICU_ENTRY_POINT_RENAME(uregex_getText) +#define uregex_getTimeLimit U_ICU_ENTRY_POINT_RENAME(uregex_getTimeLimit) +#define uregex_getUText U_ICU_ENTRY_POINT_RENAME(uregex_getUText) +#define uregex_group U_ICU_ENTRY_POINT_RENAME(uregex_group) +#define uregex_groupCount U_ICU_ENTRY_POINT_RENAME(uregex_groupCount) +#define uregex_groupUText U_ICU_ENTRY_POINT_RENAME(uregex_groupUText) +#define uregex_groupUTextDeep U_ICU_ENTRY_POINT_RENAME(uregex_groupUTextDeep) +#define uregex_hasAnchoringBounds U_ICU_ENTRY_POINT_RENAME(uregex_hasAnchoringBounds) +#define uregex_hasTransparentBounds U_ICU_ENTRY_POINT_RENAME(uregex_hasTransparentBounds) +#define uregex_hitEnd U_ICU_ENTRY_POINT_RENAME(uregex_hitEnd) +#define uregex_lookingAt U_ICU_ENTRY_POINT_RENAME(uregex_lookingAt) +#define uregex_lookingAt64 U_ICU_ENTRY_POINT_RENAME(uregex_lookingAt64) +#define uregex_matches U_ICU_ENTRY_POINT_RENAME(uregex_matches) +#define uregex_matches64 U_ICU_ENTRY_POINT_RENAME(uregex_matches64) +#define uregex_open U_ICU_ENTRY_POINT_RENAME(uregex_open) +#define uregex_openC U_ICU_ENTRY_POINT_RENAME(uregex_openC) +#define uregex_openUText U_ICU_ENTRY_POINT_RENAME(uregex_openUText) +#define uregex_pattern U_ICU_ENTRY_POINT_RENAME(uregex_pattern) +#define uregex_patternUText U_ICU_ENTRY_POINT_RENAME(uregex_patternUText) +#define uregex_regionEnd U_ICU_ENTRY_POINT_RENAME(uregex_regionEnd) +#define uregex_regionEnd64 U_ICU_ENTRY_POINT_RENAME(uregex_regionEnd64) +#define uregex_regionStart U_ICU_ENTRY_POINT_RENAME(uregex_regionStart) +#define uregex_regionStart64 U_ICU_ENTRY_POINT_RENAME(uregex_regionStart64) +#define uregex_replaceAll U_ICU_ENTRY_POINT_RENAME(uregex_replaceAll) +#define uregex_replaceAllUText U_ICU_ENTRY_POINT_RENAME(uregex_replaceAllUText) +#define uregex_replaceFirst U_ICU_ENTRY_POINT_RENAME(uregex_replaceFirst) +#define uregex_replaceFirstUText U_ICU_ENTRY_POINT_RENAME(uregex_replaceFirstUText) +#define uregex_requireEnd U_ICU_ENTRY_POINT_RENAME(uregex_requireEnd) +#define uregex_reset U_ICU_ENTRY_POINT_RENAME(uregex_reset) +#define uregex_reset64 U_ICU_ENTRY_POINT_RENAME(uregex_reset64) +#define uregex_setFindProgressCallback U_ICU_ENTRY_POINT_RENAME(uregex_setFindProgressCallback) +#define uregex_setMatchCallback U_ICU_ENTRY_POINT_RENAME(uregex_setMatchCallback) +#define uregex_setRegion U_ICU_ENTRY_POINT_RENAME(uregex_setRegion) +#define uregex_setRegion64 U_ICU_ENTRY_POINT_RENAME(uregex_setRegion64) +#define uregex_setRegionAndStart U_ICU_ENTRY_POINT_RENAME(uregex_setRegionAndStart) +#define uregex_setStackLimit U_ICU_ENTRY_POINT_RENAME(uregex_setStackLimit) +#define uregex_setText U_ICU_ENTRY_POINT_RENAME(uregex_setText) +#define uregex_setTimeLimit U_ICU_ENTRY_POINT_RENAME(uregex_setTimeLimit) +#define uregex_setUText U_ICU_ENTRY_POINT_RENAME(uregex_setUText) +#define uregex_split U_ICU_ENTRY_POINT_RENAME(uregex_split) +#define uregex_splitUText U_ICU_ENTRY_POINT_RENAME(uregex_splitUText) +#define uregex_start U_ICU_ENTRY_POINT_RENAME(uregex_start) +#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_useAnchoringBounds U_ICU_ENTRY_POINT_RENAME(uregex_useAnchoringBounds) +#define uregex_useTransparentBounds U_ICU_ENTRY_POINT_RENAME(uregex_useTransparentBounds) +#define uregex_utext_unescape_charAt U_ICU_ENTRY_POINT_RENAME(uregex_utext_unescape_charAt) +#define ures_close U_ICU_ENTRY_POINT_RENAME(ures_close) +#define ures_copyResb U_ICU_ENTRY_POINT_RENAME(ures_copyResb) +#define ures_countArrayItems U_ICU_ENTRY_POINT_RENAME(ures_countArrayItems) +#define ures_findResource U_ICU_ENTRY_POINT_RENAME(ures_findResource) +#define ures_findSubResource U_ICU_ENTRY_POINT_RENAME(ures_findSubResource) +#define ures_getBinary U_ICU_ENTRY_POINT_RENAME(ures_getBinary) +#define ures_getByIndex U_ICU_ENTRY_POINT_RENAME(ures_getByIndex) +#define ures_getByKey U_ICU_ENTRY_POINT_RENAME(ures_getByKey) +#define ures_getByKeyWithFallback U_ICU_ENTRY_POINT_RENAME(ures_getByKeyWithFallback) +#define ures_getFunctionalEquivalent U_ICU_ENTRY_POINT_RENAME(ures_getFunctionalEquivalent) +#define ures_getInt U_ICU_ENTRY_POINT_RENAME(ures_getInt) +#define ures_getIntVector U_ICU_ENTRY_POINT_RENAME(ures_getIntVector) +#define ures_getKey U_ICU_ENTRY_POINT_RENAME(ures_getKey) +#define ures_getKeywordValues U_ICU_ENTRY_POINT_RENAME(ures_getKeywordValues) +#define ures_getLocale U_ICU_ENTRY_POINT_RENAME(ures_getLocale) +#define ures_getLocaleByType U_ICU_ENTRY_POINT_RENAME(ures_getLocaleByType) +#define ures_getLocaleInternal U_ICU_ENTRY_POINT_RENAME(ures_getLocaleInternal) +#define ures_getName U_ICU_ENTRY_POINT_RENAME(ures_getName) +#define ures_getNextResource U_ICU_ENTRY_POINT_RENAME(ures_getNextResource) +#define ures_getNextString U_ICU_ENTRY_POINT_RENAME(ures_getNextString) +#define ures_getSize U_ICU_ENTRY_POINT_RENAME(ures_getSize) +#define ures_getString U_ICU_ENTRY_POINT_RENAME(ures_getString) +#define ures_getStringByIndex U_ICU_ENTRY_POINT_RENAME(ures_getStringByIndex) +#define ures_getStringByKey U_ICU_ENTRY_POINT_RENAME(ures_getStringByKey) +#define ures_getStringByKeyWithFallback U_ICU_ENTRY_POINT_RENAME(ures_getStringByKeyWithFallback) +#define ures_getType U_ICU_ENTRY_POINT_RENAME(ures_getType) +#define ures_getUInt U_ICU_ENTRY_POINT_RENAME(ures_getUInt) +#define ures_getUTF8String U_ICU_ENTRY_POINT_RENAME(ures_getUTF8String) +#define ures_getUTF8StringByIndex U_ICU_ENTRY_POINT_RENAME(ures_getUTF8StringByIndex) +#define ures_getUTF8StringByKey U_ICU_ENTRY_POINT_RENAME(ures_getUTF8StringByKey) +#define ures_getVersion U_ICU_ENTRY_POINT_RENAME(ures_getVersion) +#define ures_getVersionByKey U_ICU_ENTRY_POINT_RENAME(ures_getVersionByKey) +#define ures_getVersionNumber U_ICU_ENTRY_POINT_RENAME(ures_getVersionNumber) +#define ures_getVersionNumberInternal U_ICU_ENTRY_POINT_RENAME(ures_getVersionNumberInternal) +#define ures_hasNext U_ICU_ENTRY_POINT_RENAME(ures_hasNext) +#define ures_initStackObject U_ICU_ENTRY_POINT_RENAME(ures_initStackObject) +#define ures_open U_ICU_ENTRY_POINT_RENAME(ures_open) +#define ures_openAvailableLocales U_ICU_ENTRY_POINT_RENAME(ures_openAvailableLocales) +#define ures_openDirect U_ICU_ENTRY_POINT_RENAME(ures_openDirect) +#define ures_openFillIn U_ICU_ENTRY_POINT_RENAME(ures_openFillIn) +#define ures_openU U_ICU_ENTRY_POINT_RENAME(ures_openU) +#define ures_resetIterator U_ICU_ENTRY_POINT_RENAME(ures_resetIterator) +#define ures_swap U_ICU_ENTRY_POINT_RENAME(ures_swap) +#define uscript_closeRun U_ICU_ENTRY_POINT_RENAME(uscript_closeRun) +#define uscript_getCode U_ICU_ENTRY_POINT_RENAME(uscript_getCode) +#define uscript_getName U_ICU_ENTRY_POINT_RENAME(uscript_getName) +#define uscript_getScript U_ICU_ENTRY_POINT_RENAME(uscript_getScript) +#define uscript_getScriptExtensions U_ICU_ENTRY_POINT_RENAME(uscript_getScriptExtensions) +#define uscript_getShortName U_ICU_ENTRY_POINT_RENAME(uscript_getShortName) +#define uscript_hasScript U_ICU_ENTRY_POINT_RENAME(uscript_hasScript) +#define uscript_nextRun U_ICU_ENTRY_POINT_RENAME(uscript_nextRun) +#define uscript_openRun U_ICU_ENTRY_POINT_RENAME(uscript_openRun) +#define uscript_resetRun U_ICU_ENTRY_POINT_RENAME(uscript_resetRun) +#define uscript_setRunText U_ICU_ENTRY_POINT_RENAME(uscript_setRunText) +#define usearch_close U_ICU_ENTRY_POINT_RENAME(usearch_close) +#define usearch_first U_ICU_ENTRY_POINT_RENAME(usearch_first) +#define usearch_following U_ICU_ENTRY_POINT_RENAME(usearch_following) +#define usearch_getAttribute U_ICU_ENTRY_POINT_RENAME(usearch_getAttribute) +#define usearch_getBreakIterator U_ICU_ENTRY_POINT_RENAME(usearch_getBreakIterator) +#define usearch_getCollator U_ICU_ENTRY_POINT_RENAME(usearch_getCollator) +#define usearch_getMatchedLength U_ICU_ENTRY_POINT_RENAME(usearch_getMatchedLength) +#define usearch_getMatchedStart U_ICU_ENTRY_POINT_RENAME(usearch_getMatchedStart) +#define usearch_getMatchedText U_ICU_ENTRY_POINT_RENAME(usearch_getMatchedText) +#define usearch_getOffset U_ICU_ENTRY_POINT_RENAME(usearch_getOffset) +#define usearch_getPattern U_ICU_ENTRY_POINT_RENAME(usearch_getPattern) +#define usearch_getText U_ICU_ENTRY_POINT_RENAME(usearch_getText) +#define usearch_handleNextCanonical U_ICU_ENTRY_POINT_RENAME(usearch_handleNextCanonical) +#define usearch_handleNextExact U_ICU_ENTRY_POINT_RENAME(usearch_handleNextExact) +#define usearch_handlePreviousCanonical U_ICU_ENTRY_POINT_RENAME(usearch_handlePreviousCanonical) +#define usearch_handlePreviousExact U_ICU_ENTRY_POINT_RENAME(usearch_handlePreviousExact) +#define usearch_last U_ICU_ENTRY_POINT_RENAME(usearch_last) +#define usearch_next U_ICU_ENTRY_POINT_RENAME(usearch_next) +#define usearch_open U_ICU_ENTRY_POINT_RENAME(usearch_open) +#define usearch_openFromCollator U_ICU_ENTRY_POINT_RENAME(usearch_openFromCollator) +#define usearch_preceding U_ICU_ENTRY_POINT_RENAME(usearch_preceding) +#define usearch_previous U_ICU_ENTRY_POINT_RENAME(usearch_previous) +#define usearch_reset U_ICU_ENTRY_POINT_RENAME(usearch_reset) +#define usearch_search U_ICU_ENTRY_POINT_RENAME(usearch_search) +#define usearch_searchBackwards U_ICU_ENTRY_POINT_RENAME(usearch_searchBackwards) +#define usearch_setAttribute U_ICU_ENTRY_POINT_RENAME(usearch_setAttribute) +#define usearch_setBreakIterator U_ICU_ENTRY_POINT_RENAME(usearch_setBreakIterator) +#define usearch_setCollator U_ICU_ENTRY_POINT_RENAME(usearch_setCollator) +#define usearch_setOffset U_ICU_ENTRY_POINT_RENAME(usearch_setOffset) +#define usearch_setPattern U_ICU_ENTRY_POINT_RENAME(usearch_setPattern) +#define usearch_setText U_ICU_ENTRY_POINT_RENAME(usearch_setText) +#define uset_add U_ICU_ENTRY_POINT_RENAME(uset_add) +#define uset_addAll U_ICU_ENTRY_POINT_RENAME(uset_addAll) +#define uset_addAllCodePoints U_ICU_ENTRY_POINT_RENAME(uset_addAllCodePoints) +#define uset_addRange U_ICU_ENTRY_POINT_RENAME(uset_addRange) +#define uset_addString U_ICU_ENTRY_POINT_RENAME(uset_addString) +#define uset_applyIntPropertyValue U_ICU_ENTRY_POINT_RENAME(uset_applyIntPropertyValue) +#define uset_applyPattern U_ICU_ENTRY_POINT_RENAME(uset_applyPattern) +#define uset_applyPropertyAlias U_ICU_ENTRY_POINT_RENAME(uset_applyPropertyAlias) +#define uset_charAt U_ICU_ENTRY_POINT_RENAME(uset_charAt) +#define uset_clear U_ICU_ENTRY_POINT_RENAME(uset_clear) +#define uset_clone U_ICU_ENTRY_POINT_RENAME(uset_clone) +#define uset_cloneAsThawed U_ICU_ENTRY_POINT_RENAME(uset_cloneAsThawed) +#define uset_close U_ICU_ENTRY_POINT_RENAME(uset_close) +#define uset_closeOver U_ICU_ENTRY_POINT_RENAME(uset_closeOver) +#define uset_compact U_ICU_ENTRY_POINT_RENAME(uset_compact) +#define uset_complement U_ICU_ENTRY_POINT_RENAME(uset_complement) +#define uset_complementAll U_ICU_ENTRY_POINT_RENAME(uset_complementAll) +#define uset_contains U_ICU_ENTRY_POINT_RENAME(uset_contains) +#define uset_containsAll U_ICU_ENTRY_POINT_RENAME(uset_containsAll) +#define uset_containsAllCodePoints U_ICU_ENTRY_POINT_RENAME(uset_containsAllCodePoints) +#define uset_containsNone U_ICU_ENTRY_POINT_RENAME(uset_containsNone) +#define uset_containsRange U_ICU_ENTRY_POINT_RENAME(uset_containsRange) +#define uset_containsSome U_ICU_ENTRY_POINT_RENAME(uset_containsSome) +#define uset_containsString U_ICU_ENTRY_POINT_RENAME(uset_containsString) +#define uset_equals U_ICU_ENTRY_POINT_RENAME(uset_equals) +#define uset_freeze U_ICU_ENTRY_POINT_RENAME(uset_freeze) +#define uset_getItem U_ICU_ENTRY_POINT_RENAME(uset_getItem) +#define uset_getItemCount U_ICU_ENTRY_POINT_RENAME(uset_getItemCount) +#define uset_getSerializedRange U_ICU_ENTRY_POINT_RENAME(uset_getSerializedRange) +#define uset_getSerializedRangeCount U_ICU_ENTRY_POINT_RENAME(uset_getSerializedRangeCount) +#define uset_getSerializedSet U_ICU_ENTRY_POINT_RENAME(uset_getSerializedSet) +#define uset_indexOf U_ICU_ENTRY_POINT_RENAME(uset_indexOf) +#define uset_isEmpty U_ICU_ENTRY_POINT_RENAME(uset_isEmpty) +#define uset_isFrozen U_ICU_ENTRY_POINT_RENAME(uset_isFrozen) +#define uset_open U_ICU_ENTRY_POINT_RENAME(uset_open) +#define uset_openEmpty U_ICU_ENTRY_POINT_RENAME(uset_openEmpty) +#define uset_openPattern U_ICU_ENTRY_POINT_RENAME(uset_openPattern) +#define uset_openPatternOptions U_ICU_ENTRY_POINT_RENAME(uset_openPatternOptions) +#define uset_remove U_ICU_ENTRY_POINT_RENAME(uset_remove) +#define uset_removeAll U_ICU_ENTRY_POINT_RENAME(uset_removeAll) +#define uset_removeAllStrings U_ICU_ENTRY_POINT_RENAME(uset_removeAllStrings) +#define uset_removeRange U_ICU_ENTRY_POINT_RENAME(uset_removeRange) +#define uset_removeString U_ICU_ENTRY_POINT_RENAME(uset_removeString) +#define uset_resemblesPattern U_ICU_ENTRY_POINT_RENAME(uset_resemblesPattern) +#define uset_retain U_ICU_ENTRY_POINT_RENAME(uset_retain) +#define uset_retainAll U_ICU_ENTRY_POINT_RENAME(uset_retainAll) +#define uset_serialize U_ICU_ENTRY_POINT_RENAME(uset_serialize) +#define uset_serializedContains U_ICU_ENTRY_POINT_RENAME(uset_serializedContains) +#define uset_set U_ICU_ENTRY_POINT_RENAME(uset_set) +#define uset_setSerializedToOne U_ICU_ENTRY_POINT_RENAME(uset_setSerializedToOne) +#define uset_size U_ICU_ENTRY_POINT_RENAME(uset_size) +#define uset_span U_ICU_ENTRY_POINT_RENAME(uset_span) +#define uset_spanBack U_ICU_ENTRY_POINT_RENAME(uset_spanBack) +#define uset_spanBackUTF8 U_ICU_ENTRY_POINT_RENAME(uset_spanBackUTF8) +#define uset_spanUTF8 U_ICU_ENTRY_POINT_RENAME(uset_spanUTF8) +#define uset_toPattern U_ICU_ENTRY_POINT_RENAME(uset_toPattern) +#define uspoof_areConfusable U_ICU_ENTRY_POINT_RENAME(uspoof_areConfusable) +#define uspoof_areConfusableUTF8 U_ICU_ENTRY_POINT_RENAME(uspoof_areConfusableUTF8) +#define uspoof_areConfusableUnicodeString U_ICU_ENTRY_POINT_RENAME(uspoof_areConfusableUnicodeString) +#define uspoof_check U_ICU_ENTRY_POINT_RENAME(uspoof_check) +#define uspoof_checkUTF8 U_ICU_ENTRY_POINT_RENAME(uspoof_checkUTF8) +#define uspoof_checkUnicodeString U_ICU_ENTRY_POINT_RENAME(uspoof_checkUnicodeString) +#define uspoof_clone U_ICU_ENTRY_POINT_RENAME(uspoof_clone) +#define uspoof_close U_ICU_ENTRY_POINT_RENAME(uspoof_close) +#define uspoof_getAllowedChars U_ICU_ENTRY_POINT_RENAME(uspoof_getAllowedChars) +#define uspoof_getAllowedLocales U_ICU_ENTRY_POINT_RENAME(uspoof_getAllowedLocales) +#define uspoof_getAllowedUnicodeSet U_ICU_ENTRY_POINT_RENAME(uspoof_getAllowedUnicodeSet) +#define uspoof_getChecks U_ICU_ENTRY_POINT_RENAME(uspoof_getChecks) +#define uspoof_getSkeleton U_ICU_ENTRY_POINT_RENAME(uspoof_getSkeleton) +#define uspoof_getSkeletonUTF8 U_ICU_ENTRY_POINT_RENAME(uspoof_getSkeletonUTF8) +#define uspoof_getSkeletonUnicodeString U_ICU_ENTRY_POINT_RENAME(uspoof_getSkeletonUnicodeString) +#define uspoof_open U_ICU_ENTRY_POINT_RENAME(uspoof_open) +#define uspoof_openFromSerialized U_ICU_ENTRY_POINT_RENAME(uspoof_openFromSerialized) +#define uspoof_openFromSource U_ICU_ENTRY_POINT_RENAME(uspoof_openFromSource) +#define uspoof_serialize U_ICU_ENTRY_POINT_RENAME(uspoof_serialize) +#define uspoof_setAllowedChars U_ICU_ENTRY_POINT_RENAME(uspoof_setAllowedChars) +#define uspoof_setAllowedLocales U_ICU_ENTRY_POINT_RENAME(uspoof_setAllowedLocales) +#define uspoof_setAllowedUnicodeSet U_ICU_ENTRY_POINT_RENAME(uspoof_setAllowedUnicodeSet) +#define uspoof_setChecks U_ICU_ENTRY_POINT_RENAME(uspoof_setChecks) +#define uspoof_swap U_ICU_ENTRY_POINT_RENAME(uspoof_swap) +#define usprep_close U_ICU_ENTRY_POINT_RENAME(usprep_close) +#define usprep_open U_ICU_ENTRY_POINT_RENAME(usprep_open) +#define usprep_openByType U_ICU_ENTRY_POINT_RENAME(usprep_openByType) +#define usprep_prepare U_ICU_ENTRY_POINT_RENAME(usprep_prepare) +#define usprep_swap U_ICU_ENTRY_POINT_RENAME(usprep_swap) +#define ustr_foldCase U_ICU_ENTRY_POINT_RENAME(ustr_foldCase) +#define ustr_toLower U_ICU_ENTRY_POINT_RENAME(ustr_toLower) +#define ustr_toTitle U_ICU_ENTRY_POINT_RENAME(ustr_toTitle) +#define ustr_toUpper U_ICU_ENTRY_POINT_RENAME(ustr_toUpper) +#define utext_caseCompare U_ICU_ENTRY_POINT_RENAME(utext_caseCompare) +#define utext_caseCompareNativeLimit U_ICU_ENTRY_POINT_RENAME(utext_caseCompareNativeLimit) +#define utext_char32At U_ICU_ENTRY_POINT_RENAME(utext_char32At) +#define utext_clone U_ICU_ENTRY_POINT_RENAME(utext_clone) +#define utext_close U_ICU_ENTRY_POINT_RENAME(utext_close) +#define utext_compare U_ICU_ENTRY_POINT_RENAME(utext_compare) +#define utext_compareNativeLimit U_ICU_ENTRY_POINT_RENAME(utext_compareNativeLimit) +#define utext_copy U_ICU_ENTRY_POINT_RENAME(utext_copy) +#define utext_current32 U_ICU_ENTRY_POINT_RENAME(utext_current32) +#define utext_equals U_ICU_ENTRY_POINT_RENAME(utext_equals) +#define utext_extract U_ICU_ENTRY_POINT_RENAME(utext_extract) +#define utext_freeze U_ICU_ENTRY_POINT_RENAME(utext_freeze) +#define utext_getNativeIndex U_ICU_ENTRY_POINT_RENAME(utext_getNativeIndex) +#define utext_getPreviousNativeIndex U_ICU_ENTRY_POINT_RENAME(utext_getPreviousNativeIndex) +#define utext_hasMetaData U_ICU_ENTRY_POINT_RENAME(utext_hasMetaData) +#define utext_isLengthExpensive U_ICU_ENTRY_POINT_RENAME(utext_isLengthExpensive) +#define utext_isWritable U_ICU_ENTRY_POINT_RENAME(utext_isWritable) +#define utext_moveIndex32 U_ICU_ENTRY_POINT_RENAME(utext_moveIndex32) +#define utext_nativeLength U_ICU_ENTRY_POINT_RENAME(utext_nativeLength) +#define utext_next32 U_ICU_ENTRY_POINT_RENAME(utext_next32) +#define utext_next32From U_ICU_ENTRY_POINT_RENAME(utext_next32From) +#define utext_openCharacterIterator U_ICU_ENTRY_POINT_RENAME(utext_openCharacterIterator) +#define utext_openConstUnicodeString U_ICU_ENTRY_POINT_RENAME(utext_openConstUnicodeString) +#define utext_openReplaceable U_ICU_ENTRY_POINT_RENAME(utext_openReplaceable) +#define utext_openUChars U_ICU_ENTRY_POINT_RENAME(utext_openUChars) +#define utext_openUTF8 U_ICU_ENTRY_POINT_RENAME(utext_openUTF8) +#define utext_openUnicodeString U_ICU_ENTRY_POINT_RENAME(utext_openUnicodeString) +#define utext_previous32 U_ICU_ENTRY_POINT_RENAME(utext_previous32) +#define utext_previous32From U_ICU_ENTRY_POINT_RENAME(utext_previous32From) +#define utext_replace U_ICU_ENTRY_POINT_RENAME(utext_replace) +#define utext_setNativeIndex U_ICU_ENTRY_POINT_RENAME(utext_setNativeIndex) +#define utext_setup U_ICU_ENTRY_POINT_RENAME(utext_setup) +#define utf8_appendCharSafeBody U_ICU_ENTRY_POINT_RENAME(utf8_appendCharSafeBody) +#define utf8_back1SafeBody U_ICU_ENTRY_POINT_RENAME(utf8_back1SafeBody) +#define utf8_countTrailBytes U_ICU_ENTRY_POINT_RENAME(utf8_countTrailBytes) +#define utf8_nextCharSafeBody U_ICU_ENTRY_POINT_RENAME(utf8_nextCharSafeBody) +#define utf8_prevCharSafeBody U_ICU_ENTRY_POINT_RENAME(utf8_prevCharSafeBody) +#define utmscale_fromInt64 U_ICU_ENTRY_POINT_RENAME(utmscale_fromInt64) +#define utmscale_getTimeScaleValue U_ICU_ENTRY_POINT_RENAME(utmscale_getTimeScaleValue) +#define utmscale_toInt64 U_ICU_ENTRY_POINT_RENAME(utmscale_toInt64) +#define utrace_cleanup U_ICU_ENTRY_POINT_RENAME(utrace_cleanup) +#define utrace_data U_ICU_ENTRY_POINT_RENAME(utrace_data) +#define utrace_entry U_ICU_ENTRY_POINT_RENAME(utrace_entry) +#define utrace_exit U_ICU_ENTRY_POINT_RENAME(utrace_exit) +#define utrace_format U_ICU_ENTRY_POINT_RENAME(utrace_format) +#define utrace_functionName U_ICU_ENTRY_POINT_RENAME(utrace_functionName) +#define utrace_getFunctions U_ICU_ENTRY_POINT_RENAME(utrace_getFunctions) +#define utrace_getLevel U_ICU_ENTRY_POINT_RENAME(utrace_getLevel) +#define utrace_level U_ICU_ENTRY_POINT_RENAME(utrace_level) +#define utrace_setFunctions U_ICU_ENTRY_POINT_RENAME(utrace_setFunctions) +#define utrace_setLevel U_ICU_ENTRY_POINT_RENAME(utrace_setLevel) +#define utrace_vformat U_ICU_ENTRY_POINT_RENAME(utrace_vformat) +#define utrans_clone U_ICU_ENTRY_POINT_RENAME(utrans_clone) +#define utrans_close U_ICU_ENTRY_POINT_RENAME(utrans_close) +#define utrans_countAvailableIDs U_ICU_ENTRY_POINT_RENAME(utrans_countAvailableIDs) +#define utrans_getAvailableID U_ICU_ENTRY_POINT_RENAME(utrans_getAvailableID) +#define utrans_getID U_ICU_ENTRY_POINT_RENAME(utrans_getID) +#define utrans_getUnicodeID U_ICU_ENTRY_POINT_RENAME(utrans_getUnicodeID) +#define utrans_open U_ICU_ENTRY_POINT_RENAME(utrans_open) +#define utrans_openIDs U_ICU_ENTRY_POINT_RENAME(utrans_openIDs) +#define utrans_openInverse U_ICU_ENTRY_POINT_RENAME(utrans_openInverse) +#define utrans_openU U_ICU_ENTRY_POINT_RENAME(utrans_openU) +#define utrans_register U_ICU_ENTRY_POINT_RENAME(utrans_register) +#define utrans_rep_caseContextIterator U_ICU_ENTRY_POINT_RENAME(utrans_rep_caseContextIterator) +#define utrans_setFilter U_ICU_ENTRY_POINT_RENAME(utrans_setFilter) +#define utrans_stripRules U_ICU_ENTRY_POINT_RENAME(utrans_stripRules) +#define utrans_trans U_ICU_ENTRY_POINT_RENAME(utrans_trans) +#define utrans_transIncremental U_ICU_ENTRY_POINT_RENAME(utrans_transIncremental) +#define utrans_transIncrementalUChars U_ICU_ENTRY_POINT_RENAME(utrans_transIncrementalUChars) +#define utrans_transUChars U_ICU_ENTRY_POINT_RENAME(utrans_transUChars) +#define utrans_transliterator_cleanup U_ICU_ENTRY_POINT_RENAME(utrans_transliterator_cleanup) +#define utrans_unregister U_ICU_ENTRY_POINT_RENAME(utrans_unregister) +#define utrans_unregisterID U_ICU_ENTRY_POINT_RENAME(utrans_unregisterID) +#define utrie2_clone U_ICU_ENTRY_POINT_RENAME(utrie2_clone) +#define utrie2_cloneAsThawed U_ICU_ENTRY_POINT_RENAME(utrie2_cloneAsThawed) +#define utrie2_close U_ICU_ENTRY_POINT_RENAME(utrie2_close) +#define utrie2_enum U_ICU_ENTRY_POINT_RENAME(utrie2_enum) +#define utrie2_enumForLeadSurrogate U_ICU_ENTRY_POINT_RENAME(utrie2_enumForLeadSurrogate) +#define utrie2_freeze U_ICU_ENTRY_POINT_RENAME(utrie2_freeze) +#define utrie2_fromUTrie U_ICU_ENTRY_POINT_RENAME(utrie2_fromUTrie) +#define utrie2_get32 U_ICU_ENTRY_POINT_RENAME(utrie2_get32) +#define utrie2_get32FromLeadSurrogateCodeUnit U_ICU_ENTRY_POINT_RENAME(utrie2_get32FromLeadSurrogateCodeUnit) +#define utrie2_getVersion U_ICU_ENTRY_POINT_RENAME(utrie2_getVersion) +#define utrie2_internalU8NextIndex U_ICU_ENTRY_POINT_RENAME(utrie2_internalU8NextIndex) +#define utrie2_internalU8PrevIndex U_ICU_ENTRY_POINT_RENAME(utrie2_internalU8PrevIndex) +#define utrie2_isFrozen U_ICU_ENTRY_POINT_RENAME(utrie2_isFrozen) +#define utrie2_open U_ICU_ENTRY_POINT_RENAME(utrie2_open) +#define utrie2_openDummy U_ICU_ENTRY_POINT_RENAME(utrie2_openDummy) +#define utrie2_openFromSerialized U_ICU_ENTRY_POINT_RENAME(utrie2_openFromSerialized) +#define utrie2_serialize U_ICU_ENTRY_POINT_RENAME(utrie2_serialize) +#define utrie2_set32 U_ICU_ENTRY_POINT_RENAME(utrie2_set32) +#define utrie2_set32ForLeadSurrogateCodeUnit U_ICU_ENTRY_POINT_RENAME(utrie2_set32ForLeadSurrogateCodeUnit) +#define utrie2_setRange32 U_ICU_ENTRY_POINT_RENAME(utrie2_setRange32) +#define utrie2_swap U_ICU_ENTRY_POINT_RENAME(utrie2_swap) +#define utrie2_swapAnyVersion U_ICU_ENTRY_POINT_RENAME(utrie2_swapAnyVersion) +#define utrie_clone U_ICU_ENTRY_POINT_RENAME(utrie_clone) +#define utrie_close U_ICU_ENTRY_POINT_RENAME(utrie_close) +#define utrie_defaultGetFoldingOffset U_ICU_ENTRY_POINT_RENAME(utrie_defaultGetFoldingOffset) +#define utrie_enum U_ICU_ENTRY_POINT_RENAME(utrie_enum) +#define utrie_get32 U_ICU_ENTRY_POINT_RENAME(utrie_get32) +#define utrie_getData U_ICU_ENTRY_POINT_RENAME(utrie_getData) +#define utrie_open U_ICU_ENTRY_POINT_RENAME(utrie_open) +#define utrie_serialize U_ICU_ENTRY_POINT_RENAME(utrie_serialize) +#define utrie_set32 U_ICU_ENTRY_POINT_RENAME(utrie_set32) +#define utrie_setRange32 U_ICU_ENTRY_POINT_RENAME(utrie_setRange32) +#define utrie_swap U_ICU_ENTRY_POINT_RENAME(utrie_swap) +#define utrie_unserialize U_ICU_ENTRY_POINT_RENAME(utrie_unserialize) +#define utrie_unserializeDummy U_ICU_ENTRY_POINT_RENAME(utrie_unserializeDummy) +#define vzone_clone U_ICU_ENTRY_POINT_RENAME(vzone_clone) +#define vzone_close U_ICU_ENTRY_POINT_RENAME(vzone_close) +#define vzone_countTransitionRules U_ICU_ENTRY_POINT_RENAME(vzone_countTransitionRules) +#define vzone_equals U_ICU_ENTRY_POINT_RENAME(vzone_equals) +#define vzone_getDynamicClassID U_ICU_ENTRY_POINT_RENAME(vzone_getDynamicClassID) +#define vzone_getLastModified U_ICU_ENTRY_POINT_RENAME(vzone_getLastModified) +#define vzone_getNextTransition U_ICU_ENTRY_POINT_RENAME(vzone_getNextTransition) +#define vzone_getOffset U_ICU_ENTRY_POINT_RENAME(vzone_getOffset) +#define vzone_getOffset2 U_ICU_ENTRY_POINT_RENAME(vzone_getOffset2) +#define vzone_getOffset3 U_ICU_ENTRY_POINT_RENAME(vzone_getOffset3) +#define vzone_getPreviousTransition U_ICU_ENTRY_POINT_RENAME(vzone_getPreviousTransition) +#define vzone_getRawOffset U_ICU_ENTRY_POINT_RENAME(vzone_getRawOffset) +#define vzone_getStaticClassID U_ICU_ENTRY_POINT_RENAME(vzone_getStaticClassID) +#define vzone_getTZURL U_ICU_ENTRY_POINT_RENAME(vzone_getTZURL) +#define vzone_hasSameRules U_ICU_ENTRY_POINT_RENAME(vzone_hasSameRules) +#define vzone_inDaylightTime U_ICU_ENTRY_POINT_RENAME(vzone_inDaylightTime) +#define vzone_openData U_ICU_ENTRY_POINT_RENAME(vzone_openData) +#define vzone_openID U_ICU_ENTRY_POINT_RENAME(vzone_openID) +#define vzone_setLastModified U_ICU_ENTRY_POINT_RENAME(vzone_setLastModified) +#define vzone_setRawOffset U_ICU_ENTRY_POINT_RENAME(vzone_setRawOffset) +#define vzone_setTZURL U_ICU_ENTRY_POINT_RENAME(vzone_setTZURL) +#define vzone_useDaylightTime U_ICU_ENTRY_POINT_RENAME(vzone_useDaylightTime) +#define vzone_write U_ICU_ENTRY_POINT_RENAME(vzone_write) +#define vzone_writeFromStart U_ICU_ENTRY_POINT_RENAME(vzone_writeFromStart) +#define vzone_writeSimple U_ICU_ENTRY_POINT_RENAME(vzone_writeSimple) +#define zrule_close U_ICU_ENTRY_POINT_RENAME(zrule_close) +#define zrule_equals U_ICU_ENTRY_POINT_RENAME(zrule_equals) +#define zrule_getDSTSavings U_ICU_ENTRY_POINT_RENAME(zrule_getDSTSavings) +#define zrule_getName U_ICU_ENTRY_POINT_RENAME(zrule_getName) +#define zrule_getRawOffset U_ICU_ENTRY_POINT_RENAME(zrule_getRawOffset) +#define zrule_isEquivalentTo U_ICU_ENTRY_POINT_RENAME(zrule_isEquivalentTo) +#define ztrans_adoptFrom U_ICU_ENTRY_POINT_RENAME(ztrans_adoptFrom) +#define ztrans_adoptTo U_ICU_ENTRY_POINT_RENAME(ztrans_adoptTo) +#define ztrans_clone U_ICU_ENTRY_POINT_RENAME(ztrans_clone) +#define ztrans_close U_ICU_ENTRY_POINT_RENAME(ztrans_close) +#define ztrans_equals U_ICU_ENTRY_POINT_RENAME(ztrans_equals) +#define ztrans_getDynamicClassID U_ICU_ENTRY_POINT_RENAME(ztrans_getDynamicClassID) +#define ztrans_getFrom U_ICU_ENTRY_POINT_RENAME(ztrans_getFrom) +#define ztrans_getStaticClassID U_ICU_ENTRY_POINT_RENAME(ztrans_getStaticClassID) +#define ztrans_getTime U_ICU_ENTRY_POINT_RENAME(ztrans_getTime) +#define ztrans_getTo U_ICU_ENTRY_POINT_RENAME(ztrans_getTo) +#define ztrans_open U_ICU_ENTRY_POINT_RENAME(ztrans_open) +#define ztrans_openEmpty U_ICU_ENTRY_POINT_RENAME(ztrans_openEmpty) +#define ztrans_setFrom U_ICU_ENTRY_POINT_RENAME(ztrans_setFrom) +#define ztrans_setTime U_ICU_ENTRY_POINT_RENAME(ztrans_setTime) +#define ztrans_setTo U_ICU_ENTRY_POINT_RENAME(ztrans_setTo) + + /* C++ class names renaming defines */ #ifdef XP_CPLUSPLUS #if !U_HAVE_NAMESPACE -#define AbsoluteValueSubstitution AbsoluteValueSubstitution_3_2 -#define AlternateSubstitutionSubtable AlternateSubstitutionSubtable_3_2 -#define AnchorTable AnchorTable_3_2 -#define AnyTransliterator AnyTransliterator_3_2 -#define ArabicOpenTypeLayoutEngine ArabicOpenTypeLayoutEngine_3_2 -#define ArabicShaping ArabicShaping_3_2 -#define BasicCalendarFactory BasicCalendarFactory_3_2 -#define BinarySearchLookupTable BinarySearchLookupTable_3_2 -#define BreakDictionary BreakDictionary_3_2 -#define BreakIterator BreakIterator_3_2 -#define BuddhistCalendar BuddhistCalendar_3_2 -#define CFactory CFactory_3_2 -#define Calendar Calendar_3_2 -#define CalendarAstronomer CalendarAstronomer_3_2 -#define CalendarCache CalendarCache_3_2 -#define CalendarData CalendarData_3_2 -#define CalendarService CalendarService_3_2 -#define CanonShaping CanonShaping_3_2 -#define CanonicalIterator CanonicalIterator_3_2 -#define CaseMapTransliterator CaseMapTransliterator_3_2 -#define ChainingContextualSubstitutionFormat1Subtable ChainingContextualSubstitutionFormat1Subtable_3_2 -#define ChainingContextualSubstitutionFormat2Subtable ChainingContextualSubstitutionFormat2Subtable_3_2 -#define ChainingContextualSubstitutionFormat3Subtable ChainingContextualSubstitutionFormat3Subtable_3_2 -#define ChainingContextualSubstitutionSubtable ChainingContextualSubstitutionSubtable_3_2 -#define CharSubstitutionFilter CharSubstitutionFilter_3_2 -#define CharacterIterator CharacterIterator_3_2 -#define ChoiceFormat ChoiceFormat_3_2 -#define ClassDefFormat1Table ClassDefFormat1Table_3_2 -#define ClassDefFormat2Table ClassDefFormat2Table_3_2 -#define ClassDefinitionTable ClassDefinitionTable_3_2 -#define CollationElementIterator CollationElementIterator_3_2 -#define CollationKey CollationKey_3_2 -#define Collator Collator_3_2 -#define CollatorFactory CollatorFactory_3_2 -#define CompoundTransliterator CompoundTransliterator_3_2 -#define ContextualGlyphSubstitutionProcessor ContextualGlyphSubstitutionProcessor_3_2 -#define ContextualSubstitutionBase ContextualSubstitutionBase_3_2 -#define ContextualSubstitutionFormat1Subtable ContextualSubstitutionFormat1Subtable_3_2 -#define ContextualSubstitutionFormat2Subtable ContextualSubstitutionFormat2Subtable_3_2 -#define ContextualSubstitutionFormat3Subtable ContextualSubstitutionFormat3Subtable_3_2 -#define ContextualSubstitutionSubtable ContextualSubstitutionSubtable_3_2 -#define CoverageFormat1Table CoverageFormat1Table_3_2 -#define CoverageFormat2Table CoverageFormat2Table_3_2 -#define CoverageTable CoverageTable_3_2 -#define CurrencyAmount CurrencyAmount_3_2 -#define CurrencyFormat CurrencyFormat_3_2 -#define CurrencyUnit CurrencyUnit_3_2 -#define CursiveAttachmentSubtable CursiveAttachmentSubtable_3_2 -#define DateFormat DateFormat_3_2 -#define DateFormatSymbols DateFormatSymbols_3_2 -#define DecimalFormat DecimalFormat_3_2 -#define DecimalFormatSymbols DecimalFormatSymbols_3_2 -#define DefaultCalendarFactory DefaultCalendarFactory_3_2 -#define DefaultCharMapper DefaultCharMapper_3_2 -#define DeviceTable DeviceTable_3_2 -#define DictionaryBasedBreakIterator DictionaryBasedBreakIterator_3_2 -#define DictionaryBasedBreakIteratorTables DictionaryBasedBreakIteratorTables_3_2 -#define DigitList DigitList_3_2 -#define Entry Entry_3_2 -#define EnumToOffset EnumToOffset_3_2 -#define EscapeTransliterator EscapeTransliterator_3_2 -#define EventListener EventListener_3_2 -#define ExtensionSubtable ExtensionSubtable_3_2 -#define FeatureListTable FeatureListTable_3_2 -#define FieldPosition FieldPosition_3_2 -#define FontRuns FontRuns_3_2 -#define Format Format_3_2 -#define Format1AnchorTable Format1AnchorTable_3_2 -#define Format2AnchorTable Format2AnchorTable_3_2 -#define Format3AnchorTable Format3AnchorTable_3_2 -#define Formattable Formattable_3_2 -#define ForwardCharacterIterator ForwardCharacterIterator_3_2 -#define FractionalPartSubstitution FractionalPartSubstitution_3_2 -#define FunctionReplacer FunctionReplacer_3_2 -#define GDEFMarkFilter GDEFMarkFilter_3_2 -#define GXLayoutEngine GXLayoutEngine_3_2 -#define GlyphDefinitionTableHeader GlyphDefinitionTableHeader_3_2 -#define GlyphIterator GlyphIterator_3_2 -#define GlyphLookupTableHeader GlyphLookupTableHeader_3_2 -#define GlyphPositioningLookupProcessor GlyphPositioningLookupProcessor_3_2 -#define GlyphPositioningTableHeader GlyphPositioningTableHeader_3_2 -#define GlyphSubstitutionLookupProcessor GlyphSubstitutionLookupProcessor_3_2 -#define GlyphSubstitutionTableHeader GlyphSubstitutionTableHeader_3_2 -#define Grego Grego_3_2 -#define GregorianCalendar GregorianCalendar_3_2 -#define HanOpenTypeLayoutEngine HanOpenTypeLayoutEngine_3_2 -#define HebrewCalendar HebrewCalendar_3_2 -#define ICUBreakIteratorFactory ICUBreakIteratorFactory_3_2 -#define ICUBreakIteratorService ICUBreakIteratorService_3_2 -#define ICUCollatorFactory ICUCollatorFactory_3_2 -#define ICUCollatorService ICUCollatorService_3_2 -#define ICULayoutEngine ICULayoutEngine_3_2 -#define ICULocaleService ICULocaleService_3_2 -#define ICUNotifier ICUNotifier_3_2 -#define ICUNumberFormatFactory ICUNumberFormatFactory_3_2 -#define ICUNumberFormatService ICUNumberFormatService_3_2 -#define ICUResourceBundleFactory ICUResourceBundleFactory_3_2 -#define ICUService ICUService_3_2 -#define ICUServiceFactory ICUServiceFactory_3_2 -#define ICUServiceKey ICUServiceKey_3_2 -#define ICU_Utility ICU_Utility_3_2 -#define IndicClassTable IndicClassTable_3_2 -#define IndicOpenTypeLayoutEngine IndicOpenTypeLayoutEngine_3_2 -#define IndicRearrangementProcessor IndicRearrangementProcessor_3_2 -#define IndicReordering IndicReordering_3_2 -#define IntegralPartSubstitution IntegralPartSubstitution_3_2 -#define IslamicCalendar IslamicCalendar_3_2 -#define JapaneseCalendar JapaneseCalendar_3_2 -#define KeywordEnumeration KeywordEnumeration_3_2 -#define LECharMapper LECharMapper_3_2 -#define LEFontInstance LEFontInstance_3_2 -#define LEGlyphFilter LEGlyphFilter_3_2 -#define LEGlyphStorage LEGlyphStorage_3_2 -#define LEInsertionCallback LEInsertionCallback_3_2 -#define LEInsertionList LEInsertionList_3_2 -#define LXUtilities LXUtilities_3_2 -#define LayoutEngine LayoutEngine_3_2 -#define LigatureSubstitutionProcessor LigatureSubstitutionProcessor_3_2 -#define LigatureSubstitutionSubtable LigatureSubstitutionSubtable_3_2 -#define LocDataParser LocDataParser_3_2 -#define Locale Locale_3_2 -#define LocaleBased LocaleBased_3_2 -#define LocaleKey LocaleKey_3_2 -#define LocaleKeyFactory LocaleKeyFactory_3_2 -#define LocaleRuns LocaleRuns_3_2 -#define LocaleUtility LocaleUtility_3_2 -#define LocalizationInfo LocalizationInfo_3_2 -#define LookupListTable LookupListTable_3_2 -#define LookupProcessor LookupProcessor_3_2 -#define LookupSubtable LookupSubtable_3_2 -#define LookupTable LookupTable_3_2 -#define LowercaseTransliterator LowercaseTransliterator_3_2 -#define MPreFixups MPreFixups_3_2 -#define MarkArray MarkArray_3_2 -#define MarkToBasePositioningSubtable MarkToBasePositioningSubtable_3_2 -#define MarkToLigaturePositioningSubtable MarkToLigaturePositioningSubtable_3_2 -#define MarkToMarkPositioningSubtable MarkToMarkPositioningSubtable_3_2 -#define Math Math_3_2 -#define Measure Measure_3_2 -#define MeasureFormat MeasureFormat_3_2 -#define MeasureUnit MeasureUnit_3_2 -#define MessageFormat MessageFormat_3_2 -#define MessageFormatAdapter MessageFormatAdapter_3_2 -#define ModulusSubstitution ModulusSubstitution_3_2 -#define MoonRiseSetCoordFunc MoonRiseSetCoordFunc_3_2 -#define MoonTimeAngleFunc MoonTimeAngleFunc_3_2 -#define MorphSubtableHeader MorphSubtableHeader_3_2 -#define MorphTableHeader MorphTableHeader_3_2 -#define MultipleSubstitutionSubtable MultipleSubstitutionSubtable_3_2 -#define MultiplierSubstitution MultiplierSubstitution_3_2 -#define NFFactory NFFactory_3_2 -#define NFRule NFRule_3_2 -#define NFRuleSet NFRuleSet_3_2 -#define NFSubstitution NFSubstitution_3_2 -#define NameToEnum NameToEnum_3_2 -#define NameUnicodeTransliterator NameUnicodeTransliterator_3_2 -#define NonContextualGlyphSubstitutionProcessor NonContextualGlyphSubstitutionProcessor_3_2 -#define NonContiguousEnumToOffset NonContiguousEnumToOffset_3_2 -#define NormalizationTransliterator NormalizationTransliterator_3_2 -#define Normalizer Normalizer_3_2 -#define NullSubstitution NullSubstitution_3_2 -#define NullTransliterator NullTransliterator_3_2 -#define NumberFormat NumberFormat_3_2 -#define NumberFormatFactory NumberFormatFactory_3_2 -#define NumeratorSubstitution NumeratorSubstitution_3_2 -#define OlsonTimeZone OlsonTimeZone_3_2 -#define OpenTypeLayoutEngine OpenTypeLayoutEngine_3_2 -#define OpenTypeUtilities OpenTypeUtilities_3_2 -#define PairPositioningFormat1Subtable PairPositioningFormat1Subtable_3_2 -#define PairPositioningFormat2Subtable PairPositioningFormat2Subtable_3_2 -#define PairPositioningSubtable PairPositioningSubtable_3_2 -#define ParagraphLayout ParagraphLayout_3_2 -#define ParseData ParseData_3_2 -#define ParsePosition ParsePosition_3_2 -#define PropertyAliases PropertyAliases_3_2 -#define Quantifier Quantifier_3_2 -#define RBBIDataWrapper RBBIDataWrapper_3_2 -#define RBBINode RBBINode_3_2 -#define RBBIRuleBuilder RBBIRuleBuilder_3_2 -#define RBBIRuleScanner RBBIRuleScanner_3_2 -#define RBBISetBuilder RBBISetBuilder_3_2 -#define RBBIStateDescriptor RBBIStateDescriptor_3_2 -#define RBBISymbolTable RBBISymbolTable_3_2 -#define RBBISymbolTableEntry RBBISymbolTableEntry_3_2 -#define RBBITableBuilder RBBITableBuilder_3_2 -#define RangeDescriptor RangeDescriptor_3_2 -#define RegexCompile RegexCompile_3_2 -#define RegexMatcher RegexMatcher_3_2 -#define RegexPattern RegexPattern_3_2 -#define RegexStaticSets RegexStaticSets_3_2 -#define RemoveTransliterator RemoveTransliterator_3_2 -#define Replaceable Replaceable_3_2 -#define ReplaceableGlue ReplaceableGlue_3_2 -#define ResourceBundle ResourceBundle_3_2 -#define RiseSetCoordFunc RiseSetCoordFunc_3_2 -#define RuleBasedBreakIterator RuleBasedBreakIterator_3_2 -#define RuleBasedCollator RuleBasedCollator_3_2 -#define RuleBasedNumberFormat RuleBasedNumberFormat_3_2 -#define RuleBasedTransliterator RuleBasedTransliterator_3_2 -#define RuleCharacterIterator RuleCharacterIterator_3_2 -#define RuleHalf RuleHalf_3_2 -#define RunArray RunArray_3_2 -#define SameValueSubstitution SameValueSubstitution_3_2 -#define ScriptListTable ScriptListTable_3_2 -#define ScriptRunIterator ScriptRunIterator_3_2 -#define ScriptTable ScriptTable_3_2 -#define SearchIterator SearchIterator_3_2 -#define SegmentArrayProcessor SegmentArrayProcessor_3_2 -#define SegmentSingleProcessor SegmentSingleProcessor_3_2 -#define ServiceEnumeration ServiceEnumeration_3_2 -#define ServiceListener ServiceListener_3_2 -#define SimpleArrayProcessor SimpleArrayProcessor_3_2 -#define SimpleDateFormat SimpleDateFormat_3_2 -#define SimpleFactory SimpleFactory_3_2 -#define SimpleLocaleKeyFactory SimpleLocaleKeyFactory_3_2 -#define SimpleNumberFormatFactory SimpleNumberFormatFactory_3_2 -#define SimpleTimeZone SimpleTimeZone_3_2 -#define SinglePositioningFormat1Subtable SinglePositioningFormat1Subtable_3_2 -#define SinglePositioningFormat2Subtable SinglePositioningFormat2Subtable_3_2 -#define SinglePositioningSubtable SinglePositioningSubtable_3_2 -#define SingleSubstitutionFormat1Subtable SingleSubstitutionFormat1Subtable_3_2 -#define SingleSubstitutionFormat2Subtable SingleSubstitutionFormat2Subtable_3_2 -#define SingleSubstitutionSubtable SingleSubstitutionSubtable_3_2 -#define SingleTableProcessor SingleTableProcessor_3_2 -#define Spec Spec_3_2 -#define StateTableProcessor StateTableProcessor_3_2 -#define StringCharacterIterator StringCharacterIterator_3_2 -#define StringEnumeration StringEnumeration_3_2 -#define StringLocalizationInfo StringLocalizationInfo_3_2 -#define StringMatcher StringMatcher_3_2 -#define StringPair StringPair_3_2 -#define StringReplacer StringReplacer_3_2 -#define StringSearch StringSearch_3_2 -#define StyleRuns StyleRuns_3_2 -#define SubstitutionLookup SubstitutionLookup_3_2 -#define SubtableProcessor SubtableProcessor_3_2 -#define SunTimeAngleFunc SunTimeAngleFunc_3_2 -#define SymbolTable SymbolTable_3_2 -#define TZEnumeration TZEnumeration_3_2 -#define ThaiLayoutEngine ThaiLayoutEngine_3_2 -#define ThaiShaping ThaiShaping_3_2 -#define TimeZone TimeZone_3_2 -#define TitlecaseTransliterator TitlecaseTransliterator_3_2 -#define TransliterationRule TransliterationRule_3_2 -#define TransliterationRuleData TransliterationRuleData_3_2 -#define TransliterationRuleSet TransliterationRuleSet_3_2 -#define Transliterator Transliterator_3_2 -#define TransliteratorAlias TransliteratorAlias_3_2 -#define TransliteratorIDParser TransliteratorIDParser_3_2 -#define TransliteratorParser TransliteratorParser_3_2 -#define TransliteratorRegistry TransliteratorRegistry_3_2 -#define TrimmedArrayProcessor TrimmedArrayProcessor_3_2 -#define UCharCharacterIterator UCharCharacterIterator_3_2 -#define UMemory UMemory_3_2 -#define UObject UObject_3_2 -#define UStack UStack_3_2 -#define UStringEnumeration UStringEnumeration_3_2 -#define UVector UVector_3_2 -#define UVector32 UVector32_3_2 -#define UnescapeTransliterator UnescapeTransliterator_3_2 -#define UnicodeArabicOpenTypeLayoutEngine UnicodeArabicOpenTypeLayoutEngine_3_2 -#define UnicodeFilter UnicodeFilter_3_2 -#define UnicodeFunctor UnicodeFunctor_3_2 -#define UnicodeMatcher UnicodeMatcher_3_2 -#define UnicodeNameTransliterator UnicodeNameTransliterator_3_2 -#define UnicodeReplacer UnicodeReplacer_3_2 -#define UnicodeSet UnicodeSet_3_2 -#define UnicodeSetIterator UnicodeSetIterator_3_2 -#define UnicodeString UnicodeString_3_2 -#define UppercaseTransliterator UppercaseTransliterator_3_2 -#define ValueRecord ValueRecord_3_2 -#define ValueRuns ValueRuns_3_2 -#define locale_set_default_internal locale_set_default_internal_3_2 -#define uprv_parseCurrency uprv_parseCurrency_3_2 -#define util64_fromDouble util64_fromDouble_3_2 -#define util64_pow util64_pow_3_2 -#define util64_tou util64_tou_3_2 -#define util64_utoi util64_utoi_3_2 +#define AbsoluteValueSubstitution U_ICU_ENTRY_POINT_RENAME(AbsoluteValueSubstitution) +#define AlternateSubstitutionSubtable U_ICU_ENTRY_POINT_RENAME(AlternateSubstitutionSubtable) +#define AnchorTable U_ICU_ENTRY_POINT_RENAME(AnchorTable) +#define AndConstraint U_ICU_ENTRY_POINT_RENAME(AndConstraint) +#define AnnualTimeZoneRule U_ICU_ENTRY_POINT_RENAME(AnnualTimeZoneRule) +#define AnyTransliterator U_ICU_ENTRY_POINT_RENAME(AnyTransliterator) +#define ArabicOpenTypeLayoutEngine U_ICU_ENTRY_POINT_RENAME(ArabicOpenTypeLayoutEngine) +#define ArabicShaping U_ICU_ENTRY_POINT_RENAME(ArabicShaping) +#define ArgExtractor U_ICU_ENTRY_POINT_RENAME(ArgExtractor) +#define BMPSet U_ICU_ENTRY_POINT_RENAME(BMPSet) +#define BackwardUTrie2StringIterator U_ICU_ENTRY_POINT_RENAME(BackwardUTrie2StringIterator) +#define BadCharacterTable U_ICU_ENTRY_POINT_RENAME(BadCharacterTable) +#define BasicCalendarFactory U_ICU_ENTRY_POINT_RENAME(BasicCalendarFactory) +#define BasicTimeZone U_ICU_ENTRY_POINT_RENAME(BasicTimeZone) +#define BinarySearchLookupTable U_ICU_ENTRY_POINT_RENAME(BinarySearchLookupTable) +#define BoyerMooreSearch U_ICU_ENTRY_POINT_RENAME(BoyerMooreSearch) +#define BreakIterator U_ICU_ENTRY_POINT_RENAME(BreakIterator) +#define BreakTransliterator U_ICU_ENTRY_POINT_RENAME(BreakTransliterator) +#define BuddhistCalendar U_ICU_ENTRY_POINT_RENAME(BuddhistCalendar) +#define BuildCompactTrieHorizontalNode U_ICU_ENTRY_POINT_RENAME(BuildCompactTrieHorizontalNode) +#define BuildCompactTrieNode U_ICU_ENTRY_POINT_RENAME(BuildCompactTrieNode) +#define BuildCompactTrieVerticalNode U_ICU_ENTRY_POINT_RENAME(BuildCompactTrieVerticalNode) +#define BuilderScriptSet U_ICU_ENTRY_POINT_RENAME(BuilderScriptSet) +#define ByteSink U_ICU_ENTRY_POINT_RENAME(ByteSink) +#define CEBuffer U_ICU_ENTRY_POINT_RENAME(CEBuffer) +#define CECalendar U_ICU_ENTRY_POINT_RENAME(CECalendar) +#define CEList U_ICU_ENTRY_POINT_RENAME(CEList) +#define CEToStringsMap U_ICU_ENTRY_POINT_RENAME(CEToStringsMap) +#define CFactory U_ICU_ENTRY_POINT_RENAME(CFactory) +#define Calendar U_ICU_ENTRY_POINT_RENAME(Calendar) +#define CalendarAstronomer U_ICU_ENTRY_POINT_RENAME(CalendarAstronomer) +#define CalendarCache U_ICU_ENTRY_POINT_RENAME(CalendarCache) +#define CalendarData U_ICU_ENTRY_POINT_RENAME(CalendarData) +#define CalendarService U_ICU_ENTRY_POINT_RENAME(CalendarService) +#define CanonIterData U_ICU_ENTRY_POINT_RENAME(CanonIterData) +#define CanonIterDataSingleton U_ICU_ENTRY_POINT_RENAME(CanonIterDataSingleton) +#define CanonMarkFilter U_ICU_ENTRY_POINT_RENAME(CanonMarkFilter) +#define CanonShaping U_ICU_ENTRY_POINT_RENAME(CanonShaping) +#define CanonicalIterator U_ICU_ENTRY_POINT_RENAME(CanonicalIterator) +#define CaseMapTransliterator U_ICU_ENTRY_POINT_RENAME(CaseMapTransliterator) +#define ChainingContextualSubstitutionFormat1Subtable U_ICU_ENTRY_POINT_RENAME(ChainingContextualSubstitutionFormat1Subtable) +#define ChainingContextualSubstitutionFormat2Subtable U_ICU_ENTRY_POINT_RENAME(ChainingContextualSubstitutionFormat2Subtable) +#define ChainingContextualSubstitutionFormat3Subtable U_ICU_ENTRY_POINT_RENAME(ChainingContextualSubstitutionFormat3Subtable) +#define ChainingContextualSubstitutionSubtable U_ICU_ENTRY_POINT_RENAME(ChainingContextualSubstitutionSubtable) +#define CharString U_ICU_ENTRY_POINT_RENAME(CharString) +#define CharSubstitutionFilter U_ICU_ENTRY_POINT_RENAME(CharSubstitutionFilter) +#define CharacterIterator U_ICU_ENTRY_POINT_RENAME(CharacterIterator) +#define CharacterNode U_ICU_ENTRY_POINT_RENAME(CharacterNode) +#define CharsetDetector U_ICU_ENTRY_POINT_RENAME(CharsetDetector) +#define CharsetMatch U_ICU_ENTRY_POINT_RENAME(CharsetMatch) +#define CharsetRecog_2022 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_2022) +#define CharsetRecog_2022CN U_ICU_ENTRY_POINT_RENAME(CharsetRecog_2022CN) +#define CharsetRecog_2022JP U_ICU_ENTRY_POINT_RENAME(CharsetRecog_2022JP) +#define CharsetRecog_2022KR U_ICU_ENTRY_POINT_RENAME(CharsetRecog_2022KR) +#define CharsetRecog_8859_1 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_1) +#define CharsetRecog_8859_1_da U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_1_da) +#define CharsetRecog_8859_1_de U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_1_de) +#define CharsetRecog_8859_1_en U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_1_en) +#define CharsetRecog_8859_1_es U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_1_es) +#define CharsetRecog_8859_1_fr U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_1_fr) +#define CharsetRecog_8859_1_it U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_1_it) +#define CharsetRecog_8859_1_nl U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_1_nl) +#define CharsetRecog_8859_1_no U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_1_no) +#define CharsetRecog_8859_1_pt U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_1_pt) +#define CharsetRecog_8859_1_sv U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_1_sv) +#define CharsetRecog_8859_2 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_2) +#define CharsetRecog_8859_2_cs U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_2_cs) +#define CharsetRecog_8859_2_hu U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_2_hu) +#define CharsetRecog_8859_2_pl U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_2_pl) +#define CharsetRecog_8859_2_ro U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_2_ro) +#define CharsetRecog_8859_5 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_5) +#define CharsetRecog_8859_5_ru U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_5_ru) +#define CharsetRecog_8859_6 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_6) +#define CharsetRecog_8859_6_ar U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_6_ar) +#define CharsetRecog_8859_7 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_7) +#define CharsetRecog_8859_7_el U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_7_el) +#define CharsetRecog_8859_8 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_8) +#define CharsetRecog_8859_8_I_he U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_8_I_he) +#define CharsetRecog_8859_8_he U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_8_he) +#define CharsetRecog_8859_9 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_9) +#define CharsetRecog_8859_9_tr U_ICU_ENTRY_POINT_RENAME(CharsetRecog_8859_9_tr) +#define CharsetRecog_IBM420_ar U_ICU_ENTRY_POINT_RENAME(CharsetRecog_IBM420_ar) +#define CharsetRecog_IBM420_ar_ltr U_ICU_ENTRY_POINT_RENAME(CharsetRecog_IBM420_ar_ltr) +#define CharsetRecog_IBM420_ar_rtl U_ICU_ENTRY_POINT_RENAME(CharsetRecog_IBM420_ar_rtl) +#define CharsetRecog_IBM424_he U_ICU_ENTRY_POINT_RENAME(CharsetRecog_IBM424_he) +#define CharsetRecog_IBM424_he_ltr U_ICU_ENTRY_POINT_RENAME(CharsetRecog_IBM424_he_ltr) +#define CharsetRecog_IBM424_he_rtl U_ICU_ENTRY_POINT_RENAME(CharsetRecog_IBM424_he_rtl) +#define CharsetRecog_KOI8_R U_ICU_ENTRY_POINT_RENAME(CharsetRecog_KOI8_R) +#define CharsetRecog_UTF8 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_UTF8) +#define CharsetRecog_UTF_16_BE U_ICU_ENTRY_POINT_RENAME(CharsetRecog_UTF_16_BE) +#define CharsetRecog_UTF_16_LE U_ICU_ENTRY_POINT_RENAME(CharsetRecog_UTF_16_LE) +#define CharsetRecog_UTF_32 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_UTF_32) +#define CharsetRecog_UTF_32_BE U_ICU_ENTRY_POINT_RENAME(CharsetRecog_UTF_32_BE) +#define CharsetRecog_UTF_32_LE U_ICU_ENTRY_POINT_RENAME(CharsetRecog_UTF_32_LE) +#define CharsetRecog_Unicode U_ICU_ENTRY_POINT_RENAME(CharsetRecog_Unicode) +#define CharsetRecog_big5 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_big5) +#define CharsetRecog_euc U_ICU_ENTRY_POINT_RENAME(CharsetRecog_euc) +#define CharsetRecog_euc_jp U_ICU_ENTRY_POINT_RENAME(CharsetRecog_euc_jp) +#define CharsetRecog_euc_kr U_ICU_ENTRY_POINT_RENAME(CharsetRecog_euc_kr) +#define CharsetRecog_gb_18030 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_gb_18030) +#define CharsetRecog_mbcs U_ICU_ENTRY_POINT_RENAME(CharsetRecog_mbcs) +#define CharsetRecog_sbcs U_ICU_ENTRY_POINT_RENAME(CharsetRecog_sbcs) +#define CharsetRecog_sjis U_ICU_ENTRY_POINT_RENAME(CharsetRecog_sjis) +#define CharsetRecog_windows_1251 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_windows_1251) +#define CharsetRecog_windows_1256 U_ICU_ENTRY_POINT_RENAME(CharsetRecog_windows_1256) +#define CharsetRecognizer U_ICU_ENTRY_POINT_RENAME(CharsetRecognizer) +#define CheckedArrayByteSink U_ICU_ENTRY_POINT_RENAME(CheckedArrayByteSink) +#define ChineseCalendar U_ICU_ENTRY_POINT_RENAME(ChineseCalendar) +#define ChoiceFormat U_ICU_ENTRY_POINT_RENAME(ChoiceFormat) +#define ClassDefFormat1Table U_ICU_ENTRY_POINT_RENAME(ClassDefFormat1Table) +#define ClassDefFormat2Table U_ICU_ENTRY_POINT_RENAME(ClassDefFormat2Table) +#define ClassDefinitionTable U_ICU_ENTRY_POINT_RENAME(ClassDefinitionTable) +#define ClockMath U_ICU_ENTRY_POINT_RENAME(ClockMath) +#define CollData U_ICU_ENTRY_POINT_RENAME(CollData) +#define CollDataCache U_ICU_ENTRY_POINT_RENAME(CollDataCache) +#define CollDataCacheEntry U_ICU_ENTRY_POINT_RENAME(CollDataCacheEntry) +#define CollationElementIterator U_ICU_ENTRY_POINT_RENAME(CollationElementIterator) +#define CollationKey U_ICU_ENTRY_POINT_RENAME(CollationKey) +#define CollationLocaleListEnumeration U_ICU_ENTRY_POINT_RENAME(CollationLocaleListEnumeration) +#define Collator U_ICU_ENTRY_POINT_RENAME(Collator) +#define CollatorFactory U_ICU_ENTRY_POINT_RENAME(CollatorFactory) +#define CompactTrieDictionary U_ICU_ENTRY_POINT_RENAME(CompactTrieDictionary) +#define CompactTrieEnumeration U_ICU_ENTRY_POINT_RENAME(CompactTrieEnumeration) +#define ComposeNormalizer2 U_ICU_ENTRY_POINT_RENAME(ComposeNormalizer2) +#define CompoundTransliterator U_ICU_ENTRY_POINT_RENAME(CompoundTransliterator) +#define ConfusabledataBuilder U_ICU_ENTRY_POINT_RENAME(ConfusabledataBuilder) +#define ContextualGlyphSubstitutionProcessor U_ICU_ENTRY_POINT_RENAME(ContextualGlyphSubstitutionProcessor) +#define ContextualSubstitutionBase U_ICU_ENTRY_POINT_RENAME(ContextualSubstitutionBase) +#define ContextualSubstitutionFormat1Subtable U_ICU_ENTRY_POINT_RENAME(ContextualSubstitutionFormat1Subtable) +#define ContextualSubstitutionFormat2Subtable U_ICU_ENTRY_POINT_RENAME(ContextualSubstitutionFormat2Subtable) +#define ContextualSubstitutionFormat3Subtable U_ICU_ENTRY_POINT_RENAME(ContextualSubstitutionFormat3Subtable) +#define ContextualSubstitutionSubtable U_ICU_ENTRY_POINT_RENAME(ContextualSubstitutionSubtable) +#define CopticCalendar U_ICU_ENTRY_POINT_RENAME(CopticCalendar) +#define CoverageFormat1Table U_ICU_ENTRY_POINT_RENAME(CoverageFormat1Table) +#define CoverageFormat2Table U_ICU_ENTRY_POINT_RENAME(CoverageFormat2Table) +#define CoverageTable U_ICU_ENTRY_POINT_RENAME(CoverageTable) +#define CurrencyAmount U_ICU_ENTRY_POINT_RENAME(CurrencyAmount) +#define CurrencyFormat U_ICU_ENTRY_POINT_RENAME(CurrencyFormat) +#define CurrencyPluralInfo U_ICU_ENTRY_POINT_RENAME(CurrencyPluralInfo) +#define CurrencyUnit U_ICU_ENTRY_POINT_RENAME(CurrencyUnit) +#define CursiveAttachmentSubtable U_ICU_ENTRY_POINT_RENAME(CursiveAttachmentSubtable) +#define DTRedundantEnumeration U_ICU_ENTRY_POINT_RENAME(DTRedundantEnumeration) +#define DTSkeletonEnumeration U_ICU_ENTRY_POINT_RENAME(DTSkeletonEnumeration) +#define DateFormat U_ICU_ENTRY_POINT_RENAME(DateFormat) +#define DateFormatSymbols U_ICU_ENTRY_POINT_RENAME(DateFormatSymbols) +#define DateInterval U_ICU_ENTRY_POINT_RENAME(DateInterval) +#define DateIntervalFormat U_ICU_ENTRY_POINT_RENAME(DateIntervalFormat) +#define DateIntervalInfo U_ICU_ENTRY_POINT_RENAME(DateIntervalInfo) +#define DateTimeMatcher U_ICU_ENTRY_POINT_RENAME(DateTimeMatcher) +#define DateTimePatternGenerator U_ICU_ENTRY_POINT_RENAME(DateTimePatternGenerator) +#define DateTimeRule U_ICU_ENTRY_POINT_RENAME(DateTimeRule) +#define DecimalFormat U_ICU_ENTRY_POINT_RENAME(DecimalFormat) +#define DecimalFormatSymbols U_ICU_ENTRY_POINT_RENAME(DecimalFormatSymbols) +#define DecomposeNormalizer2 U_ICU_ENTRY_POINT_RENAME(DecomposeNormalizer2) +#define DefaultCalendarFactory U_ICU_ENTRY_POINT_RENAME(DefaultCalendarFactory) +#define DefaultCharMapper U_ICU_ENTRY_POINT_RENAME(DefaultCharMapper) +#define DeviceTable U_ICU_ENTRY_POINT_RENAME(DeviceTable) +#define DictionaryBreakEngine U_ICU_ENTRY_POINT_RENAME(DictionaryBreakEngine) +#define DigitList U_ICU_ENTRY_POINT_RENAME(DigitList) +#define DistanceInfo U_ICU_ENTRY_POINT_RENAME(DistanceInfo) +#define EnumToOffset U_ICU_ENTRY_POINT_RENAME(EnumToOffset) +#define ErrorCode U_ICU_ENTRY_POINT_RENAME(ErrorCode) +#define EscapeTransliterator U_ICU_ENTRY_POINT_RENAME(EscapeTransliterator) +#define EthiopicCalendar U_ICU_ENTRY_POINT_RENAME(EthiopicCalendar) +#define EventListener U_ICU_ENTRY_POINT_RENAME(EventListener) +#define ExtensionSubtable U_ICU_ENTRY_POINT_RENAME(ExtensionSubtable) +#define FCDNormalizer2 U_ICU_ENTRY_POINT_RENAME(FCDNormalizer2) +#define FCDTrieSingleton U_ICU_ENTRY_POINT_RENAME(FCDTrieSingleton) +#define FeatureListTable U_ICU_ENTRY_POINT_RENAME(FeatureListTable) +#define FieldPosition U_ICU_ENTRY_POINT_RENAME(FieldPosition) +#define FieldPositionHandler U_ICU_ENTRY_POINT_RENAME(FieldPositionHandler) +#define FieldPositionIterator U_ICU_ENTRY_POINT_RENAME(FieldPositionIterator) +#define FieldPositionIteratorHandler U_ICU_ENTRY_POINT_RENAME(FieldPositionIteratorHandler) +#define FieldPositionOnlyHandler U_ICU_ENTRY_POINT_RENAME(FieldPositionOnlyHandler) +#define FilteredNormalizer2 U_ICU_ENTRY_POINT_RENAME(FilteredNormalizer2) +#define FontRuns U_ICU_ENTRY_POINT_RENAME(FontRuns) +#define Format U_ICU_ENTRY_POINT_RENAME(Format) +#define Format1AnchorTable U_ICU_ENTRY_POINT_RENAME(Format1AnchorTable) +#define Format2AnchorTable U_ICU_ENTRY_POINT_RENAME(Format2AnchorTable) +#define Format3AnchorTable U_ICU_ENTRY_POINT_RENAME(Format3AnchorTable) +#define FormatNameEnumeration U_ICU_ENTRY_POINT_RENAME(FormatNameEnumeration) +#define FormatParser U_ICU_ENTRY_POINT_RENAME(FormatParser) +#define Formattable U_ICU_ENTRY_POINT_RENAME(Formattable) +#define ForwardCharacterIterator U_ICU_ENTRY_POINT_RENAME(ForwardCharacterIterator) +#define ForwardUTrie2StringIterator U_ICU_ENTRY_POINT_RENAME(ForwardUTrie2StringIterator) +#define FractionalPartSubstitution U_ICU_ENTRY_POINT_RENAME(FractionalPartSubstitution) +#define FunctionReplacer U_ICU_ENTRY_POINT_RENAME(FunctionReplacer) +#define GDEFMarkFilter U_ICU_ENTRY_POINT_RENAME(GDEFMarkFilter) +#define GXLayoutEngine U_ICU_ENTRY_POINT_RENAME(GXLayoutEngine) +#define GlyphDefinitionTableHeader U_ICU_ENTRY_POINT_RENAME(GlyphDefinitionTableHeader) +#define GlyphIterator U_ICU_ENTRY_POINT_RENAME(GlyphIterator) +#define GlyphLookupTableHeader U_ICU_ENTRY_POINT_RENAME(GlyphLookupTableHeader) +#define GlyphPositionAdjustments U_ICU_ENTRY_POINT_RENAME(GlyphPositionAdjustments) +#define GlyphPositioningLookupProcessor U_ICU_ENTRY_POINT_RENAME(GlyphPositioningLookupProcessor) +#define GlyphPositioningTableHeader U_ICU_ENTRY_POINT_RENAME(GlyphPositioningTableHeader) +#define GlyphSubstitutionLookupProcessor U_ICU_ENTRY_POINT_RENAME(GlyphSubstitutionLookupProcessor) +#define GlyphSubstitutionTableHeader U_ICU_ENTRY_POINT_RENAME(GlyphSubstitutionTableHeader) +#define GoodSuffixTable U_ICU_ENTRY_POINT_RENAME(GoodSuffixTable) +#define Grego U_ICU_ENTRY_POINT_RENAME(Grego) +#define GregorianCalendar U_ICU_ENTRY_POINT_RENAME(GregorianCalendar) +#define HanOpenTypeLayoutEngine U_ICU_ENTRY_POINT_RENAME(HanOpenTypeLayoutEngine) +#define HangulOpenTypeLayoutEngine U_ICU_ENTRY_POINT_RENAME(HangulOpenTypeLayoutEngine) +#define HebrewCalendar U_ICU_ENTRY_POINT_RENAME(HebrewCalendar) +#define ICUBreakIteratorFactory U_ICU_ENTRY_POINT_RENAME(ICUBreakIteratorFactory) +#define ICUBreakIteratorService U_ICU_ENTRY_POINT_RENAME(ICUBreakIteratorService) +#define ICUCollatorFactory U_ICU_ENTRY_POINT_RENAME(ICUCollatorFactory) +#define ICUCollatorService U_ICU_ENTRY_POINT_RENAME(ICUCollatorService) +#define ICUDataTable U_ICU_ENTRY_POINT_RENAME(ICUDataTable) +#define ICULanguageBreakFactory U_ICU_ENTRY_POINT_RENAME(ICULanguageBreakFactory) +#define ICULocaleService U_ICU_ENTRY_POINT_RENAME(ICULocaleService) +#define ICUNotifier U_ICU_ENTRY_POINT_RENAME(ICUNotifier) +#define ICUNumberFormatFactory U_ICU_ENTRY_POINT_RENAME(ICUNumberFormatFactory) +#define ICUNumberFormatService U_ICU_ENTRY_POINT_RENAME(ICUNumberFormatService) +#define ICUResourceBundleFactory U_ICU_ENTRY_POINT_RENAME(ICUResourceBundleFactory) +#define ICUService U_ICU_ENTRY_POINT_RENAME(ICUService) +#define ICUServiceFactory U_ICU_ENTRY_POINT_RENAME(ICUServiceFactory) +#define ICUServiceKey U_ICU_ENTRY_POINT_RENAME(ICUServiceKey) +#define ICU_Utility U_ICU_ENTRY_POINT_RENAME(ICU_Utility) +#define IDNA U_ICU_ENTRY_POINT_RENAME(IDNA) +#define IndianCalendar U_ICU_ENTRY_POINT_RENAME(IndianCalendar) +#define IndicClassTable U_ICU_ENTRY_POINT_RENAME(IndicClassTable) +#define IndicOpenTypeLayoutEngine U_ICU_ENTRY_POINT_RENAME(IndicOpenTypeLayoutEngine) +#define IndicRearrangementProcessor U_ICU_ENTRY_POINT_RENAME(IndicRearrangementProcessor) +#define IndicReordering U_ICU_ENTRY_POINT_RENAME(IndicReordering) +#define InitialTimeZoneRule U_ICU_ENTRY_POINT_RENAME(InitialTimeZoneRule) +#define InputText U_ICU_ENTRY_POINT_RENAME(InputText) +#define IntegralPartSubstitution U_ICU_ENTRY_POINT_RENAME(IntegralPartSubstitution) +#define IslamicCalendar U_ICU_ENTRY_POINT_RENAME(IslamicCalendar) +#define IteratedChar U_ICU_ENTRY_POINT_RENAME(IteratedChar) +#define JapaneseCalendar U_ICU_ENTRY_POINT_RENAME(JapaneseCalendar) +#define KernTable U_ICU_ENTRY_POINT_RENAME(KernTable) +#define KeywordEnumeration U_ICU_ENTRY_POINT_RENAME(KeywordEnumeration) +#define KhmerClassTable U_ICU_ENTRY_POINT_RENAME(KhmerClassTable) +#define KhmerOpenTypeLayoutEngine U_ICU_ENTRY_POINT_RENAME(KhmerOpenTypeLayoutEngine) +#define KhmerReordering U_ICU_ENTRY_POINT_RENAME(KhmerReordering) +#define LECharMapper U_ICU_ENTRY_POINT_RENAME(LECharMapper) +#define LEFontInstance U_ICU_ENTRY_POINT_RENAME(LEFontInstance) +#define LEGlyphFilter U_ICU_ENTRY_POINT_RENAME(LEGlyphFilter) +#define LEGlyphStorage U_ICU_ENTRY_POINT_RENAME(LEGlyphStorage) +#define LEInsertionCallback U_ICU_ENTRY_POINT_RENAME(LEInsertionCallback) +#define LEInsertionList U_ICU_ENTRY_POINT_RENAME(LEInsertionList) +#define LXUtilities U_ICU_ENTRY_POINT_RENAME(LXUtilities) +#define LanguageBreakEngine U_ICU_ENTRY_POINT_RENAME(LanguageBreakEngine) +#define LanguageBreakFactory U_ICU_ENTRY_POINT_RENAME(LanguageBreakFactory) +#define LayoutEngine U_ICU_ENTRY_POINT_RENAME(LayoutEngine) +#define LigatureSubstitutionProcessor U_ICU_ENTRY_POINT_RENAME(LigatureSubstitutionProcessor) +#define LigatureSubstitutionSubtable U_ICU_ENTRY_POINT_RENAME(LigatureSubstitutionSubtable) +#define LocDataParser U_ICU_ENTRY_POINT_RENAME(LocDataParser) +#define Locale U_ICU_ENTRY_POINT_RENAME(Locale) +#define LocaleBased U_ICU_ENTRY_POINT_RENAME(LocaleBased) +#define LocaleDisplayNames U_ICU_ENTRY_POINT_RENAME(LocaleDisplayNames) +#define LocaleDisplayNamesImpl U_ICU_ENTRY_POINT_RENAME(LocaleDisplayNamesImpl) +#define LocaleKey U_ICU_ENTRY_POINT_RENAME(LocaleKey) +#define LocaleKeyFactory U_ICU_ENTRY_POINT_RENAME(LocaleKeyFactory) +#define LocaleRuns U_ICU_ENTRY_POINT_RENAME(LocaleRuns) +#define LocaleUtility U_ICU_ENTRY_POINT_RENAME(LocaleUtility) +#define LocalizationInfo U_ICU_ENTRY_POINT_RENAME(LocalizationInfo) +#define LookupListTable U_ICU_ENTRY_POINT_RENAME(LookupListTable) +#define LookupProcessor U_ICU_ENTRY_POINT_RENAME(LookupProcessor) +#define LookupSubtable U_ICU_ENTRY_POINT_RENAME(LookupSubtable) +#define LookupTable U_ICU_ENTRY_POINT_RENAME(LookupTable) +#define LowercaseTransliterator U_ICU_ENTRY_POINT_RENAME(LowercaseTransliterator) +#define MPreFixups U_ICU_ENTRY_POINT_RENAME(MPreFixups) +#define MarkArray U_ICU_ENTRY_POINT_RENAME(MarkArray) +#define MarkToBasePositioningSubtable U_ICU_ENTRY_POINT_RENAME(MarkToBasePositioningSubtable) +#define MarkToLigaturePositioningSubtable U_ICU_ENTRY_POINT_RENAME(MarkToLigaturePositioningSubtable) +#define MarkToMarkPositioningSubtable U_ICU_ENTRY_POINT_RENAME(MarkToMarkPositioningSubtable) +#define Measure U_ICU_ENTRY_POINT_RENAME(Measure) +#define MeasureFormat U_ICU_ENTRY_POINT_RENAME(MeasureFormat) +#define MeasureUnit U_ICU_ENTRY_POINT_RENAME(MeasureUnit) +#define MessageFormat U_ICU_ENTRY_POINT_RENAME(MessageFormat) +#define MessageFormatAdapter U_ICU_ENTRY_POINT_RENAME(MessageFormatAdapter) +#define ModulusSubstitution U_ICU_ENTRY_POINT_RENAME(ModulusSubstitution) +#define MoonRiseSetCoordFunc U_ICU_ENTRY_POINT_RENAME(MoonRiseSetCoordFunc) +#define MoonTimeAngleFunc U_ICU_ENTRY_POINT_RENAME(MoonTimeAngleFunc) +#define MorphSubtableHeader U_ICU_ENTRY_POINT_RENAME(MorphSubtableHeader) +#define MorphTableHeader U_ICU_ENTRY_POINT_RENAME(MorphTableHeader) +#define MultipleSubstitutionSubtable U_ICU_ENTRY_POINT_RENAME(MultipleSubstitutionSubtable) +#define MultiplierSubstitution U_ICU_ENTRY_POINT_RENAME(MultiplierSubstitution) +#define MutableTrieDictionary U_ICU_ENTRY_POINT_RENAME(MutableTrieDictionary) +#define MutableTrieEnumeration U_ICU_ENTRY_POINT_RENAME(MutableTrieEnumeration) +#define NFFactory U_ICU_ENTRY_POINT_RENAME(NFFactory) +#define NFKDBuffer U_ICU_ENTRY_POINT_RENAME(NFKDBuffer) +#define NFRule U_ICU_ENTRY_POINT_RENAME(NFRule) +#define NFRuleSet U_ICU_ENTRY_POINT_RENAME(NFRuleSet) +#define NFSubstitution U_ICU_ENTRY_POINT_RENAME(NFSubstitution) +#define NGramParser U_ICU_ENTRY_POINT_RENAME(NGramParser) +#define NameToEnum U_ICU_ENTRY_POINT_RENAME(NameToEnum) +#define NameUnicodeTransliterator U_ICU_ENTRY_POINT_RENAME(NameUnicodeTransliterator) +#define NonContextualGlyphSubstitutionProcessor U_ICU_ENTRY_POINT_RENAME(NonContextualGlyphSubstitutionProcessor) +#define NonContiguousEnumToOffset U_ICU_ENTRY_POINT_RENAME(NonContiguousEnumToOffset) +#define NoopNormalizer2 U_ICU_ENTRY_POINT_RENAME(NoopNormalizer2) +#define Norm2AllModes U_ICU_ENTRY_POINT_RENAME(Norm2AllModes) +#define NormalizationTransliterator U_ICU_ENTRY_POINT_RENAME(NormalizationTransliterator) +#define Normalizer U_ICU_ENTRY_POINT_RENAME(Normalizer) +#define Normalizer2 U_ICU_ENTRY_POINT_RENAME(Normalizer2) +#define Normalizer2Factory U_ICU_ENTRY_POINT_RENAME(Normalizer2Factory) +#define Normalizer2Impl U_ICU_ENTRY_POINT_RENAME(Normalizer2Impl) +#define Normalizer2WithImpl U_ICU_ENTRY_POINT_RENAME(Normalizer2WithImpl) +#define NullSubstitution U_ICU_ENTRY_POINT_RENAME(NullSubstitution) +#define NullTransliterator U_ICU_ENTRY_POINT_RENAME(NullTransliterator) +#define NumberFormat U_ICU_ENTRY_POINT_RENAME(NumberFormat) +#define NumberFormatFactory U_ICU_ENTRY_POINT_RENAME(NumberFormatFactory) +#define NumberingSystem U_ICU_ENTRY_POINT_RENAME(NumberingSystem) +#define NumeratorSubstitution U_ICU_ENTRY_POINT_RENAME(NumeratorSubstitution) +#define OlsonTimeZone U_ICU_ENTRY_POINT_RENAME(OlsonTimeZone) +#define OpenTypeLayoutEngine U_ICU_ENTRY_POINT_RENAME(OpenTypeLayoutEngine) +#define OpenTypeUtilities U_ICU_ENTRY_POINT_RENAME(OpenTypeUtilities) +#define OrConstraint U_ICU_ENTRY_POINT_RENAME(OrConstraint) +#define PCEBuffer U_ICU_ENTRY_POINT_RENAME(PCEBuffer) +#define PairPositioningFormat1Subtable U_ICU_ENTRY_POINT_RENAME(PairPositioningFormat1Subtable) +#define PairPositioningFormat2Subtable U_ICU_ENTRY_POINT_RENAME(PairPositioningFormat2Subtable) +#define PairPositioningSubtable U_ICU_ENTRY_POINT_RENAME(PairPositioningSubtable) +#define ParagraphLayout U_ICU_ENTRY_POINT_RENAME(ParagraphLayout) +#define ParseData U_ICU_ENTRY_POINT_RENAME(ParseData) +#define ParsePosition U_ICU_ENTRY_POINT_RENAME(ParsePosition) +#define PatternMap U_ICU_ENTRY_POINT_RENAME(PatternMap) +#define PatternMapIterator U_ICU_ENTRY_POINT_RENAME(PatternMapIterator) +#define PersianCalendar U_ICU_ENTRY_POINT_RENAME(PersianCalendar) +#define PluralFormat U_ICU_ENTRY_POINT_RENAME(PluralFormat) +#define PluralKeywordEnumeration U_ICU_ENTRY_POINT_RENAME(PluralKeywordEnumeration) +#define PluralRules U_ICU_ENTRY_POINT_RENAME(PluralRules) +#define PropertyAliases U_ICU_ENTRY_POINT_RENAME(PropertyAliases) +#define PtnElem U_ICU_ENTRY_POINT_RENAME(PtnElem) +#define PtnSkeleton U_ICU_ENTRY_POINT_RENAME(PtnSkeleton) +#define Quantifier U_ICU_ENTRY_POINT_RENAME(Quantifier) +#define RBBIDataWrapper U_ICU_ENTRY_POINT_RENAME(RBBIDataWrapper) +#define RBBINode U_ICU_ENTRY_POINT_RENAME(RBBINode) +#define RBBIRuleBuilder U_ICU_ENTRY_POINT_RENAME(RBBIRuleBuilder) +#define RBBIRuleScanner U_ICU_ENTRY_POINT_RENAME(RBBIRuleScanner) +#define RBBISetBuilder U_ICU_ENTRY_POINT_RENAME(RBBISetBuilder) +#define RBBIStateDescriptor U_ICU_ENTRY_POINT_RENAME(RBBIStateDescriptor) +#define RBBISymbolTable U_ICU_ENTRY_POINT_RENAME(RBBISymbolTable) +#define RBBISymbolTableEntry U_ICU_ENTRY_POINT_RENAME(RBBISymbolTableEntry) +#define RBBITableBuilder U_ICU_ENTRY_POINT_RENAME(RBBITableBuilder) +#define RCEBuffer U_ICU_ENTRY_POINT_RENAME(RCEBuffer) +#define RangeDescriptor U_ICU_ENTRY_POINT_RENAME(RangeDescriptor) +#define RegexCompile U_ICU_ENTRY_POINT_RENAME(RegexCompile) +#define RegexMatcher U_ICU_ENTRY_POINT_RENAME(RegexMatcher) +#define RegexPattern U_ICU_ENTRY_POINT_RENAME(RegexPattern) +#define RegexStaticSets U_ICU_ENTRY_POINT_RENAME(RegexStaticSets) +#define RegularExpression U_ICU_ENTRY_POINT_RENAME(RegularExpression) +#define RelativeDateFormat U_ICU_ENTRY_POINT_RENAME(RelativeDateFormat) +#define RemoveTransliterator U_ICU_ENTRY_POINT_RENAME(RemoveTransliterator) +#define ReorderingBuffer U_ICU_ENTRY_POINT_RENAME(ReorderingBuffer) +#define Replaceable U_ICU_ENTRY_POINT_RENAME(Replaceable) +#define ReplaceableGlue U_ICU_ENTRY_POINT_RENAME(ReplaceableGlue) +#define ResourceBundle U_ICU_ENTRY_POINT_RENAME(ResourceBundle) +#define RiseSetCoordFunc U_ICU_ENTRY_POINT_RENAME(RiseSetCoordFunc) +#define RuleBasedBreakIterator U_ICU_ENTRY_POINT_RENAME(RuleBasedBreakIterator) +#define RuleBasedCollator U_ICU_ENTRY_POINT_RENAME(RuleBasedCollator) +#define RuleBasedNumberFormat U_ICU_ENTRY_POINT_RENAME(RuleBasedNumberFormat) +#define RuleBasedTimeZone U_ICU_ENTRY_POINT_RENAME(RuleBasedTimeZone) +#define RuleBasedTransliterator U_ICU_ENTRY_POINT_RENAME(RuleBasedTransliterator) +#define RuleChain U_ICU_ENTRY_POINT_RENAME(RuleChain) +#define RuleCharacterIterator U_ICU_ENTRY_POINT_RENAME(RuleCharacterIterator) +#define RuleHalf U_ICU_ENTRY_POINT_RENAME(RuleHalf) +#define RuleParser U_ICU_ENTRY_POINT_RENAME(RuleParser) +#define RunArray U_ICU_ENTRY_POINT_RENAME(RunArray) +#define SPUString U_ICU_ENTRY_POINT_RENAME(SPUString) +#define SPUStringPool U_ICU_ENTRY_POINT_RENAME(SPUStringPool) +#define SafeZoneStringFormatPtr U_ICU_ENTRY_POINT_RENAME(SafeZoneStringFormatPtr) +#define SameValueSubstitution U_ICU_ENTRY_POINT_RENAME(SameValueSubstitution) +#define ScriptListTable U_ICU_ENTRY_POINT_RENAME(ScriptListTable) +#define ScriptRunIterator U_ICU_ENTRY_POINT_RENAME(ScriptRunIterator) +#define ScriptSet U_ICU_ENTRY_POINT_RENAME(ScriptSet) +#define ScriptTable U_ICU_ENTRY_POINT_RENAME(ScriptTable) +#define SearchIterator U_ICU_ENTRY_POINT_RENAME(SearchIterator) +#define SegmentArrayProcessor U_ICU_ENTRY_POINT_RENAME(SegmentArrayProcessor) +#define SegmentSingleProcessor U_ICU_ENTRY_POINT_RENAME(SegmentSingleProcessor) +#define SelectFormat U_ICU_ENTRY_POINT_RENAME(SelectFormat) +#define ServiceEnumeration U_ICU_ENTRY_POINT_RENAME(ServiceEnumeration) +#define ServiceListener U_ICU_ENTRY_POINT_RENAME(ServiceListener) +#define SimpleArrayProcessor U_ICU_ENTRY_POINT_RENAME(SimpleArrayProcessor) +#define SimpleDateFormat U_ICU_ENTRY_POINT_RENAME(SimpleDateFormat) +#define SimpleFactory U_ICU_ENTRY_POINT_RENAME(SimpleFactory) +#define SimpleLocaleKeyFactory U_ICU_ENTRY_POINT_RENAME(SimpleLocaleKeyFactory) +#define SimpleNumberFormatFactory U_ICU_ENTRY_POINT_RENAME(SimpleNumberFormatFactory) +#define SimpleSingleton U_ICU_ENTRY_POINT_RENAME(SimpleSingleton) +#define SimpleTimeZone U_ICU_ENTRY_POINT_RENAME(SimpleTimeZone) +#define SinglePositioningFormat1Subtable U_ICU_ENTRY_POINT_RENAME(SinglePositioningFormat1Subtable) +#define SinglePositioningFormat2Subtable U_ICU_ENTRY_POINT_RENAME(SinglePositioningFormat2Subtable) +#define SinglePositioningSubtable U_ICU_ENTRY_POINT_RENAME(SinglePositioningSubtable) +#define SingleSubstitutionFormat1Subtable U_ICU_ENTRY_POINT_RENAME(SingleSubstitutionFormat1Subtable) +#define SingleSubstitutionFormat2Subtable U_ICU_ENTRY_POINT_RENAME(SingleSubstitutionFormat2Subtable) +#define SingleSubstitutionSubtable U_ICU_ENTRY_POINT_RENAME(SingleSubstitutionSubtable) +#define SingleTableProcessor U_ICU_ENTRY_POINT_RENAME(SingleTableProcessor) +#define SpoofData U_ICU_ENTRY_POINT_RENAME(SpoofData) +#define SpoofImpl U_ICU_ENTRY_POINT_RENAME(SpoofImpl) +#define StateTableProcessor U_ICU_ENTRY_POINT_RENAME(StateTableProcessor) +#define StringCharacterIterator U_ICU_ENTRY_POINT_RENAME(StringCharacterIterator) +#define StringEnumeration U_ICU_ENTRY_POINT_RENAME(StringEnumeration) +#define StringList U_ICU_ENTRY_POINT_RENAME(StringList) +#define StringLocalizationInfo U_ICU_ENTRY_POINT_RENAME(StringLocalizationInfo) +#define StringMatcher U_ICU_ENTRY_POINT_RENAME(StringMatcher) +#define StringPair U_ICU_ENTRY_POINT_RENAME(StringPair) +#define StringPiece U_ICU_ENTRY_POINT_RENAME(StringPiece) +#define StringReplacer U_ICU_ENTRY_POINT_RENAME(StringReplacer) +#define StringSearch U_ICU_ENTRY_POINT_RENAME(StringSearch) +#define StringToCEsMap U_ICU_ENTRY_POINT_RENAME(StringToCEsMap) +#define StyleRuns U_ICU_ENTRY_POINT_RENAME(StyleRuns) +#define SubstitutionLookup U_ICU_ENTRY_POINT_RENAME(SubstitutionLookup) +#define SubtableProcessor U_ICU_ENTRY_POINT_RENAME(SubtableProcessor) +#define SunTimeAngleFunc U_ICU_ENTRY_POINT_RENAME(SunTimeAngleFunc) +#define SymbolTable U_ICU_ENTRY_POINT_RENAME(SymbolTable) +#define TZEnumeration U_ICU_ENTRY_POINT_RENAME(TZEnumeration) +#define TaiwanCalendar U_ICU_ENTRY_POINT_RENAME(TaiwanCalendar) +#define Target U_ICU_ENTRY_POINT_RENAME(Target) +#define TernaryNode U_ICU_ENTRY_POINT_RENAME(TernaryNode) +#define TextTrieMap U_ICU_ENTRY_POINT_RENAME(TextTrieMap) +#define TextTrieMapSearchResultHandler U_ICU_ENTRY_POINT_RENAME(TextTrieMapSearchResultHandler) +#define ThaiBreakEngine U_ICU_ENTRY_POINT_RENAME(ThaiBreakEngine) +#define ThaiLayoutEngine U_ICU_ENTRY_POINT_RENAME(ThaiLayoutEngine) +#define ThaiShaping U_ICU_ENTRY_POINT_RENAME(ThaiShaping) +#define TibetanClassTable U_ICU_ENTRY_POINT_RENAME(TibetanClassTable) +#define TibetanOpenTypeLayoutEngine U_ICU_ENTRY_POINT_RENAME(TibetanOpenTypeLayoutEngine) +#define TibetanReordering U_ICU_ENTRY_POINT_RENAME(TibetanReordering) +#define TimeArrayTimeZoneRule U_ICU_ENTRY_POINT_RENAME(TimeArrayTimeZoneRule) +#define TimeUnit U_ICU_ENTRY_POINT_RENAME(TimeUnit) +#define TimeUnitAmount U_ICU_ENTRY_POINT_RENAME(TimeUnitAmount) +#define TimeUnitFormat U_ICU_ENTRY_POINT_RENAME(TimeUnitFormat) +#define TimeZone U_ICU_ENTRY_POINT_RENAME(TimeZone) +#define TimeZoneRule U_ICU_ENTRY_POINT_RENAME(TimeZoneRule) +#define TimeZoneTransition U_ICU_ENTRY_POINT_RENAME(TimeZoneTransition) +#define TitlecaseTransliterator U_ICU_ENTRY_POINT_RENAME(TitlecaseTransliterator) +#define TransliterationRule U_ICU_ENTRY_POINT_RENAME(TransliterationRule) +#define TransliterationRuleData U_ICU_ENTRY_POINT_RENAME(TransliterationRuleData) +#define TransliterationRuleSet U_ICU_ENTRY_POINT_RENAME(TransliterationRuleSet) +#define Transliterator U_ICU_ENTRY_POINT_RENAME(Transliterator) +#define TransliteratorAlias U_ICU_ENTRY_POINT_RENAME(TransliteratorAlias) +#define TransliteratorEntry U_ICU_ENTRY_POINT_RENAME(TransliteratorEntry) +#define TransliteratorIDParser U_ICU_ENTRY_POINT_RENAME(TransliteratorIDParser) +#define TransliteratorParser U_ICU_ENTRY_POINT_RENAME(TransliteratorParser) +#define TransliteratorRegistry U_ICU_ENTRY_POINT_RENAME(TransliteratorRegistry) +#define TransliteratorSpec U_ICU_ENTRY_POINT_RENAME(TransliteratorSpec) +#define TriStateSingleton U_ICU_ENTRY_POINT_RENAME(TriStateSingleton) +#define TrieWordDictionary U_ICU_ENTRY_POINT_RENAME(TrieWordDictionary) +#define TrimmedArrayProcessor U_ICU_ENTRY_POINT_RENAME(TrimmedArrayProcessor) +#define UCharCharacterIterator U_ICU_ENTRY_POINT_RENAME(UCharCharacterIterator) +#define UCollationPCE U_ICU_ENTRY_POINT_RENAME(UCollationPCE) +#define UDataPathIterator U_ICU_ENTRY_POINT_RENAME(UDataPathIterator) +#define ULocRuns U_ICU_ENTRY_POINT_RENAME(ULocRuns) +#define UMemory U_ICU_ENTRY_POINT_RENAME(UMemory) +#define UObject U_ICU_ENTRY_POINT_RENAME(UObject) +#define UStack U_ICU_ENTRY_POINT_RENAME(UStack) +#define UStringEnumeration U_ICU_ENTRY_POINT_RENAME(UStringEnumeration) +#define UTS46 U_ICU_ENTRY_POINT_RENAME(UTS46) +#define UTrie2Singleton U_ICU_ENTRY_POINT_RENAME(UTrie2Singleton) +#define UVector U_ICU_ENTRY_POINT_RENAME(UVector) +#define UVector32 U_ICU_ENTRY_POINT_RENAME(UVector32) +#define UVector64 U_ICU_ENTRY_POINT_RENAME(UVector64) +#define UnescapeTransliterator U_ICU_ENTRY_POINT_RENAME(UnescapeTransliterator) +#define UnhandledEngine U_ICU_ENTRY_POINT_RENAME(UnhandledEngine) +#define UnicodeArabicOpenTypeLayoutEngine U_ICU_ENTRY_POINT_RENAME(UnicodeArabicOpenTypeLayoutEngine) +#define UnicodeFilter U_ICU_ENTRY_POINT_RENAME(UnicodeFilter) +#define UnicodeFunctor U_ICU_ENTRY_POINT_RENAME(UnicodeFunctor) +#define UnicodeMatcher U_ICU_ENTRY_POINT_RENAME(UnicodeMatcher) +#define UnicodeNameTransliterator U_ICU_ENTRY_POINT_RENAME(UnicodeNameTransliterator) +#define UnicodeReplacer U_ICU_ENTRY_POINT_RENAME(UnicodeReplacer) +#define UnicodeSet U_ICU_ENTRY_POINT_RENAME(UnicodeSet) +#define UnicodeSetIterator U_ICU_ENTRY_POINT_RENAME(UnicodeSetIterator) +#define UnicodeSetStringSpan U_ICU_ENTRY_POINT_RENAME(UnicodeSetStringSpan) +#define UnicodeString U_ICU_ENTRY_POINT_RENAME(UnicodeString) +#define UppercaseTransliterator U_ICU_ENTRY_POINT_RENAME(UppercaseTransliterator) +#define VTZReader U_ICU_ENTRY_POINT_RENAME(VTZReader) +#define VTZWriter U_ICU_ENTRY_POINT_RENAME(VTZWriter) +#define VTimeZone U_ICU_ENTRY_POINT_RENAME(VTimeZone) +#define ValueRecord U_ICU_ENTRY_POINT_RENAME(ValueRecord) +#define ValueRuns U_ICU_ENTRY_POINT_RENAME(ValueRuns) +#define ZSFCache U_ICU_ENTRY_POINT_RENAME(ZSFCache) +#define ZSFCacheEntry U_ICU_ENTRY_POINT_RENAME(ZSFCacheEntry) +#define ZSFStringPool U_ICU_ENTRY_POINT_RENAME(ZSFStringPool) +#define ZSFStringPoolChunk U_ICU_ENTRY_POINT_RENAME(ZSFStringPoolChunk) +#define ZoneMeta U_ICU_ENTRY_POINT_RENAME(ZoneMeta) +#define ZoneStringFormat U_ICU_ENTRY_POINT_RENAME(ZoneStringFormat) +#define ZoneStringInfo U_ICU_ENTRY_POINT_RENAME(ZoneStringInfo) +#define ZoneStringSearchResultHandler U_ICU_ENTRY_POINT_RENAME(ZoneStringSearchResultHandler) +#define ZoneStrings U_ICU_ENTRY_POINT_RENAME(ZoneStrings) +#define collIterate U_ICU_ENTRY_POINT_RENAME(collIterate) +#define locale_set_default_internal U_ICU_ENTRY_POINT_RENAME(locale_set_default_internal) +#define util64_fromDouble U_ICU_ENTRY_POINT_RENAME(util64_fromDouble) +#define util64_pow U_ICU_ENTRY_POINT_RENAME(util64_pow) +#define util64_tou U_ICU_ENTRY_POINT_RENAME(util64_tou) #endif #endif diff --git a/Source/WTF/icu/unicode/uscript.h b/Source/WTF/icu/unicode/uscript.h index 16375447d..ee21c740d 100644 --- a/Source/WTF/icu/unicode/uscript.h +++ b/Source/WTF/icu/unicode/uscript.h @@ -1,17 +1,18 @@ /* -********************************************************************** -* Copyright (C) 1997-2006, International Business Machines -* Corporation and others. All Rights Reserved. -********************************************************************** -* -* File USCRIPT.H -* -* Modification History: -* -* Date Name Description -* 07/06/2001 Ram Creation. -****************************************************************************** -*/ + ********************************************************************** + * Copyright (C) 1997-2010, International Business Machines + * Corporation and others. All Rights Reserved. + ********************************************************************** + * + * File USCRIPT.H + * + * Modification History: + * + * Date Name Description + * 07/06/2001 Ram Creation. + ****************************************************************************** + */ + #ifndef USCRIPT_H #define USCRIPT_H #include "unicode/utypes.h" @@ -44,8 +45,8 @@ */ typedef enum UScriptCode { USCRIPT_INVALID_CODE = -1, - USCRIPT_COMMON = 0 , /* Zyyy */ - USCRIPT_INHERITED = 1, /* Qaai */ + USCRIPT_COMMON = 0, /* Zyyy */ + USCRIPT_INHERITED = 1, /* Zinh */ /* "Code for inherited script", for non-spacing combining marks; also Qaai */ USCRIPT_ARABIC = 2, /* Arab */ USCRIPT_ARMENIAN = 3, /* Armn */ USCRIPT_BENGALI = 4, /* Beng */ @@ -106,9 +107,8 @@ typedef enum UScriptCode { /** New script code in Unicode 4.0.1 @stable ICU 3.0 */ USCRIPT_KATAKANA_OR_HIRAGANA = 54,/*Hrkt */ - -#ifndef U_HIDE_DRAFT_API - /* New scripts in Unicode 4.1 @draft ICU 3.4 */ + + /* New scripts in Unicode 4.1 @stable ICU 3.4 */ USCRIPT_BUGINESE = 55, /* Bugi */ USCRIPT_GLAGOLITIC = 56, /* Glag */ USCRIPT_KHAROSHTHI = 57, /* Khar */ @@ -117,7 +117,7 @@ typedef enum UScriptCode { USCRIPT_TIFINAGH = 60, /* Tfng */ USCRIPT_OLD_PERSIAN = 61, /* Xpeo */ - /* New script codes from ISO 15924 @draft ICU 3.6 */ + /* New script codes from ISO 15924 @stable ICU 3.6 */ USCRIPT_BALINESE = 62, /* Bali */ USCRIPT_BATAK = 63, /* Batk */ USCRIPT_BLISSYMBOLS = 64, /* Blis */ @@ -140,9 +140,15 @@ typedef enum UScriptCode { USCRIPT_LATIN_GAELIC = 81, /* Latg */ USCRIPT_LEPCHA = 82, /* Lepc */ USCRIPT_LINEAR_A = 83, /* Lina */ - USCRIPT_MANDAEAN = 84, /* Mand */ + /** @stable ICU 4.6 */ + USCRIPT_MANDAIC = 84, /* Mand */ + /** @stable ICU 3.6 */ + USCRIPT_MANDAEAN = USCRIPT_MANDAIC, USCRIPT_MAYAN_HIEROGLYPHS = 85, /* Maya */ - USCRIPT_MEROITIC = 86, /* Mero */ + /** @stable ICU 4.6 */ + USCRIPT_MEROITIC_HIEROGLYPHS = 86, /* Mero */ + /** @stable ICU 3.6 */ + USCRIPT_MEROITIC = USCRIPT_MEROITIC_HIEROGLYPHS, USCRIPT_NKO = 87, /* Nkoo */ USCRIPT_ORKHON = 88, /* Orkh */ USCRIPT_OLD_PERMIC = 89, /* Perm */ @@ -156,13 +162,64 @@ typedef enum UScriptCode { USCRIPT_EASTERN_SYRIAC = 97, /* Syrn */ USCRIPT_TENGWAR = 98, /* Teng */ USCRIPT_VAI = 99, /* Vaii */ - USCRIPT_VISIBLE_SPEECH = 100, /* Visp */ + USCRIPT_VISIBLE_SPEECH = 100,/* Visp */ USCRIPT_CUNEIFORM = 101,/* Xsux */ USCRIPT_UNWRITTEN_LANGUAGES = 102,/* Zxxx */ USCRIPT_UNKNOWN = 103,/* Zzzz */ /* Unknown="Code for uncoded script", for unassigned code points */ - /* Private use codes from Qaaa - Qabx are not supported*/ -#endif /* U_HIDE_DRAFT_API */ - USCRIPT_CODE_LIMIT = 104 + + /* New script codes from ISO 15924 @stable ICU 3.8 */ + USCRIPT_CARIAN = 104,/* Cari */ + USCRIPT_JAPANESE = 105,/* Jpan */ + USCRIPT_LANNA = 106,/* Lana */ + USCRIPT_LYCIAN = 107,/* Lyci */ + USCRIPT_LYDIAN = 108,/* Lydi */ + USCRIPT_OL_CHIKI = 109,/* Olck */ + USCRIPT_REJANG = 110,/* Rjng */ + USCRIPT_SAURASHTRA = 111,/* Saur */ + USCRIPT_SIGN_WRITING = 112,/* Sgnw */ + USCRIPT_SUNDANESE = 113,/* Sund */ + USCRIPT_MOON = 114,/* Moon */ + USCRIPT_MEITEI_MAYEK = 115,/* Mtei */ + + /* New script codes from ISO 15924 @stable ICU 4.0 */ + USCRIPT_IMPERIAL_ARAMAIC = 116,/* Armi */ + USCRIPT_AVESTAN = 117,/* Avst */ + USCRIPT_CHAKMA = 118,/* Cakm */ + USCRIPT_KOREAN = 119,/* Kore */ + USCRIPT_KAITHI = 120,/* Kthi */ + USCRIPT_MANICHAEAN = 121,/* Mani */ + USCRIPT_INSCRIPTIONAL_PAHLAVI = 122,/* Phli */ + USCRIPT_PSALTER_PAHLAVI = 123,/* Phlp */ + USCRIPT_BOOK_PAHLAVI = 124,/* Phlv */ + USCRIPT_INSCRIPTIONAL_PARTHIAN = 125,/* Prti */ + USCRIPT_SAMARITAN = 126,/* Samr */ + USCRIPT_TAI_VIET = 127,/* Tavt */ + USCRIPT_MATHEMATICAL_NOTATION = 128,/* Zmth */ + USCRIPT_SYMBOLS = 129,/* Zsym */ + + /* New script codes from ISO 15924 @stable ICU 4.4 */ + USCRIPT_BAMUM = 130,/* Bamu */ + USCRIPT_LISU = 131,/* Lisu */ + USCRIPT_NAKHI_GEBA = 132,/* Nkgb */ + USCRIPT_OLD_SOUTH_ARABIAN = 133,/* Sarb */ + + /* New script codes from ISO 15924 @stable ICU 4.6 */ + USCRIPT_BASSA_VAH = 134,/* Bass */ + USCRIPT_DUPLOYAN_SHORTAND = 135,/* Dupl */ + USCRIPT_ELBASAN = 136,/* Elba */ + USCRIPT_GRANTHA = 137,/* Gran */ + USCRIPT_KPELLE = 138,/* Kpel */ + USCRIPT_LOMA = 139,/* Loma */ + USCRIPT_MENDE = 140,/* Mend */ + USCRIPT_MEROITIC_CURSIVE = 141,/* Merc */ + USCRIPT_OLD_NORTH_ARABIAN = 142,/* Narb */ + USCRIPT_NABATAEAN = 143,/* Nbat */ + USCRIPT_PALMYRENE = 144,/* Palm */ + USCRIPT_SINDHI = 145,/* Sind */ + USCRIPT_WARANG_CITI = 146,/* Wara */ + + /* Private use codes from Qaaa - Qabx are not supported */ + USCRIPT_CODE_LIMIT = 147 } UScriptCode; /** @@ -208,7 +265,7 @@ uscript_getName(UScriptCode scriptCode); U_STABLE const char* U_EXPORT2 uscript_getShortName(UScriptCode scriptCode); -/** +/** * Gets the script code associated with the given codepoint. * Returns USCRIPT_MALAYALAM given 0x0D02 * @param codepoint UChar32 codepoint @@ -219,4 +276,51 @@ uscript_getShortName(UScriptCode scriptCode); U_STABLE UScriptCode U_EXPORT2 uscript_getScript(UChar32 codepoint, UErrorCode *err); +/** + * Is code point c used in script sc? + * That is, does code point c have the Script property value sc, + * or do code point c's Script_Extensions include script code sc? + * + * Some characters are commonly used in multiple scripts. + * For more information, see UAX #24: http://www.unicode.org/reports/tr24/. + * + * The Script_Extensions property is provisional. It may be modified or removed + * in future versions of the Unicode Standard, and thus in ICU. + * @param c code point + * @param sc script code + * @return TRUE if Script(c)==sc or sc is in Script_Extensions(c) + * @draft ICU 4.6 + */ +U_DRAFT UBool U_EXPORT2 +uscript_hasScript(UChar32 c, UScriptCode sc); + +/** + * Writes code point c's Script_Extensions as a list of UScriptCode values + * to the output scripts array. + * + * Some characters are commonly used in multiple scripts. + * For more information, see UAX #24: http://www.unicode.org/reports/tr24/. + * + * If there are more than capacity script codes to be written, then + * U_BUFFER_OVERFLOW_ERROR is set and the number of Script_Extensions is returned. + * (Usual ICU buffer handling behavior.) + * + * The Script_Extensions property is provisional. It may be modified or removed + * in future versions of the Unicode Standard, and thus in ICU. + * @param c code point + * @param scripts output script code array + * @param capacity capacity of the scripts array + * @param errorCode Standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return number of script codes in c's Script_Extensions, + * written to scripts unless U_BUFFER_OVERFLOW_ERROR indicates insufficient capacity + * @draft ICU 4.6 + */ +U_DRAFT int32_t U_EXPORT2 +uscript_getScriptExtensions(UChar32 c, + UScriptCode *scripts, int32_t capacity, + UErrorCode *pErrorCode); + #endif diff --git a/Source/WTF/icu/unicode/uset.h b/Source/WTF/icu/unicode/uset.h index b82ceb8ff..77ab06342 100644 --- a/Source/WTF/icu/unicode/uset.h +++ b/Source/WTF/icu/unicode/uset.h @@ -1,7 +1,7 @@ /* ******************************************************************************* * -* Copyright (C) 2002-2004, International Business Machines +* Copyright (C) 2002-2010, International Business Machines * Corporation and others. All Rights Reserved. * ******************************************************************************* @@ -29,6 +29,7 @@ #include "unicode/utypes.h" #include "unicode/uchar.h" +#include "unicode/localpointer.h" #ifndef UCNV_H struct USet; @@ -57,27 +58,39 @@ enum { * will match 'a', 'A', 'b', and 'B'. "[^ab]" with this flag will * match all except 'a', 'A', 'b', and 'B'. This performs a full * closure over case mappings, e.g. U+017F for s. + * + * The resulting set is a superset of the input for the code points but + * not for the strings. + * It performs a case mapping closure of the code points and adds + * full case folding strings for the code points, and reduces strings of + * the original set to their full case folding equivalents. + * + * This is designed for case-insensitive matches, for example + * in regular expressions. The full code point case closure allows checking of + * an input character directly against the closure set. + * Strings are matched by comparing the case-folded form from the closure + * set with an incremental case folding of the string in question. + * + * The closure set will also contain single code points if the original + * set contained case-equivalent strings (like U+00DF for "ss" or "Ss" etc.). + * This is not necessary (that is, redundant) for the above matching method + * but results in the same closure sets regardless of whether the original + * set contained the code point or a string. + * * @stable ICU 2.4 */ USET_CASE_INSENSITIVE = 2, /** - * Bitmask for UnicodeSet::closeOver() indicating letter case. - * This may be ORed together with other selectors. - * @internal - */ - USET_CASE = 2, - - /** * Enable case insensitive matching. E.g., "[ab]" with this flag * will match 'a', 'A', 'b', and 'B'. "[^ab]" with this flag will * match all except 'a', 'A', 'b', and 'B'. This adds the lower-, * title-, and uppercase mappings as well as the case folding * of each existing element in the set. - * @draft ICU 3.2 + * @stable ICU 3.2 */ USET_ADD_CASE_MAPPINGS = 4, - + /** * Enough for any single-code point set * @internal @@ -86,6 +99,115 @@ enum { }; /** + * Argument values for whether span() and similar functions continue while + * the current character is contained vs. not contained in the set. + * + * The functionality is straightforward for sets with only single code points, + * without strings (which is the common case): + * - USET_SPAN_CONTAINED and USET_SPAN_SIMPLE + * work the same. + * - span() and spanBack() partition any string the same way when + * alternating between span(USET_SPAN_NOT_CONTAINED) and + * span(either "contained" condition). + * - Using a complemented (inverted) set and the opposite span conditions + * yields the same results. + * + * When a set contains multi-code point strings, then these statements may not + * be true, depending on the strings in the set (for example, whether they + * overlap with each other) and the string that is processed. + * For a set with strings: + * - The complement of the set contains the opposite set of code points, + * but the same set of strings. + * Therefore, complementing both the set and the span conditions + * may yield different results. + * - When starting spans at different positions in a string + * (span(s, ...) vs. span(s+1, ...)) the ends of the spans may be different + * because a set string may start before the later position. + * - span(USET_SPAN_SIMPLE) may be shorter than + * span(USET_SPAN_CONTAINED) because it will not recursively try + * all possible paths. + * For example, with a set which contains the three strings "xy", "xya" and "ax", + * span("xyax", USET_SPAN_CONTAINED) will return 4 but + * span("xyax", USET_SPAN_SIMPLE) will return 3. + * span(USET_SPAN_SIMPLE) will never be longer than + * span(USET_SPAN_CONTAINED). + * - With either "contained" condition, span() and spanBack() may partition + * a string in different ways. + * For example, with a set which contains the two strings "ab" and "ba", + * and when processing the string "aba", + * span() will yield contained/not-contained boundaries of { 0, 2, 3 } + * while spanBack() will yield boundaries of { 0, 1, 3 }. + * + * Note: If it is important to get the same boundaries whether iterating forward + * or backward through a string, then either only span() should be used and + * the boundaries cached for backward operation, or an ICU BreakIterator + * could be used. + * + * Note: Unpaired surrogates are treated like surrogate code points. + * Similarly, set strings match only on code point boundaries, + * never in the middle of a surrogate pair. + * Illegal UTF-8 sequences are treated like U+FFFD. + * When processing UTF-8 strings, malformed set strings + * (strings with unpaired surrogates which cannot be converted to UTF-8) + * are ignored. + * + * @stable ICU 3.8 + */ +typedef enum USetSpanCondition { + /** + * Continue a span() while there is no set element at the current position. + * Stops before the first set element (character or string). + * (For code points only, this is like while contains(current)==FALSE). + * + * When span() returns, the substring between where it started and the position + * it returned consists only of characters that are not in the set, + * and none of its strings overlap with the span. + * + * @stable ICU 3.8 + */ + USET_SPAN_NOT_CONTAINED = 0, + /** + * Continue a span() while there is a set element at the current position. + * (For characters only, this is like while contains(current)==TRUE). + * + * When span() returns, the substring between where it started and the position + * it returned consists only of set elements (characters or strings) that are in the set. + * + * If a set contains strings, then the span will be the longest substring + * matching any of the possible concatenations of set elements (characters or strings). + * (There must be a single, non-overlapping concatenation of characters or strings.) + * This is equivalent to a POSIX regular expression for (OR of each set element)*. + * + * @stable ICU 3.8 + */ + USET_SPAN_CONTAINED = 1, + /** + * Continue a span() while there is a set element at the current position. + * (For characters only, this is like while contains(current)==TRUE). + * + * When span() returns, the substring between where it started and the position + * it returned consists only of set elements (characters or strings) that are in the set. + * + * If a set only contains single characters, then this is the same + * as USET_SPAN_CONTAINED. + * + * If a set contains strings, then the span will be the longest substring + * with a match at each position with the longest single set element (character or string). + * + * Use this span condition together with other longest-match algorithms, + * such as ICU converters (ucnv_getUnicodeSet()). + * + * @stable ICU 3.8 + */ + USET_SPAN_SIMPLE = 2, + /** + * One more than the last span condition. + * @stable ICU 3.8 + */ + USET_SPAN_CONDITION_COUNT +} USetSpanCondition; + +/** * A serialized form of a Unicode set. Limited manipulations are * possible directly on a serialized set. See below. * @stable ICU 2.4 @@ -118,8 +240,19 @@ typedef struct USerializedSet { *********************************************************************/ /** + * Create an empty USet object. + * Equivalent to uset_open(1, 0). + * @return a newly created USet. The caller must call uset_close() on + * it when done. + * @stable ICU 4.2 + */ +U_STABLE USet* U_EXPORT2 +uset_openEmpty(); + +/** * Creates a USet object that contains the range of characters - * start..end, inclusive. + * start..end, inclusive. If <code>start > end</code> + * then an empty set is created (same as using uset_openEmpty()). * @param start first character of the range, inclusive * @param end last character of the range, inclusive * @return a newly created USet. The caller must call uset_close() on @@ -167,15 +300,89 @@ uset_openPatternOptions(const UChar* pattern, int32_t patternLength, U_STABLE void U_EXPORT2 uset_close(USet* set); +#if U_SHOW_CPLUSPLUS_API + +U_NAMESPACE_BEGIN + +/** + * \class LocalUSetPointer + * "Smart pointer" class, closes a USet via uset_close(). + * For most methods see the LocalPointerBase base class. + * + * @see LocalPointerBase + * @see LocalPointer + * @stable ICU 4.4 + */ +U_DEFINE_LOCAL_OPEN_POINTER(LocalUSetPointer, USet, uset_close); + +U_NAMESPACE_END + +#endif + +/** + * Returns a copy of this object. + * If this set is frozen, then the clone will be frozen as well. + * Use uset_cloneAsThawed() for a mutable clone of a frozen set. + * @param set the original set + * @return the newly allocated copy of the set + * @see uset_cloneAsThawed + * @stable ICU 3.8 + */ +U_STABLE USet * U_EXPORT2 +uset_clone(const USet *set); + +/** + * Determines whether the set has been frozen (made immutable) or not. + * See the ICU4J Freezable interface for details. + * @param set the set + * @return TRUE/FALSE for whether the set has been frozen + * @see uset_freeze + * @see uset_cloneAsThawed + * @stable ICU 3.8 + */ +U_STABLE UBool U_EXPORT2 +uset_isFrozen(const USet *set); + +/** + * Freeze the set (make it immutable). + * Once frozen, it cannot be unfrozen and is therefore thread-safe + * until it is deleted. + * See the ICU4J Freezable interface for details. + * Freezing the set may also make some operations faster, for example + * uset_contains() and uset_span(). + * A frozen set will not be modified. (It remains frozen.) + * @param set the set + * @return the same set, now frozen + * @see uset_isFrozen + * @see uset_cloneAsThawed + * @stable ICU 3.8 + */ +U_STABLE void U_EXPORT2 +uset_freeze(USet *set); + +/** + * Clone the set and make the clone mutable. + * See the ICU4J Freezable interface for details. + * @param set the set + * @return the mutable clone + * @see uset_freeze + * @see uset_isFrozen + * @see uset_clone + * @stable ICU 3.8 + */ +U_STABLE USet * U_EXPORT2 +uset_cloneAsThawed(const USet *set); + /** * Causes the USet object to represent the range <code>start - end</code>. * If <code>start > end</code> then this USet is set to an empty range. + * A frozen set will not be modified. * @param set the object to set to the given range * @param start first character in the set, inclusive * @param end last character in the set, inclusive - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT void U_EXPORT2 +U_STABLE void U_EXPORT2 uset_set(USet* set, UChar32 start, UChar32 end); @@ -184,6 +391,7 @@ uset_set(USet* set, * pattern. See the UnicodeSet class description for the syntax of * the pattern language. See also the User Guide chapter about UnicodeSet. * <em>Empties the set passed before applying the pattern.</em> + * A frozen set will not be modified. * @param set The set to which the pattern is to be applied. * @param pattern A pointer to UChar string specifying what characters are in the set. * The character at pattern[0] must be a '['. @@ -196,10 +404,10 @@ uset_set(USet* set, * of the parsed pattern. * If the status code indicates failure, then the return value * is the index of the error in the source. - * - * @draft ICU 2.8 + * + * @stable ICU 2.8 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uset_applyPattern(USet *set, const UChar *pattern, int32_t patternLength, uint32_t options, @@ -209,6 +417,7 @@ uset_applyPattern(USet *set, * Modifies the set to contain those code points which have the given value * for the given binary or enumerated property, as returned by * u_getIntPropertyValue. Prior contents of this set are lost. + * A frozen set will not be modified. * * @param set the object to contain the code points defined by the property * @@ -224,9 +433,9 @@ uset_applyPattern(USet *set, * * @param ec error code input/output parameter * - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT void U_EXPORT2 +U_STABLE void U_EXPORT2 uset_applyIntPropertyValue(USet* set, UProperty prop, int32_t value, UErrorCode* ec); @@ -234,6 +443,7 @@ uset_applyIntPropertyValue(USet* set, * Modifies the set to contain those code points which have the * given value for the given property. Prior contents of this * set are lost. + * A frozen set will not be modified. * * @param set the object to contain the code points defined by the given * property and value alias @@ -246,7 +456,8 @@ uset_applyIntPropertyValue(USet* set, * matched loosely and correspond to the following sets: * * "ANY" = [\\u0000-\\U0010FFFF], - * "ASCII" = [\\u0000-\\u007F]. + * "ASCII" = [\\u0000-\\u007F], + * "Assigned" = [:^Cn:]. * * @param propLength the length of the prop, or -1 if NULL * @@ -261,9 +472,9 @@ uset_applyIntPropertyValue(USet* set, * * @param ec error code input/output parameter * - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT void U_EXPORT2 +U_STABLE void U_EXPORT2 uset_applyPropertyAlias(USet* set, const UChar *prop, int32_t propLength, const UChar *value, int32_t valueLength, @@ -276,9 +487,9 @@ uset_applyPropertyAlias(USet* set, * @param pattern a string specifying the pattern * @param patternLength the length of the pattern, or -1 if NULL * @param pos the given position - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT UBool U_EXPORT2 +U_STABLE UBool U_EXPORT2 uset_resemblesPattern(const UChar *pattern, int32_t patternLength, int32_t pos); @@ -306,6 +517,7 @@ uset_toPattern(const USet* set, /** * Adds the given character to the given USet. After this call, * uset_contains(set, c) will return TRUE. + * A frozen set will not be modified. * @param set the object to which to add the character * @param c the character to add * @stable ICU 2.4 @@ -319,6 +531,7 @@ uset_add(USet* set, UChar32 c); * modifies this set so that its value is the <i>union</i> of the two * sets. The behavior of this operation is unspecified if the specified * collection is modified while the operation is in progress. + * A frozen set will not be modified. * * @param set the object to which to add the set * @param additionalSet the source set whose elements are to be added to this set. @@ -330,6 +543,7 @@ uset_addAll(USet* set, const USet *additionalSet); /** * Adds the given range of characters to the given USet. After this call, * uset_contains(set, start, end) will return TRUE. + * A frozen set will not be modified. * @param set the object to which to add the character * @param start the first character of the range to add, inclusive * @param end the last character of the range to add, inclusive @@ -341,6 +555,7 @@ uset_addRange(USet* set, UChar32 start, UChar32 end); /** * Adds the given string to the given USet. After this call, * uset_containsString(set, str, strLen) will return TRUE. + * A frozen set will not be modified. * @param set the object to which to add the character * @param str the string to add * @param strLen the length of the string or -1 if null terminated. @@ -350,8 +565,21 @@ U_STABLE void U_EXPORT2 uset_addString(USet* set, const UChar* str, int32_t strLen); /** + * Adds each of the characters in this string to the set. Thus "ch" => {"c", "h"} + * If this set already any particular character, it has no effect on that character. + * A frozen set will not be modified. + * @param set the object to which to add the character + * @param str the source string + * @param strLen the length of the string or -1 if null terminated. + * @stable ICU 3.4 + */ +U_STABLE void U_EXPORT2 +uset_addAllCodePoints(USet* set, const UChar *str, int32_t strLen); + +/** * Removes the given character from the given USet. After this call, * uset_contains(set, c) will return FALSE. + * A frozen set will not be modified. * @param set the object from which to remove the character * @param c the character to remove * @stable ICU 2.4 @@ -362,6 +590,7 @@ uset_remove(USet* set, UChar32 c); /** * Removes the given range of characters from the given USet. After this call, * uset_contains(set, start, end) will return FALSE. + * A frozen set will not be modified. * @param set the object to which to add the character * @param start the first character of the range to remove, inclusive * @param end the last character of the range to remove, inclusive @@ -373,6 +602,7 @@ uset_removeRange(USet* set, UChar32 start, UChar32 end); /** * Removes the given string to the given USet. After this call, * uset_containsString(set, str, strLen) will return FALSE. + * A frozen set will not be modified. * @param set the object to which to add the character * @param str the string to remove * @param strLen the length of the string or -1 if null terminated. @@ -386,12 +616,13 @@ uset_removeString(USet* set, const UChar* str, int32_t strLen); * specified set. This operation effectively modifies this * set so that its value is the <i>asymmetric set difference</i> of * the two sets. + * A frozen set will not be modified. * @param set the object from which the elements are to be removed * @param removeSet the object that defines which elements will be * removed from this set - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT void U_EXPORT2 +U_STABLE void U_EXPORT2 uset_removeAll(USet* set, const USet* removeSet); /** @@ -399,15 +630,16 @@ uset_removeAll(USet* set, const USet* removeSet); * specified range. If <code>start > end</code> then an empty range is * retained, leaving the set empty. This is equivalent to * a boolean logic AND, or a set INTERSECTION. + * A frozen set will not be modified. * * @param set the object for which to retain only the specified range * @param start first character, inclusive, of range to be retained * to this set. * @param end last character, inclusive, of range to be retained * to this set. - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT void U_EXPORT2 +U_STABLE void U_EXPORT2 uset_retain(USet* set, UChar32 start, UChar32 end); /** @@ -416,28 +648,31 @@ uset_retain(USet* set, UChar32 start, UChar32 end); * its elements that are not contained in the specified set. This * operation effectively modifies this set so that its value is * the <i>intersection</i> of the two sets. + * A frozen set will not be modified. * * @param set the object on which to perform the retain * @param retain set that defines which elements this set will retain - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT void U_EXPORT2 +U_STABLE void U_EXPORT2 uset_retainAll(USet* set, const USet* retain); /** * Reallocate this objects internal structures to take up the least * possible space, without changing this object's value. + * A frozen set will not be modified. * * @param set the object on which to perfrom the compact - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT void U_EXPORT2 +U_STABLE void U_EXPORT2 uset_compact(USet* set); /** * Inverts this set. This operation modifies this set so that * its value is its complement. This operation does not affect * the multicharacter strings, if any. + * A frozen set will not be modified. * @param set the set * @stable ICU 2.4 */ @@ -448,18 +683,20 @@ uset_complement(USet* set); * Complements in this set all elements contained in the specified * set. Any character in the other set will be removed if it is * in this set, or will be added if it is not in this set. + * A frozen set will not be modified. * * @param set the set with which to complement * @param complement set that defines which elements will be xor'ed * from this set. - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT void U_EXPORT2 +U_STABLE void U_EXPORT2 uset_complementAll(USet* set, const USet* complement); /** * Removes all of the elements from this set. This set will be * empty after this call returns. + * A frozen set will not be modified. * @param set the set * @stable ICU 2.4 */ @@ -467,6 +704,44 @@ U_STABLE void U_EXPORT2 uset_clear(USet* set); /** + * Close this set over the given attribute. For the attribute + * USET_CASE, the result is to modify this set so that: + * + * 1. For each character or string 'a' in this set, all strings or + * characters 'b' such that foldCase(a) == foldCase(b) are added + * to this set. + * + * 2. For each string 'e' in the resulting set, if e != + * foldCase(e), 'e' will be removed. + * + * Example: [aq\\u00DF{Bc}{bC}{Fi}] => [aAqQ\\u00DF\\uFB01{ss}{bc}{fi}] + * + * (Here foldCase(x) refers to the operation u_strFoldCase, and a + * == b denotes that the contents are the same, not pointer + * comparison.) + * + * A frozen set will not be modified. + * + * @param set the set + * + * @param attributes bitmask for attributes to close over. + * Currently only the USET_CASE bit is supported. Any undefined bits + * are ignored. + * @stable ICU 4.2 + */ +U_STABLE void U_EXPORT2 +uset_closeOver(USet* set, int32_t attributes); + +/** + * Remove all strings from this set. + * + * @param set the set + * @stable ICU 4.2 + */ +U_STABLE void U_EXPORT2 +uset_removeAllStrings(USet* set); + +/** * Returns TRUE if the given USet contains no characters and no * strings. * @param set the set @@ -478,6 +753,7 @@ uset_isEmpty(const USet* set); /** * Returns TRUE if the given USet contains the given character. + * This function works faster with a frozen set. * @param set the set * @param c The codepoint to check for within the set * @return true if set contains c @@ -517,9 +793,9 @@ uset_containsString(const USet* set, const UChar* str, int32_t strLen); * @param set the set * @param c the character to obtain the index for * @return an index from 0..size()-1, or -1 - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 uset_indexOf(const USet* set, UChar32 c); /** @@ -528,12 +804,12 @@ uset_indexOf(const USet* set, UChar32 c); * out of range, return (UChar32)-1. The inverse of this method is * <code>indexOf()</code>. * @param set the set - * @param index an index from 0..size()-1 to obtain the char for + * @param charIndex an index from 0..size()-1 to obtain the char for * @return the character at the given index, or (UChar32)-1. - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT UChar32 U_EXPORT2 -uset_charAt(const USet* set, int32_t index); +U_STABLE UChar32 U_EXPORT2 +uset_charAt(const USet* set, int32_t charIndex); /** * Returns the number of characters and strings contained in the given @@ -583,24 +859,37 @@ uset_getItem(const USet* set, int32_t itemIndex, /** * Returns true if set1 contains all the characters and strings - * of set2. It answers the question, 'Is set1 a subset of set2?' + * of set2. It answers the question, 'Is set1 a superset of set2?' * @param set1 set to be checked for containment * @param set2 set to be checked for containment * @return true if the test condition is met - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT UBool U_EXPORT2 +U_STABLE UBool U_EXPORT2 uset_containsAll(const USet* set1, const USet* set2); /** + * Returns true if this set contains all the characters + * of the given string. This is does not check containment of grapheme + * clusters, like uset_containsString. + * @param set set of characters to be checked for containment + * @param str string containing codepoints to be checked for containment + * @param strLen the length of the string or -1 if null terminated. + * @return true if the test condition is met + * @stable ICU 3.4 + */ +U_STABLE UBool U_EXPORT2 +uset_containsAllCodePoints(const USet* set, const UChar *str, int32_t strLen); + +/** * Returns true if set1 contains none of the characters and strings * of set2. It answers the question, 'Is set1 a disjoint set of set2?' * @param set1 set to be checked for containment * @param set2 set to be checked for containment * @return true if the test condition is met - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT UBool U_EXPORT2 +U_STABLE UBool U_EXPORT2 uset_containsNone(const USet* set1, const USet* set2); /** @@ -609,20 +898,106 @@ uset_containsNone(const USet* set1, const USet* set2); * @param set1 set to be checked for containment * @param set2 set to be checked for containment * @return true if the test condition is met - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT UBool U_EXPORT2 +U_STABLE UBool U_EXPORT2 uset_containsSome(const USet* set1, const USet* set2); /** + * Returns the length of the initial substring of the input string which + * consists only of characters and strings that are contained in this set + * (USET_SPAN_CONTAINED, USET_SPAN_SIMPLE), + * or only of characters and strings that are not contained + * in this set (USET_SPAN_NOT_CONTAINED). + * See USetSpanCondition for details. + * Similar to the strspn() C library function. + * Unpaired surrogates are treated according to contains() of their surrogate code points. + * This function works faster with a frozen set and with a non-negative string length argument. + * @param set the set + * @param s start of the string + * @param length of the string; can be -1 for NUL-terminated + * @param spanCondition specifies the containment condition + * @return the length of the initial substring according to the spanCondition; + * 0 if the start of the string does not fit the spanCondition + * @stable ICU 3.8 + * @see USetSpanCondition + */ +U_STABLE int32_t U_EXPORT2 +uset_span(const USet *set, const UChar *s, int32_t length, USetSpanCondition spanCondition); + +/** + * Returns the start of the trailing substring of the input string which + * consists only of characters and strings that are contained in this set + * (USET_SPAN_CONTAINED, USET_SPAN_SIMPLE), + * or only of characters and strings that are not contained + * in this set (USET_SPAN_NOT_CONTAINED). + * See USetSpanCondition for details. + * Unpaired surrogates are treated according to contains() of their surrogate code points. + * This function works faster with a frozen set and with a non-negative string length argument. + * @param set the set + * @param s start of the string + * @param length of the string; can be -1 for NUL-terminated + * @param spanCondition specifies the containment condition + * @return the start of the trailing substring according to the spanCondition; + * the string length if the end of the string does not fit the spanCondition + * @stable ICU 3.8 + * @see USetSpanCondition + */ +U_STABLE int32_t U_EXPORT2 +uset_spanBack(const USet *set, const UChar *s, int32_t length, USetSpanCondition spanCondition); + +/** + * Returns the length of the initial substring of the input string which + * consists only of characters and strings that are contained in this set + * (USET_SPAN_CONTAINED, USET_SPAN_SIMPLE), + * or only of characters and strings that are not contained + * in this set (USET_SPAN_NOT_CONTAINED). + * See USetSpanCondition for details. + * Similar to the strspn() C library function. + * Malformed byte sequences are treated according to contains(0xfffd). + * This function works faster with a frozen set and with a non-negative string length argument. + * @param set the set + * @param s start of the string (UTF-8) + * @param length of the string; can be -1 for NUL-terminated + * @param spanCondition specifies the containment condition + * @return the length of the initial substring according to the spanCondition; + * 0 if the start of the string does not fit the spanCondition + * @stable ICU 3.8 + * @see USetSpanCondition + */ +U_STABLE int32_t U_EXPORT2 +uset_spanUTF8(const USet *set, const char *s, int32_t length, USetSpanCondition spanCondition); + +/** + * Returns the start of the trailing substring of the input string which + * consists only of characters and strings that are contained in this set + * (USET_SPAN_CONTAINED, USET_SPAN_SIMPLE), + * or only of characters and strings that are not contained + * in this set (USET_SPAN_NOT_CONTAINED). + * See USetSpanCondition for details. + * Malformed byte sequences are treated according to contains(0xfffd). + * This function works faster with a frozen set and with a non-negative string length argument. + * @param set the set + * @param s start of the string (UTF-8) + * @param length of the string; can be -1 for NUL-terminated + * @param spanCondition specifies the containment condition + * @return the start of the trailing substring according to the spanCondition; + * the string length if the end of the string does not fit the spanCondition + * @stable ICU 3.8 + * @see USetSpanCondition + */ +U_STABLE int32_t U_EXPORT2 +uset_spanBackUTF8(const USet *set, const char *s, int32_t length, USetSpanCondition spanCondition); + +/** * Returns true if set1 contains all of the characters and strings * of set2, and vis versa. It answers the question, 'Is set1 equal to set2?' * @param set1 set to be checked for containment * @param set2 set to be checked for containment * @return true if the test condition is met - * @draft ICU 3.2 + * @stable ICU 3.2 */ -U_DRAFT UBool U_EXPORT2 +U_STABLE UBool U_EXPORT2 uset_equals(const USet* set1, const USet* set2); /********************************************************************* diff --git a/Source/WTF/icu/unicode/ustring.h b/Source/WTF/icu/unicode/ustring.h index 6ebb6fbec..2ee16e99c 100644 --- a/Source/WTF/icu/unicode/ustring.h +++ b/Source/WTF/icu/unicode/ustring.h @@ -1,6 +1,6 @@ /* ********************************************************************** -* Copyright (C) 1998-2004, International Business Machines +* Copyright (C) 1998-2010, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************** * @@ -23,7 +23,7 @@ /** Simple declaration for u_strToTitle() to avoid including unicode/ubrk.h. @stable ICU 2.1*/ #ifndef UBRK_TYPEDEF_UBREAK_ITERATOR # define UBRK_TYPEDEF_UBREAK_ITERATOR - typedef void UBreakIterator; + typedef struct UBreakIterator UBreakIterator; #endif /** @@ -65,12 +65,17 @@ * their occurrence is rare. Almost all characters in modern use require only * a single UChar code unit (i.e., their code point values are <=0xffff). * - * For more details see the User Guide Strings chapter (http://oss.software.ibm.com/icu/userguide/strings.html). + * For more details see the User Guide Strings chapter (http://icu-project.org/userguide/strings.html). * For a discussion of the handling of unpaired surrogates see also * Jitterbug 2145 and its icu mailing list proposal on 2002-sep-18. */ /** + * \defgroup ustring_ustrlen String Length + * \ingroup ustring_strlen + */ +/*@{*/ +/** * Determine the length of an array of UChar. * * @param s The array of UChars, NULL (U+0000) terminated. @@ -79,6 +84,7 @@ */ U_STABLE int32_t U_EXPORT2 u_strlen(const UChar *s); +/*@}*/ /** * Count Unicode code points in the length UChar code units of the string. @@ -141,7 +147,7 @@ u_strcat(UChar *dst, * * @param dst The destination string. * @param src The source string. - * @param n The maximum number of characters to compare. + * @param n The maximum number of characters to append. * @return A pointer to <code>dst</code>. * @stable ICU 2.0 */ @@ -898,23 +904,41 @@ u_memrchr32(const UChar *s, UChar32 c, int32_t count); * * Usage: * <pre> - *   U_STRING_DECL(ustringVar1, "Quick-Fox 2", 11); - *   U_STRING_DECL(ustringVar2, "jumps 5%", 8); - *   static UBool didInit=FALSE; - *   - *   int32_t function() { - *   if(!didInit) { - *   U_STRING_INIT(ustringVar1, "Quick-Fox 2", 11); - *   U_STRING_INIT(ustringVar2, "jumps 5%", 8); - *   didInit=TRUE; - *   } - *   return u_strcmp(ustringVar1, ustringVar2); - *   } + * U_STRING_DECL(ustringVar1, "Quick-Fox 2", 11); + * U_STRING_DECL(ustringVar2, "jumps 5%", 8); + * static UBool didInit=FALSE; + * + * int32_t function() { + * if(!didInit) { + * U_STRING_INIT(ustringVar1, "Quick-Fox 2", 11); + * U_STRING_INIT(ustringVar2, "jumps 5%", 8); + * didInit=TRUE; + * } + * return u_strcmp(ustringVar1, ustringVar2); + * } + * </pre> + * + * Note that the macros will NOT consistently work if their argument is another #define. + * The following will not work on all platforms, don't use it. + * + * <pre> + * #define GLUCK "Mr. Gluck" + * U_STRING_DECL(var, GLUCK, 9) + * U_STRING_INIT(var, GLUCK, 9) * </pre> + * + * Instead, use the string literal "Mr. Gluck" as the argument to both macro + * calls. + * + * * @stable ICU 2.0 */ -#if U_SIZEOF_WCHAR_T==U_SIZEOF_UCHAR && U_CHARSET_FAMILY==U_ASCII_FAMILY -# define U_STRING_DECL(var, cs, length) static const wchar_t var[(length)+1]={ L ## cs } +#if defined(U_DECLARE_UTF16) +# define U_STRING_DECL(var, cs, length) static const UChar var[(length)+1]=U_DECLARE_UTF16(cs) + /**@stable ICU 2.0 */ +# define U_STRING_INIT(var, cs, length) +#elif U_SIZEOF_WCHAR_T==U_SIZEOF_UCHAR && (U_CHARSET_FAMILY==U_ASCII_FAMILY || (U_SIZEOF_UCHAR == 2 && defined(U_WCHAR_IS_UTF16))) +# define U_STRING_DECL(var, cs, length) static const UChar var[(length)+1]=L ## cs /**@stable ICU 2.0 */ # define U_STRING_INIT(var, cs, length) #elif U_SIZEOF_UCHAR==1 && U_CHARSET_FAMILY==U_ASCII_FAMILY @@ -943,7 +967,7 @@ u_memrchr32(const UChar *s, UChar32 c, int32_t count); * * \\a => U+0007, \\b => U+0008, \\t => U+0009, \\n => U+000A, * \\v => U+000B, \\f => U+000C, \\r => U+000D, \\e => U+001B, - * \\" => U+0022, \\' => U+0027, \\? => U+003F, \\\\ => U+005C + * \\" => U+0022, \\' => U+0027, \\? => U+003F, \\\\ => U+005C * * Anything else following a backslash is generically escaped. For * example, "[a\\-z]" returns "[a-z]". @@ -1096,7 +1120,7 @@ u_strToLower(UChar *dest, int32_t destCapacity, * The standard titlecase iterator for the root locale implements the * algorithm of Unicode TR 21. * - * This function uses only the first() and next() methods of the + * This function uses only the setText(), first() and next() methods of the * provided break iterator. * * The result may be longer or shorter than the original. @@ -1157,8 +1181,12 @@ u_strFoldCase(UChar *dest, int32_t destCapacity, uint32_t options, UErrorCode *pErrorCode); +#if defined(U_WCHAR_IS_UTF16) || defined(U_WCHAR_IS_UTF32) || !UCONFIG_NO_CONVERSION /** - * Converts a sequence of UChars to wchar_t units. + * Convert a UTF-16 string to a wchar_t string. + * If it is known at compile time that wchar_t strings are in UTF-16 or UTF-32, then + * this function simply calls the fast, dedicated function for that. + * Otherwise, two conversions UTF-16 -> default charset -> wchar_t* are performed. * * @param dest A buffer for the result string. The result will be zero-terminated if * the buffer is large enough. @@ -1184,7 +1212,10 @@ u_strToWCS(wchar_t *dest, int32_t srcLength, UErrorCode *pErrorCode); /** - * Converts a sequence of wchar_t units to UChars + * Convert a wchar_t string to UTF-16. + * If it is known at compile time that wchar_t strings are in UTF-16 or UTF-32, then + * this function simply calls the fast, dedicated function for that. + * Otherwise, two conversions wchar_t* -> default charset -> UTF-16 are performed. * * @param dest A buffer for the result string. The result will be zero-terminated if * the buffer is large enough. @@ -1209,8 +1240,11 @@ u_strFromWCS(UChar *dest, const wchar_t *src, int32_t srcLength, UErrorCode *pErrorCode); +#endif /* defined(U_WCHAR_IS_UTF16) || defined(U_WCHAR_IS_UTF32) || !UCONFIG_NO_CONVERSION */ + /** - * Converts a sequence of UChars (UTF-16) to UTF-8 bytes + * Convert a UTF-16 string to UTF-8. + * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set. * * @param dest A buffer for the result string. The result will be zero-terminated if * the buffer is large enough. @@ -1227,6 +1261,8 @@ u_strFromWCS(UChar *dest, * which must not indicate a failure before the function call. * @return The pointer to destination buffer. * @stable ICU 2.0 + * @see u_strToUTF8WithSub + * @see u_strFromUTF8 */ U_STABLE char* U_EXPORT2 u_strToUTF8(char *dest, @@ -1237,7 +1273,8 @@ u_strToUTF8(char *dest, UErrorCode *pErrorCode); /** - * Converts a sequence of UTF-8 bytes to UChars (UTF-16). + * Convert a UTF-8 string to UTF-16. + * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set. * * @param dest A buffer for the result string. The result will be zero-terminated if * the buffer is large enough. @@ -1254,6 +1291,8 @@ u_strToUTF8(char *dest, * which must not indicate a failure before the function call. * @return The pointer to destination buffer. * @stable ICU 2.0 + * @see u_strFromUTF8WithSub + * @see u_strFromUTF8Lenient */ U_STABLE UChar* U_EXPORT2 u_strFromUTF8(UChar *dest, @@ -1264,7 +1303,158 @@ u_strFromUTF8(UChar *dest, UErrorCode *pErrorCode); /** - * Converts a sequence of UChars (UTF-16) to UTF32 units. + * Convert a UTF-16 string to UTF-8. + * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set. + * + * Same as u_strToUTF8() except for the additional subchar which is output for + * illegal input sequences, instead of stopping with the U_INVALID_CHAR_FOUND error code. + * With subchar==U_SENTINEL, this function behaves exactly like u_strToUTF8(). + * + * @param dest A buffer for the result string. The result will be zero-terminated if + * the buffer is large enough. + * @param destCapacity The size of the buffer (number of chars). If it is 0, then + * dest may be NULL and the function will only return the length of the + * result without writing any of the result string (pre-flighting). + * @param pDestLength A pointer to receive the number of units written to the destination. If + * pDestLength!=NULL then *pDestLength is always set to the + * number of output units corresponding to the transformation of + * all the input units, even in case of a buffer overflow. + * @param src The original source string + * @param srcLength The length of the original string. If -1, then src must be zero-terminated. + * @param subchar The substitution character to use in place of an illegal input sequence, + * or U_SENTINEL if the function is to return with U_INVALID_CHAR_FOUND instead. + * A substitution character can be any valid Unicode code point (up to U+10FFFF) + * except for surrogate code points (U+D800..U+DFFF). + * The recommended value is U+FFFD "REPLACEMENT CHARACTER". + * @param pNumSubstitutions Output parameter receiving the number of substitutions if subchar>=0. + * Set to 0 if no substitutions occur or subchar<0. + * pNumSubstitutions can be NULL. + * @param pErrorCode Pointer to a standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return The pointer to destination buffer. + * @see u_strToUTF8 + * @see u_strFromUTF8WithSub + * @stable ICU 3.6 + */ +U_STABLE char* U_EXPORT2 +u_strToUTF8WithSub(char *dest, + int32_t destCapacity, + int32_t *pDestLength, + const UChar *src, + int32_t srcLength, + UChar32 subchar, int32_t *pNumSubstitutions, + UErrorCode *pErrorCode); + +/** + * Convert a UTF-8 string to UTF-16. + * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set. + * + * Same as u_strFromUTF8() except for the additional subchar which is output for + * illegal input sequences, instead of stopping with the U_INVALID_CHAR_FOUND error code. + * With subchar==U_SENTINEL, this function behaves exactly like u_strFromUTF8(). + * + * @param dest A buffer for the result string. The result will be zero-terminated if + * the buffer is large enough. + * @param destCapacity The size of the buffer (number of UChars). If it is 0, then + * dest may be NULL and the function will only return the length of the + * result without writing any of the result string (pre-flighting). + * @param pDestLength A pointer to receive the number of units written to the destination. If + * pDestLength!=NULL then *pDestLength is always set to the + * number of output units corresponding to the transformation of + * all the input units, even in case of a buffer overflow. + * @param src The original source string + * @param srcLength The length of the original string. If -1, then src must be zero-terminated. + * @param subchar The substitution character to use in place of an illegal input sequence, + * or U_SENTINEL if the function is to return with U_INVALID_CHAR_FOUND instead. + * A substitution character can be any valid Unicode code point (up to U+10FFFF) + * except for surrogate code points (U+D800..U+DFFF). + * The recommended value is U+FFFD "REPLACEMENT CHARACTER". + * @param pNumSubstitutions Output parameter receiving the number of substitutions if subchar>=0. + * Set to 0 if no substitutions occur or subchar<0. + * pNumSubstitutions can be NULL. + * @param pErrorCode Pointer to a standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return The pointer to destination buffer. + * @see u_strFromUTF8 + * @see u_strFromUTF8Lenient + * @see u_strToUTF8WithSub + * @stable ICU 3.6 + */ +U_STABLE UChar* U_EXPORT2 +u_strFromUTF8WithSub(UChar *dest, + int32_t destCapacity, + int32_t *pDestLength, + const char *src, + int32_t srcLength, + UChar32 subchar, int32_t *pNumSubstitutions, + UErrorCode *pErrorCode); + +/** + * Convert a UTF-8 string to UTF-16. + * + * Same as u_strFromUTF8() except that this function is designed to be very fast, + * which it achieves by being lenient about malformed UTF-8 sequences. + * This function is intended for use in environments where UTF-8 text is + * expected to be well-formed. + * + * Its semantics are: + * - Well-formed UTF-8 text is correctly converted to well-formed UTF-16 text. + * - The function will not read beyond the input string, nor write beyond + * the destCapacity. + * - Malformed UTF-8 results in "garbage" 16-bit Unicode strings which may not + * be well-formed UTF-16. + * The function will resynchronize to valid code point boundaries + * within a small number of code points after an illegal sequence. + * - Non-shortest forms are not detected and will result in "spoofing" output. + * + * For further performance improvement, if srcLength is given (>=0), + * then it must be destCapacity>=srcLength. + * + * There is no inverse u_strToUTF8Lenient() function because there is practically + * no performance gain from not checking that a UTF-16 string is well-formed. + * + * @param dest A buffer for the result string. The result will be zero-terminated if + * the buffer is large enough. + * @param destCapacity The size of the buffer (number of UChars). If it is 0, then + * dest may be NULL and the function will only return the length of the + * result without writing any of the result string (pre-flighting). + * Unlike for other ICU functions, if srcLength>=0 then it + * must be destCapacity>=srcLength. + * @param pDestLength A pointer to receive the number of units written to the destination. If + * pDestLength!=NULL then *pDestLength is always set to the + * number of output units corresponding to the transformation of + * all the input units, even in case of a buffer overflow. + * Unlike for other ICU functions, if srcLength>=0 but + * destCapacity<srcLength, then *pDestLength will be set to srcLength + * (and U_BUFFER_OVERFLOW_ERROR will be set) + * regardless of the actual result length. + * @param src The original source string + * @param srcLength The length of the original string. If -1, then src must be zero-terminated. + * @param pErrorCode Pointer to a standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return The pointer to destination buffer. + * @see u_strFromUTF8 + * @see u_strFromUTF8WithSub + * @see u_strToUTF8WithSub + * @stable ICU 3.6 + */ +U_STABLE UChar * U_EXPORT2 +u_strFromUTF8Lenient(UChar *dest, + int32_t destCapacity, + int32_t *pDestLength, + const char *src, + int32_t srcLength, + UErrorCode *pErrorCode); + +/** + * Convert a UTF-16 string to UTF-32. + * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set. * * @param dest A buffer for the result string. The result will be zero-terminated if * the buffer is large enough. @@ -1280,6 +1470,8 @@ u_strFromUTF8(UChar *dest, * @param pErrorCode Must be a valid pointer to an error code value, * which must not indicate a failure before the function call. * @return The pointer to destination buffer. + * @see u_strToUTF32WithSub + * @see u_strFromUTF32 * @stable ICU 2.0 */ U_STABLE UChar32* U_EXPORT2 @@ -1291,7 +1483,8 @@ u_strToUTF32(UChar32 *dest, UErrorCode *pErrorCode); /** - * Converts a sequence of UTF32 units to UChars (UTF-16) + * Convert a UTF-32 string to UTF-16. + * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set. * * @param dest A buffer for the result string. The result will be zero-terminated if * the buffer is large enough. @@ -1307,6 +1500,8 @@ u_strToUTF32(UChar32 *dest, * @param pErrorCode Must be a valid pointer to an error code value, * which must not indicate a failure before the function call. * @return The pointer to destination buffer. + * @see u_strFromUTF32WithSub + * @see u_strToUTF32 * @stable ICU 2.0 */ U_STABLE UChar* U_EXPORT2 @@ -1317,4 +1512,185 @@ u_strFromUTF32(UChar *dest, int32_t srcLength, UErrorCode *pErrorCode); +/** + * Convert a UTF-16 string to UTF-32. + * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set. + * + * Same as u_strToUTF32() except for the additional subchar which is output for + * illegal input sequences, instead of stopping with the U_INVALID_CHAR_FOUND error code. + * With subchar==U_SENTINEL, this function behaves exactly like u_strToUTF32(). + * + * @param dest A buffer for the result string. The result will be zero-terminated if + * the buffer is large enough. + * @param destCapacity The size of the buffer (number of UChar32s). If it is 0, then + * dest may be NULL and the function will only return the length of the + * result without writing any of the result string (pre-flighting). + * @param pDestLength A pointer to receive the number of units written to the destination. If + * pDestLength!=NULL then *pDestLength is always set to the + * number of output units corresponding to the transformation of + * all the input units, even in case of a buffer overflow. + * @param src The original source string + * @param srcLength The length of the original string. If -1, then src must be zero-terminated. + * @param subchar The substitution character to use in place of an illegal input sequence, + * or U_SENTINEL if the function is to return with U_INVALID_CHAR_FOUND instead. + * A substitution character can be any valid Unicode code point (up to U+10FFFF) + * except for surrogate code points (U+D800..U+DFFF). + * The recommended value is U+FFFD "REPLACEMENT CHARACTER". + * @param pNumSubstitutions Output parameter receiving the number of substitutions if subchar>=0. + * Set to 0 if no substitutions occur or subchar<0. + * pNumSubstitutions can be NULL. + * @param pErrorCode Pointer to a standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return The pointer to destination buffer. + * @see u_strToUTF32 + * @see u_strFromUTF32WithSub + * @stable ICU 4.2 + */ +U_STABLE UChar32* U_EXPORT2 +u_strToUTF32WithSub(UChar32 *dest, + int32_t destCapacity, + int32_t *pDestLength, + const UChar *src, + int32_t srcLength, + UChar32 subchar, int32_t *pNumSubstitutions, + UErrorCode *pErrorCode); + +/** + * Convert a UTF-32 string to UTF-16. + * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set. + * + * Same as u_strFromUTF32() except for the additional subchar which is output for + * illegal input sequences, instead of stopping with the U_INVALID_CHAR_FOUND error code. + * With subchar==U_SENTINEL, this function behaves exactly like u_strFromUTF32(). + * + * @param dest A buffer for the result string. The result will be zero-terminated if + * the buffer is large enough. + * @param destCapacity The size of the buffer (number of UChars). If it is 0, then + * dest may be NULL and the function will only return the length of the + * result without writing any of the result string (pre-flighting). + * @param pDestLength A pointer to receive the number of units written to the destination. If + * pDestLength!=NULL then *pDestLength is always set to the + * number of output units corresponding to the transformation of + * all the input units, even in case of a buffer overflow. + * @param src The original source string + * @param srcLength The length of the original string. If -1, then src must be zero-terminated. + * @param subchar The substitution character to use in place of an illegal input sequence, + * or U_SENTINEL if the function is to return with U_INVALID_CHAR_FOUND instead. + * A substitution character can be any valid Unicode code point (up to U+10FFFF) + * except for surrogate code points (U+D800..U+DFFF). + * The recommended value is U+FFFD "REPLACEMENT CHARACTER". + * @param pNumSubstitutions Output parameter receiving the number of substitutions if subchar>=0. + * Set to 0 if no substitutions occur or subchar<0. + * pNumSubstitutions can be NULL. + * @param pErrorCode Pointer to a standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return The pointer to destination buffer. + * @see u_strFromUTF32 + * @see u_strToUTF32WithSub + * @stable ICU 4.2 + */ +U_STABLE UChar* U_EXPORT2 +u_strFromUTF32WithSub(UChar *dest, + int32_t destCapacity, + int32_t *pDestLength, + const UChar32 *src, + int32_t srcLength, + UChar32 subchar, int32_t *pNumSubstitutions, + UErrorCode *pErrorCode); + +/** + * Convert a 16-bit Unicode string to Java Modified UTF-8. + * See http://java.sun.com/javase/6/docs/api/java/io/DataInput.html#modified-utf-8 + * + * This function behaves according to the documentation for Java DataOutput.writeUTF() + * except that it does not encode the output length in the destination buffer + * and does not have an output length restriction. + * See http://java.sun.com/javase/6/docs/api/java/io/DataOutput.html#writeUTF(java.lang.String) + * + * The input string need not be well-formed UTF-16. + * (Therefore there is no subchar parameter.) + * + * @param dest A buffer for the result string. The result will be zero-terminated if + * the buffer is large enough. + * @param destCapacity The size of the buffer (number of chars). If it is 0, then + * dest may be NULL and the function will only return the length of the + * result without writing any of the result string (pre-flighting). + * @param pDestLength A pointer to receive the number of units written to the destination. If + * pDestLength!=NULL then *pDestLength is always set to the + * number of output units corresponding to the transformation of + * all the input units, even in case of a buffer overflow. + * @param src The original source string + * @param srcLength The length of the original string. If -1, then src must be zero-terminated. + * @param pErrorCode Pointer to a standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return The pointer to destination buffer. + * @stable ICU 4.4 + * @see u_strToUTF8WithSub + * @see u_strFromJavaModifiedUTF8WithSub + */ +U_STABLE char* U_EXPORT2 +u_strToJavaModifiedUTF8( + char *dest, + int32_t destCapacity, + int32_t *pDestLength, + const UChar *src, + int32_t srcLength, + UErrorCode *pErrorCode); + +/** + * Convert a Java Modified UTF-8 string to a 16-bit Unicode string. + * If the input string is not well-formed, then the U_INVALID_CHAR_FOUND error code is set. + * + * This function behaves according to the documentation for Java DataInput.readUTF() + * except that it takes a length parameter rather than + * interpreting the first two input bytes as the length. + * See http://java.sun.com/javase/6/docs/api/java/io/DataInput.html#readUTF() + * + * The output string may not be well-formed UTF-16. + * + * @param dest A buffer for the result string. The result will be zero-terminated if + * the buffer is large enough. + * @param destCapacity The size of the buffer (number of UChars). If it is 0, then + * dest may be NULL and the function will only return the length of the + * result without writing any of the result string (pre-flighting). + * @param pDestLength A pointer to receive the number of units written to the destination. If + * pDestLength!=NULL then *pDestLength is always set to the + * number of output units corresponding to the transformation of + * all the input units, even in case of a buffer overflow. + * @param src The original source string + * @param srcLength The length of the original string. If -1, then src must be zero-terminated. + * @param subchar The substitution character to use in place of an illegal input sequence, + * or U_SENTINEL if the function is to return with U_INVALID_CHAR_FOUND instead. + * A substitution character can be any valid Unicode code point (up to U+10FFFF) + * except for surrogate code points (U+D800..U+DFFF). + * The recommended value is U+FFFD "REPLACEMENT CHARACTER". + * @param pNumSubstitutions Output parameter receiving the number of substitutions if subchar>=0. + * Set to 0 if no substitutions occur or subchar<0. + * pNumSubstitutions can be NULL. + * @param pErrorCode Pointer to a standard ICU error code. Its input value must + * pass the U_SUCCESS() test, or else the function returns + * immediately. Check for U_FAILURE() on output or use with + * function chaining. (See User Guide for details.) + * @return The pointer to destination buffer. + * @see u_strFromUTF8WithSub + * @see u_strFromUTF8Lenient + * @see u_strToJavaModifiedUTF8 + * @stable ICU 4.4 + */ +U_STABLE UChar* U_EXPORT2 +u_strFromJavaModifiedUTF8WithSub( + UChar *dest, + int32_t destCapacity, + int32_t *pDestLength, + const char *src, + int32_t srcLength, + UChar32 subchar, int32_t *pNumSubstitutions, + UErrorCode *pErrorCode); + #endif diff --git a/Source/WTF/icu/unicode/utf.h b/Source/WTF/icu/unicode/utf.h index 201691d09..f79479935 100644 --- a/Source/WTF/icu/unicode/utf.h +++ b/Source/WTF/icu/unicode/utf.h @@ -1,7 +1,7 @@ /* ******************************************************************************* * -* Copyright (C) 1999-2004, International Business Machines +* Copyright (C) 1999-2010, International Business Machines * Corporation and others. All Rights Reserved. * ******************************************************************************* @@ -63,6 +63,14 @@ * malformed sequences can be expressed unambiguously with a distinct subrange * of Unicode code points.) * + * The regular "safe" macros require that the initial, passed-in string index + * is within bounds. They only check the index when they read more than one + * code unit. This is usually done with code similar to the following loop: + * <pre>while(i<length) { + * U16_NEXT(s, i, length, c); + * // use c + * }</pre> + * * When it is safe to assume that text is well-formed UTF-16 * (does not contain single, unpaired surrogates), then one can use * U16_..._UNSAFE macros. @@ -80,12 +88,14 @@ * The unsafe UTF-8 macros are entirely implemented inside the macro definitions * and are fast, while the safe UTF-8 macros call functions for all but the * trivial (ASCII) cases. + * (ICU 3.6 optimizes U8_NEXT() and U8_APPEND() to handle most other common + * characters inline as well.) * * Unlike with UTF-16, malformed sequences cannot be expressed with distinct * code point values (0..U+10ffff). They are indicated with negative values instead. * * For more information see the ICU User Guide Strings chapter - * (http://oss.software.ibm.com/icu/userguide/). + * (http://icu-project.org/userguide/strings.html). * * <em>Usage:</em> * ICU coding guidelines for if() statements should be followed when using these macros. @@ -157,13 +167,11 @@ (uint32_t)(c)<=0x10ffff && \ !U_IS_UNICODE_NONCHAR(c))) -#ifndef U_HIDE_DRAFT_API - /** * Is this code point a BMP code point (U+0000..U+ffff)? * @param c 32-bit code point * @return TRUE or FALSE - * @draft ICU 2.8 + * @stable ICU 2.8 */ #define U_IS_BMP(c) ((uint32_t)(c)<=0xffff) @@ -171,11 +179,9 @@ * Is this code point a supplementary code point (U+10000..U+10ffff)? * @param c 32-bit code point * @return TRUE or FALSE - * @draft ICU 2.8 + * @stable ICU 2.8 */ #define U_IS_SUPPLEMENTARY(c) ((uint32_t)((c)-0x10000)<=0xfffff) - -#endif /*U_HIDE_DRAFT_API*/ /** * Is this code point a lead surrogate (U+d800..U+dbff)? @@ -210,6 +216,15 @@ */ #define U_IS_SURROGATE_LEAD(c) (((c)&0x400)==0) +/** + * Assuming c is a surrogate code point (U_IS_SURROGATE(c)), + * is it a trail surrogate? + * @param c 32-bit code point + * @return TRUE or FALSE + * @stable ICU 4.2 + */ +#define U_IS_SURROGATE_TRAIL(c) (((c)&0x400)!=0) + /* include the utfXX.h ------------------------------------------------------ */ #include "unicode/utf8.h" diff --git a/Source/WTF/icu/unicode/utf16.h b/Source/WTF/icu/unicode/utf16.h index 7bf387207..5079c1146 100644 --- a/Source/WTF/icu/unicode/utf16.h +++ b/Source/WTF/icu/unicode/utf16.h @@ -1,7 +1,7 @@ /* ******************************************************************************* * -* Copyright (C) 1999-2004, International Business Machines +* Copyright (C) 1999-2010, International Business Machines * Corporation and others. All Rights Reserved. * ******************************************************************************* @@ -23,7 +23,7 @@ * and some common definitions. * * For more information see utf.h and the ICU User Guide Strings chapter - * (http://oss.software.ibm.com/icu/userguide/). + * (http://icu-project.org/userguide/strings.html). * * <em>Usage:</em> * ICU coding guidelines for if() statements should be followed when using these macros. @@ -83,6 +83,15 @@ #define U16_IS_SURROGATE_LEAD(c) (((c)&0x400)==0) /** + * Assuming c is a surrogate code point (U16_IS_SURROGATE(c)), + * is it a trail surrogate? + * @param c 16-bit code unit + * @return TRUE or FALSE + * @stable ICU 4.2 + */ +#define U16_IS_SURROGATE_TRAIL(c) (((c)&0x400)!=0) + +/** * Helper constant for U16_GET_SUPPLEMENTARY. * @internal */ @@ -179,7 +188,7 @@ * * @param s const UChar * string * @param start starting string offset (usually 0) - * @param i string offset, start<=i<length + * @param i string offset, must be start<=i<length * @param length string length * @param c output UChar32 variable * @see U16_GET_UNSAFE @@ -194,7 +203,7 @@ (c)=U16_GET_SUPPLEMENTARY((c), __c2); \ } \ } else { \ - if((i)-1>=(start) && U16_IS_LEAD(__c2=(s)[(i)-1])) { \ + if((i)>(start) && U16_IS_LEAD(__c2=(s)[(i)-1])) { \ (c)=U16_GET_SUPPLEMENTARY(__c2, (c)); \ } \ } \ @@ -243,7 +252,7 @@ * will be returned as the code point. * * @param s const UChar * string - * @param i string offset, i<length + * @param i string offset, must be i<length * @param length string length * @param c output UChar32 variable * @see U16_NEXT_UNSAFE @@ -292,7 +301,7 @@ * then isError is set to TRUE. * * @param s const UChar * string buffer - * @param i string offset, i<length + * @param i string offset, must be i<capacity * @param capacity size of the string buffer * @param c code point to append * @param isError output UBool set to TRUE if an error occurs, otherwise not modified @@ -332,7 +341,7 @@ * "Safe" macro, handles unpaired surrogates and checks for string boundaries. * * @param s const UChar * string - * @param i string offset, i<length + * @param i string offset, must be i<length * @param length string length * @see U16_FWD_1_UNSAFE * @stable ICU 2.4 @@ -370,7 +379,7 @@ * "Safe" macro, handles unpaired surrogates and checks for string boundaries. * * @param s const UChar * string - * @param i string offset, i<length + * @param i string offset, must be i<length * @param length string length * @param n number of code points to skip * @see U16_FWD_N_UNSAFE @@ -413,7 +422,7 @@ * * @param s const UChar * string * @param start starting string offset (usually 0) - * @param i string offset, start<=i + * @param i string offset, must be start<=i * @see U16_SET_CP_START_UNSAFE * @stable ICU 2.4 */ @@ -468,7 +477,7 @@ * * @param s const UChar * string * @param start starting string offset (usually 0) - * @param i string offset, start<=i + * @param i string offset, must be start<i * @param c output UChar32 variable * @see U16_PREV_UNSAFE * @stable ICU 2.4 @@ -509,7 +518,7 @@ * * @param s const UChar * string * @param start starting string offset (usually 0) - * @param i string offset, start<=i + * @param i string offset, must be start<i * @see U16_BACK_1_UNSAFE * @stable ICU 2.4 */ @@ -549,7 +558,7 @@ * * @param s const UChar * string * @param start start of string - * @param i string offset, i<length + * @param i string offset, must be start<i * @param n number of code points to skip * @see U16_BACK_N_UNSAFE * @stable ICU 2.4 diff --git a/Source/WTF/icu/unicode/utf8.h b/Source/WTF/icu/unicode/utf8.h index f83662bad..6405795a5 100644 --- a/Source/WTF/icu/unicode/utf8.h +++ b/Source/WTF/icu/unicode/utf8.h @@ -1,7 +1,7 @@ /* ******************************************************************************* * -* Copyright (C) 1999-2004, International Business Machines +* Copyright (C) 1999-2009, International Business Machines * Corporation and others. All Rights Reserved. * ******************************************************************************* @@ -23,7 +23,7 @@ * and some common definitions. * * For more information see utf.h and the ICU User Guide Strings chapter - * (http://oss.software.ibm.com/icu/userguide/). + * (http://icu-project.org/userguide/strings.html). * * <em>Usage:</em> * ICU coding guidelines for if() statements should be followed when using these macros. @@ -45,11 +45,16 @@ * \var utf8_countTrailBytes * Internal array with numbers of trail bytes for any given byte used in * lead byte position. + * + * This is internal since it is not meant to be called directly by external clients; + * however it is called by public macros in this file and thus must remain stable, + * and should not be hidden when other internal functions are hidden (otherwise + * public macros would fail to compile). * @internal */ #ifdef U_UTF8_IMPL -U_INTERNAL const uint8_t -#elif defined(U_STATIC_IMPLEMENTATION) +U_EXPORT const uint8_t +#elif defined(U_STATIC_IMPLEMENTATION) || defined(U_COMMON_IMPLEMENTATION) U_CFUNC const uint8_t #else U_CFUNC U_IMPORT const uint8_t /* U_IMPORT2? */ /*U_IMPORT*/ @@ -58,42 +63,68 @@ utf8_countTrailBytes[256]; /** * Count the trail bytes for a UTF-8 lead byte. + * + * This is internal since it is not meant to be called directly by external clients; + * however it is called by public macros in this file and thus must remain stable. * @internal */ #define U8_COUNT_TRAIL_BYTES(leadByte) (utf8_countTrailBytes[(uint8_t)leadByte]) /** * Mask a UTF-8 lead byte, leave only the lower bits that form part of the code point value. + * + * This is internal since it is not meant to be called directly by external clients; + * however it is called by public macros in this file and thus must remain stable. * @internal */ #define U8_MASK_LEAD_BYTE(leadByte, countTrailBytes) ((leadByte)&=(1<<(6-(countTrailBytes)))-1) /** * Function for handling "next code point" with error-checking. + * + * This is internal since it is not meant to be called directly by external clients; + * however it is U_STABLE (not U_INTERNAL) since it is called by public macros in this + * file and thus must remain stable, and should not be hidden when other internal + * functions are hidden (otherwise public macros would fail to compile). * @internal */ -U_INTERNAL UChar32 U_EXPORT2 +U_STABLE UChar32 U_EXPORT2 utf8_nextCharSafeBody(const uint8_t *s, int32_t *pi, int32_t length, UChar32 c, UBool strict); /** * Function for handling "append code point" with error-checking. + * + * This is internal since it is not meant to be called directly by external clients; + * however it is U_STABLE (not U_INTERNAL) since it is called by public macros in this + * file and thus must remain stable, and should not be hidden when other internal + * functions are hidden (otherwise public macros would fail to compile). * @internal */ -U_INTERNAL int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 utf8_appendCharSafeBody(uint8_t *s, int32_t i, int32_t length, UChar32 c, UBool *pIsError); /** * Function for handling "previous code point" with error-checking. + * + * This is internal since it is not meant to be called directly by external clients; + * however it is U_STABLE (not U_INTERNAL) since it is called by public macros in this + * file and thus must remain stable, and should not be hidden when other internal + * functions are hidden (otherwise public macros would fail to compile). * @internal */ -U_INTERNAL UChar32 U_EXPORT2 +U_STABLE UChar32 U_EXPORT2 utf8_prevCharSafeBody(const uint8_t *s, int32_t start, int32_t *pi, UChar32 c, UBool strict); /** * Function for handling "skip backward one code point" with error-checking. + * + * This is internal since it is not meant to be called directly by external clients; + * however it is U_STABLE (not U_INTERNAL) since it is called by public macros in this + * file and thus must remain stable, and should not be hidden when other internal + * functions are hidden (otherwise public macros would fail to compile). * @internal */ -U_INTERNAL int32_t U_EXPORT2 +U_STABLE int32_t U_EXPORT2 utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); /* single-code point definitions -------------------------------------------- */ @@ -181,7 +212,7 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * * @param s const uint8_t * string * @param start starting string offset - * @param i string offset, start<=i<length + * @param i string offset, must be start<=i<length * @param length string length * @param c output UChar32 variable, set to <0 in case of an error * @see U8_GET_UNSAFE @@ -213,7 +244,7 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * @stable ICU 2.4 */ #define U8_NEXT_UNSAFE(s, i, c) { \ - (c)=(s)[(i)++]; \ + (c)=(uint8_t)(s)[(i)++]; \ if((uint8_t)((c)-0xc0)<0x35) { \ uint8_t __count=U8_COUNT_TRAIL_BYTES(c); \ U8_MASK_LEAD_BYTE(c, __count); \ @@ -243,16 +274,34 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * c is set to a negative value. * * @param s const uint8_t * string - * @param i string offset, i<length + * @param i string offset, must be i<length * @param length string length * @param c output UChar32 variable, set to <0 in case of an error * @see U8_NEXT_UNSAFE * @stable ICU 2.4 */ #define U8_NEXT(s, i, length, c) { \ - (c)=(s)[(i)++]; \ - if(((uint8_t)(c))>=0x80) { \ - if(U8_IS_LEAD(c)) { \ + (c)=(uint8_t)(s)[(i)++]; \ + if((c)>=0x80) { \ + uint8_t __t1, __t2; \ + if( /* handle U+1000..U+CFFF inline */ \ + (0xe0<(c) && (c)<=0xec) && \ + (((i)+1)<(length)) && \ + (__t1=(uint8_t)((s)[i]-0x80))<=0x3f && \ + (__t2=(uint8_t)((s)[(i)+1]-0x80))<= 0x3f \ + ) { \ + /* no need for (c&0xf) because the upper bits are truncated after <<12 in the cast to (UChar) */ \ + (c)=(UChar)(((c)<<12)|(__t1<<6)|__t2); \ + (i)+=2; \ + } else if( /* handle U+0080..U+07FF inline */ \ + ((c)<0xe0 && (c)>=0xc2) && \ + ((i)<(length)) && \ + (__t1=(uint8_t)((s)[i]-0x80))<=0x3f \ + ) { \ + (c)=(UChar)((((c)&0x1f)<<6)|__t1); \ + ++(i); \ + } else if(U8_IS_LEAD(c)) { \ + /* function call for "complicated" and error cases */ \ (c)=utf8_nextCharSafeBody((const uint8_t *)s, &(i), (int32_t)(length), c, -1); \ } else { \ (c)=U_SENTINEL; \ @@ -293,7 +342,7 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); } /** - * Append a code point to a string, overwriting 1 or 2 code units. + * Append a code point to a string, overwriting 1 to 4 bytes. * The offset points to the current end of the string contents * and is advanced (post-increment). * "Safe" macro, checks for a valid code point. @@ -302,18 +351,25 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * then isError is set to TRUE. * * @param s const uint8_t * string buffer - * @param i string offset, i<length - * @param length size of the string buffer + * @param i string offset, must be i<capacity + * @param capacity size of the string buffer * @param c code point to append * @param isError output UBool set to TRUE if an error occurs, otherwise not modified * @see U8_APPEND_UNSAFE * @stable ICU 2.4 */ -#define U8_APPEND(s, i, length, c, isError) { \ +#define U8_APPEND(s, i, capacity, c, isError) { \ if((uint32_t)(c)<=0x7f) { \ (s)[(i)++]=(uint8_t)(c); \ + } else if((uint32_t)(c)<=0x7ff && (i)+1<(capacity)) { \ + (s)[(i)++]=(uint8_t)(((c)>>6)|0xc0); \ + (s)[(i)++]=(uint8_t)(((c)&0x3f)|0x80); \ + } else if((uint32_t)(c)<=0xd7ff && (i)+2<(capacity)) { \ + (s)[(i)++]=(uint8_t)(((c)>>12)|0xe0); \ + (s)[(i)++]=(uint8_t)((((c)>>6)&0x3f)|0x80); \ + (s)[(i)++]=(uint8_t)(((c)&0x3f)|0x80); \ } else { \ - (i)=utf8_appendCharSafeBody(s, (int32_t)(i), (int32_t)(length), c, &(isError)); \ + (i)=utf8_appendCharSafeBody(s, (int32_t)(i), (int32_t)(capacity), c, &(isError)); \ } \ } @@ -337,13 +393,13 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * "Safe" macro, checks for illegal sequences and for string boundaries. * * @param s const uint8_t * string - * @param i string offset, i<length + * @param i string offset, must be i<length * @param length string length * @see U8_FWD_1_UNSAFE * @stable ICU 2.4 */ #define U8_FWD_1(s, i, length) { \ - uint8_t __b=(s)[(i)++]; \ + uint8_t __b=(uint8_t)(s)[(i)++]; \ if(U8_IS_LEAD(__b)) { \ uint8_t __count=U8_COUNT_TRAIL_BYTES(__b); \ if((i)+__count>(length)) { \ @@ -383,7 +439,7 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * "Safe" macro, checks for illegal sequences and for string boundaries. * * @param s const uint8_t * string - * @param i string offset, i<length + * @param i string offset, must be i<length * @param length string length * @param n number of code points to skip * @see U8_FWD_N_UNSAFE @@ -424,7 +480,7 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * * @param s const uint8_t * string * @param start starting string offset (usually 0) - * @param i string offset, start<=i + * @param i string offset, must be start<=i * @see U8_SET_CP_START_UNSAFE * @stable ICU 2.4 */ @@ -456,14 +512,14 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * @stable ICU 2.4 */ #define U8_PREV_UNSAFE(s, i, c) { \ - (c)=(s)[--(i)]; \ + (c)=(uint8_t)(s)[--(i)]; \ if(U8_IS_TRAIL(c)) { \ uint8_t __b, __count=1, __shift=6; \ \ /* c is a trail byte */ \ (c)&=0x3f; \ for(;;) { \ - __b=(s)[--(i)]; \ + __b=(uint8_t)(s)[--(i)]; \ if(__b>=0xc0) { \ U8_MASK_LEAD_BYTE(__b, __count); \ (c)|=(UChar32)__b<<__shift; \ @@ -492,16 +548,16 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * * @param s const uint8_t * string * @param start starting string offset (usually 0) - * @param i string offset, start<=i + * @param i string offset, must be start<i * @param c output UChar32 variable, set to <0 in case of an error * @see U8_PREV_UNSAFE * @stable ICU 2.4 */ #define U8_PREV(s, start, i, c) { \ - (c)=(s)[--(i)]; \ + (c)=(uint8_t)(s)[--(i)]; \ if((c)>=0x80) { \ if((c)<=0xbf) { \ - (c)=utf8_prevCharSafeBody(s, start, &(i), c, -1); \ + (c)=utf8_prevCharSafeBody((const uint8_t *)s, start, &(i), c, -1); \ } else { \ (c)=U_SENTINEL; \ } \ @@ -531,7 +587,7 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * * @param s const uint8_t * string * @param start starting string offset (usually 0) - * @param i string offset, start<=i + * @param i string offset, must be start<i * @see U8_BACK_1_UNSAFE * @stable ICU 2.4 */ @@ -571,7 +627,7 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * * @param s const uint8_t * string * @param start index of the start of the string - * @param i string offset, i<length + * @param i string offset, must be start<i * @param n number of code points to skip * @see U8_BACK_N_UNSAFE * @stable ICU 2.4 @@ -612,7 +668,7 @@ utf8_back1SafeBody(const uint8_t *s, int32_t start, int32_t i); * * @param s const uint8_t * string * @param start starting string offset (usually 0) - * @param i string offset, start<=i<=length + * @param i string offset, must be start<=i<=length * @param length string length * @see U8_SET_CP_LIMIT_UNSAFE * @stable ICU 2.4 diff --git a/Source/WTF/icu/unicode/utypes.h b/Source/WTF/icu/unicode/utypes.h index e20cd7933..00bf14ce8 100644 --- a/Source/WTF/icu/unicode/utypes.h +++ b/Source/WTF/icu/unicode/utypes.h @@ -1,6 +1,6 @@ /* ********************************************************************** -* Copyright (C) 1996-2004, International Business Machines +* Copyright (C) 1996-2010, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************** * @@ -38,6 +38,43 @@ #include "unicode/uversion.h" #include "unicode/uconfig.h" +/*! + * \file + * \brief Basic definitions for ICU, for both C and C++ APIs + * + * This file defines basic types, constants, and enumerations directly or + * indirectly by including other header files, especially utf.h for the + * basic character and string definitions and umachine.h for consistent + * integer and other types. + */ + + +/** + * \def U_SHOW_CPLUSPLUS_API + * @internal + */ +#ifdef XP_CPLUSPLUS +# ifndef U_SHOW_CPLUSPLUS_API +# define U_SHOW_CPLUSPLUS_API 1 +# endif +#else +# undef U_SHOW_CPLUSPLUS_API +# define U_SHOW_CPLUSPLUS_API 0 +#endif + +/** @{ API visibility control */ + +/** + * \def U_HIDE_DRAFT_API + * Define this to 1 to request that draft API be "hidden" + */ +#if !U_DEFAULT_SHOW_DRAFT && !defined(U_SHOW_DRAFT_API) +#define U_HIDE_DRAFT_API 1 +#endif +#if !U_DEFAULT_SHOW_DRAFT && !defined(U_SHOW_INTERNAL_API) +#define U_HIDE_INTERNAL_API 1 +#endif + #ifdef U_HIDE_DRAFT_API #include "unicode/udraft.h" #endif @@ -50,16 +87,16 @@ #include "unicode/uobslete.h" #endif +#ifdef U_HIDE_INTERNAL_API +#include "unicode/uintrnal.h" +#endif + +#ifdef U_HIDE_SYSTEM_API +#include "unicode/usystem.h" +#endif + +/** @} */ -/*! - * \file - * \brief Basic definitions for ICU, for both C and C++ APIs - * - * This file defines basic types, constants, and enumerations directly or - * indirectly by including other header files, especially utf.h for the - * basic character and string definitions and umachine.h for consistent - * integer and other types. - */ /*===========================================================================*/ /* char Character set family */ @@ -124,6 +161,30 @@ # define U_CHARSET_FAMILY 0 #endif +/** + * \def U_CHARSET_IS_UTF8 + * + * Hardcode the default charset to UTF-8. + * + * If this is set to 1, then + * - ICU will assume that all non-invariant char*, StringPiece, std::string etc. + * contain UTF-8 text, regardless of what the system API uses + * - some ICU code will use fast functions like u_strFromUTF8() + * rather than the more general and more heavy-weight conversion API (ucnv.h) + * - ucnv_getDefaultName() always returns "UTF-8" + * - ucnv_setDefaultName() is disabled and will not change the default charset + * - static builds of ICU are smaller + * - more functionality is available with the UCONFIG_NO_CONVERSION build-time + * configuration option (see unicode/uconfig.h) + * - the UCONFIG_NO_CONVERSION build option in uconfig.h is more usable + * + * @stable ICU 4.2 + * @see UCONFIG_NO_CONVERSION + */ +#ifndef U_CHARSET_IS_UTF8 +# define U_CHARSET_IS_UTF8 0 +#endif + /*===========================================================================*/ /* ICUDATA naming scheme */ /*===========================================================================*/ @@ -171,29 +232,36 @@ * ICU 1.8.x on EBCDIC, etc.. * @stable ICU 2.0 */ -#define U_ICUDATA_NAME "icudt" U_ICU_VERSION_SHORT U_ICUDATA_TYPE_LETTER - +#define U_ICUDATA_NAME "icudt" U_ICU_VERSION_SHORT U_ICUDATA_TYPE_LETTER /**< @internal */ +#define U_USRDATA_NAME "usrdt" U_ICU_VERSION_SHORT U_ICUDATA_TYPE_LETTER /**< @internal */ +#define U_USE_USRDATA 0 /**< @internal */ /** * U_ICU_ENTRY_POINT is the name of the DLL entry point to the ICU data library. * Defined as a literal, not a string. * Tricky Preprocessor use - ## operator replaces macro paramters with the literal string * from the corresponding macro invocation, _before_ other macro substitutions. - * Need a nested #defines to get the actual version numbers rather than + * Need a nested \#defines to get the actual version numbers rather than * the literal text U_ICU_VERSION_MAJOR_NUM into the name. * The net result will be something of the form - * #define U_ICU_ENTRY_POINT icudt19_dat + * \#define U_ICU_ENTRY_POINT icudt19_dat * @stable ICU 2.4 */ #define U_ICUDATA_ENTRY_POINT U_DEF2_ICUDATA_ENTRY_POINT(U_ICU_VERSION_MAJOR_NUM, U_ICU_VERSION_MINOR_NUM) + /** + * Do not use. * @internal */ #define U_DEF2_ICUDATA_ENTRY_POINT(major, minor) U_DEF_ICUDATA_ENTRY_POINT(major, minor) /** + * Do not use. * @internal */ +#ifndef U_DEF_ICUDATA_ENTRY_POINT +/* affected by symbol renaming. See platform.h */ #define U_DEF_ICUDATA_ENTRY_POINT(major, minor) icudt##major##minor##_dat +#endif /** * \def U_CALLCONV @@ -206,7 +274,7 @@ * you must use the U_CAPI and U_EXPORT2 qualifiers. * @stable ICU 2.0 */ -#if defined(OS390) && (__COMPILER_VER__ < 0x41020000) && defined(XP_CPLUSPLUS) +#if defined(OS390) && defined(XP_CPLUSPLUS) # define U_CALLCONV __cdecl #else # define U_CALLCONV U_EXPORT2 @@ -318,7 +386,7 @@ typedef void* UClassID; * \def U_DATA_API * Set to export library symbols from inside the stubdata library, * and to import them from outside. - * @draft ICU 3.0 + * @stable ICU 3.0 */ /** @@ -356,6 +424,13 @@ typedef void* UClassID; * @stable ICU 2.0 */ +/** + * \def U_TOOLUTIL_API + * Set to export library symbols from inside the toolutil library, + * and to import them from outside. + * @stable ICU 3.4 + */ + #if defined(U_COMBINED_IMPLEMENTATION) #define U_DATA_API U_EXPORT #define U_COMMON_API U_EXPORT @@ -363,6 +438,7 @@ typedef void* UClassID; #define U_LAYOUT_API U_EXPORT #define U_LAYOUTEX_API U_EXPORT #define U_IO_API U_EXPORT +#define U_TOOLUTIL_API U_EXPORT #elif defined(U_STATIC_IMPLEMENTATION) #define U_DATA_API #define U_COMMON_API @@ -370,6 +446,7 @@ typedef void* UClassID; #define U_LAYOUT_API #define U_LAYOUTEX_API #define U_IO_API +#define U_TOOLUTIL_API #elif defined(U_COMMON_IMPLEMENTATION) #define U_DATA_API U_IMPORT #define U_COMMON_API U_EXPORT @@ -377,6 +454,7 @@ typedef void* UClassID; #define U_LAYOUT_API U_IMPORT #define U_LAYOUTEX_API U_IMPORT #define U_IO_API U_IMPORT +#define U_TOOLUTIL_API U_IMPORT #elif defined(U_I18N_IMPLEMENTATION) #define U_DATA_API U_IMPORT #define U_COMMON_API U_IMPORT @@ -384,6 +462,7 @@ typedef void* UClassID; #define U_LAYOUT_API U_IMPORT #define U_LAYOUTEX_API U_IMPORT #define U_IO_API U_IMPORT +#define U_TOOLUTIL_API U_IMPORT #elif defined(U_LAYOUT_IMPLEMENTATION) #define U_DATA_API U_IMPORT #define U_COMMON_API U_IMPORT @@ -391,6 +470,7 @@ typedef void* UClassID; #define U_LAYOUT_API U_EXPORT #define U_LAYOUTEX_API U_IMPORT #define U_IO_API U_IMPORT +#define U_TOOLUTIL_API U_IMPORT #elif defined(U_LAYOUTEX_IMPLEMENTATION) #define U_DATA_API U_IMPORT #define U_COMMON_API U_IMPORT @@ -398,6 +478,7 @@ typedef void* UClassID; #define U_LAYOUT_API U_IMPORT #define U_LAYOUTEX_API U_EXPORT #define U_IO_API U_IMPORT +#define U_TOOLUTIL_API U_IMPORT #elif defined(U_IO_IMPLEMENTATION) #define U_DATA_API U_IMPORT #define U_COMMON_API U_IMPORT @@ -405,6 +486,15 @@ typedef void* UClassID; #define U_LAYOUT_API U_IMPORT #define U_LAYOUTEX_API U_IMPORT #define U_IO_API U_EXPORT +#define U_TOOLUTIL_API U_IMPORT +#elif defined(U_TOOLUTIL_IMPLEMENTATION) +#define U_DATA_API U_IMPORT +#define U_COMMON_API U_IMPORT +#define U_I18N_API U_IMPORT +#define U_LAYOUT_API U_IMPORT +#define U_LAYOUTEX_API U_IMPORT +#define U_IO_API U_IMPORT +#define U_TOOLUTIL_API U_EXPORT #else #define U_DATA_API U_IMPORT #define U_COMMON_API U_IMPORT @@ -412,6 +502,7 @@ typedef void* UClassID; #define U_LAYOUT_API U_IMPORT #define U_LAYOUTEX_API U_IMPORT #define U_IO_API U_IMPORT +#define U_TOOLUTIL_API U_IMPORT #endif /** @@ -449,10 +540,11 @@ typedef void* UClassID; * * Note: This is currently only done on Windows because * some Linux/Unix compilers have problems with defining global new/delete. - * On Windows, WIN32 is defined, and it is _MSC_Ver>=1200 for MSVC 6.0 and higher. + * On Windows, U_WINDOWS is defined, and it is _MSC_VER>=1200 for MSVC 6.0 and higher. */ -#if defined(XP_CPLUSPLUS) && defined(WIN32) && (_MSC_Ver>=1200) && (defined(U_COMMON_IMPLEMENTATION) || defined(U_I18N_IMPLEMENTATION) || defined(U_LAYOUT_IMPLEMENTATION) || defined(U_USTDIO_IMPLEMENTATION)) +#if defined(XP_CPLUSPLUS) && defined(WIN32) && U_DEBUG && U_OVERRIDE_CXX_ALLOCATION && (_MSC_VER>=1200) && !defined(U_STATIC_IMPLEMENTATION) && (defined(U_COMMON_IMPLEMENTATION) || defined(U_I18N_IMPLEMENTATION) || defined(U_IO_IMPLEMENTATION) || defined(U_LAYOUT_IMPLEMENTATION) || defined(U_LAYOUTEX_IMPLEMENTATION)) +#ifndef U_HIDE_INTERNAL_API /** * Global operator new, defined only inside ICU4C, must not be used. * Crashes intentionally. @@ -465,6 +557,10 @@ operator new(size_t /*size*/) { return q; } +#ifdef _Ret_bytecap_ +/* This is only needed to suppress a Visual C++ 2008 warning for operator new[]. */ +_Ret_bytecap_(_Size) +#endif /** * Global operator new[], defined only inside ICU4C, must not be used. * Crashes intentionally. @@ -499,6 +595,7 @@ operator delete[](void * /*p*/) { *q=5; /* break it */ } +#endif /* U_HIDE_INTERNAL_API */ #endif /*===========================================================================*/ @@ -542,6 +639,8 @@ typedef enum UErrorCode { U_AMBIGUOUS_ALIAS_WARNING = -122, /**< This converter alias can go to different converter implementations */ U_DIFFERENT_UCA_VERSION = -121, /**< ucol_open encountered a mismatch between UCA version and collator image version, so the collator was constructed from rules. No impact to further function */ + + U_PLUGIN_CHANGED_LEVEL_WARNING = -120, /**< A plugin caused a level change. May not be an error, but later plugins may not load. */ U_ERROR_WARNING_LIMIT, /**< This must always be the last warning value to indicate the limit for UErrorCode warnings (last warning code +1) */ @@ -559,7 +658,7 @@ typedef enum UErrorCode { U_PARSE_ERROR = 9, /**< Equivalent to Java ParseException */ U_INVALID_CHAR_FOUND = 10, /**< Character conversion: Unmappable input sequence. In other APIs: Invalid character. */ U_TRUNCATED_CHAR_FOUND = 11, /**< Character conversion: Incomplete input sequence. */ - U_ILLEGAL_CHAR_FOUND = 12, /**< Character conversion: Illegal input sequence/combination of input units.. */ + U_ILLEGAL_CHAR_FOUND = 12, /**< Character conversion: Illegal input sequence/combination of input units. */ U_INVALID_TABLE_FORMAT = 13, /**< Conversion table file found, but corrupted */ U_INVALID_TABLE_FILE = 14, /**< Conversion table file not found */ U_BUFFER_OVERFLOW_ERROR = 15, /**< A result would not fit in the supplied buffer */ @@ -578,6 +677,7 @@ typedef enum UErrorCode { U_INVALID_STATE_ERROR = 27, /**< Requested operation can not be completed with ICU in its current state */ U_COLLATOR_VERSION_MISMATCH = 28, /**< Collator version is not compatible with the base version */ U_USELESS_COLLATOR_ERROR = 29, /**< Collator is options only and no base is specified */ + U_NO_WRITE_PERMISSION = 30, /**< Attempt to modify read-only or constant data. */ U_STANDARD_ERROR_LIMIT, /**< This must always be the last value to indicate the limit for standard errors */ /* @@ -638,13 +738,18 @@ typedef enum UErrorCode { U_UNMATCHED_BRACES, /**< Braces do not match in message pattern */ U_UNSUPPORTED_PROPERTY, /**< UNUSED as of ICU 2.4 */ U_UNSUPPORTED_ATTRIBUTE, /**< UNUSED as of ICU 2.4 */ + U_ARGUMENT_TYPE_MISMATCH, /**< Argument name and argument index mismatch in MessageFormat functions */ + U_DUPLICATE_KEYWORD, /**< Duplicate keyword in PluralFormat */ + U_UNDEFINED_KEYWORD, /**< Undefined Plural keyword */ + U_DEFAULT_KEYWORD_MISSING, /**< Missing DEFAULT rule in plural rules */ + U_DECIMAL_NUMBER_SYNTAX_ERROR, /**< Decimal number syntax error */ U_FMT_PARSE_ERROR_LIMIT, /**< The limit for format library errors */ /* * the error code range 0x10200 0x102ff are reserved for Break Iterator related error */ + U_BRK_INTERNAL_ERROR=0x10200, /**< An internal error (bug) was detected. */ U_BRK_ERROR_START=0x10200, /**< Start of codes indicating Break Iterator failures */ - U_BRK_INTERNAL_ERROR, /**< An internal error (bug) was detected. */ U_BRK_HEX_DIGITS_EXPECTED, /**< Hex digits expected as part of a escaped char in a rule. */ U_BRK_SEMICOLON_EXPECTED, /**< Missing ';' at the end of a RBBI rule. */ U_BRK_RULE_SYNTAX, /**< Syntax error in RBBI rule. */ @@ -663,8 +768,8 @@ typedef enum UErrorCode { /* * The error codes in the range 0x10300-0x103ff are reserved for regular expression related errrs */ + U_REGEX_INTERNAL_ERROR=0x10300, /**< An internal error (bug) was detected. */ U_REGEX_ERROR_START=0x10300, /**< Start of codes indicating Regexp failures */ - U_REGEX_INTERNAL_ERROR, /**< An internal error (bug) was detected. */ U_REGEX_RULE_SYNTAX, /**< Syntax error in regexp pattern. */ U_REGEX_INVALID_STATE, /**< RegexMatcher in invalid state for requested operation */ U_REGEX_BAD_ESCAPE_SEQUENCE, /**< Unrecognized backslash escape sequence in pattern */ @@ -678,19 +783,27 @@ typedef enum UErrorCode { U_REGEX_INVALID_FLAG, /**< Invalid value for match mode flags. */ U_REGEX_LOOK_BEHIND_LIMIT, /**< Look-Behind pattern matches must have a bounded maximum length. */ U_REGEX_SET_CONTAINS_STRING, /**< Regexps cannot have UnicodeSets containing strings.*/ + U_REGEX_OCTAL_TOO_BIG, /**< Octal character constants must be <= 0377. */ + U_REGEX_MISSING_CLOSE_BRACKET, /**< Missing closing bracket on a bracket expression. */ + U_REGEX_INVALID_RANGE, /**< In a character range [x-y], x is greater than y. */ + U_REGEX_STACK_OVERFLOW, /**< Regular expression backtrack stack overflow. */ + U_REGEX_TIME_OUT, /**< Maximum allowed match time exceeded */ + U_REGEX_STOPPED_BY_CALLER, /**< Matching operation aborted by user callback fn. */ U_REGEX_ERROR_LIMIT, /**< This must always be the last value to indicate the limit for regexp errors */ /* * The error code in the range 0x10400-0x104ff are reserved for IDNA related error codes */ + U_IDNA_PROHIBITED_ERROR=0x10400, U_IDNA_ERROR_START=0x10400, - U_IDNA_PROHIBITED_ERROR, U_IDNA_UNASSIGNED_ERROR, U_IDNA_CHECK_BIDI_ERROR, U_IDNA_STD3_ASCII_RULES_ERROR, U_IDNA_ACE_PREFIX_ERROR, U_IDNA_VERIFICATION_ERROR, U_IDNA_LABEL_TOO_LONG_ERROR, + U_IDNA_ZERO_LENGTH_LABEL_ERROR, + U_IDNA_DOMAIN_NAME_TOO_LONG_ERROR, U_IDNA_ERROR_LIMIT, /* * Aliases for StringPrep @@ -698,9 +811,16 @@ typedef enum UErrorCode { U_STRINGPREP_PROHIBITED_ERROR = U_IDNA_PROHIBITED_ERROR, U_STRINGPREP_UNASSIGNED_ERROR = U_IDNA_UNASSIGNED_ERROR, U_STRINGPREP_CHECK_BIDI_ERROR = U_IDNA_CHECK_BIDI_ERROR, + + /* + * The error code in the range 0x10500-0x105ff are reserved for Plugin related error codes + */ + U_PLUGIN_ERROR_START=0x10500, /**< Start of codes indicating plugin failures */ + U_PLUGIN_TOO_HIGH=0x10500, /**< The plugin's level is too high to be loaded right now. */ + U_PLUGIN_DIDNT_SET_LEVEL, /**< The plugin didn't call uplug_setPlugLevel in response to a QUERY */ + U_PLUGIN_ERROR_LIMIT, /**< This must always be the last value to indicate the limit for plugin errors */ - - U_ERROR_LIMIT=U_IDNA_ERROR_LIMIT /**< This must always be the last value to indicate the limit for UErrorCode (last error code +1) */ + U_ERROR_LIMIT=U_PLUGIN_ERROR_LIMIT /**< This must always be the last value to indicate the limit for UErrorCode (last error code +1) */ } UErrorCode; /* Use the following to determine if an UErrorCode represents */ diff --git a/Source/WTF/icu/unicode/uvernum.h b/Source/WTF/icu/unicode/uvernum.h new file mode 100644 index 000000000..722161292 --- /dev/null +++ b/Source/WTF/icu/unicode/uvernum.h @@ -0,0 +1,138 @@ +/* +******************************************************************************* +* Copyright (C) 2000-2011, International Business Machines +* Corporation and others. All Rights Reserved. +******************************************************************************* +* +* file name: uvernum.h +* encoding: US-ASCII +* tab size: 8 (not used) +* indentation:4 +* +* Created by: Vladimir Weinstein +* Updated by: Steven R. Loomis +* +* Gets included by uversion.h and other files. +* +* IMPORTANT: When updating version, the following things need to be done: +* source/common/unicode/uvernum.h - this file: update major, minor, +* patchlevel, suffix, version, short version constants, namespace, +* renaming macro, and copyright +* +* The following files need to be updated as well, which can be done +* by running the UNIX makefile target 'update-windows-makefiles' in icu/source. +* +* +* source/common/common.vcproj - update 'Output file name' on the link tab so +* that it contains the new major/minor combination +* source/i18n/i18n.vcproj - same as for the common.vcproj +* source/layout/layout.vcproj - same as for the common.vcproj +* source/layoutex/layoutex.vcproj - same +* source/stubdata/stubdata.vcproj - same as for the common.vcproj +* source/io/io.vcproj - same as for the common.vcproj +* source/data/makedata.mak - change U_ICUDATA_NAME so that it contains +* the new major/minor combination and the Unicode version. +*/ + +#ifndef UVERNUM_H +#define UVERNUM_H + +/** The standard copyright notice that gets compiled into each library. + * This value will change in the subsequent releases of ICU + * @stable ICU 2.4 + */ +#define U_COPYRIGHT_STRING \ + " Copyright (C) 2011, International Business Machines Corporation and others. All Rights Reserved. " + +/** The current ICU major version as an integer. + * This value will change in the subsequent releases of ICU + * @stable ICU 2.4 + */ +#define U_ICU_VERSION_MAJOR_NUM 4 + +/** The current ICU minor version as an integer. + * This value will change in the subsequent releases of ICU + * @stable ICU 2.6 + */ +#define U_ICU_VERSION_MINOR_NUM 6 + +/** The current ICU patchlevel version as an integer. + * This value will change in the subsequent releases of ICU + * @stable ICU 2.4 + */ +#define U_ICU_VERSION_PATCHLEVEL_NUM 1 + +/** The current ICU build level version as an integer. + * This value is for use by ICU clients. It defaults to 0. + * @stable ICU 4.0 + */ +#ifndef U_ICU_VERSION_BUILDLEVEL_NUM +#define U_ICU_VERSION_BUILDLEVEL_NUM 0 +#endif + +/** Glued version suffix for renamers + * This value will change in the subsequent releases of ICU + * @stable ICU 2.6 + */ +#define U_ICU_VERSION_SUFFIX _46 + +/** Glued version suffix function for renamers + * This value will change in the subsequent releases of ICU. + * If a custom suffix (such as matching library suffixes) is desired, this can be modified. + * Note that if present, platform.h may contain an earlier definition of this macro. + * @stable ICU 4.2 + */ +#ifndef U_ICU_ENTRY_POINT_RENAME +#define U_ICU_ENTRY_POINT_RENAME(x) x ## _46 +#endif + +/** The current ICU library version as a dotted-decimal string. The patchlevel + * only appears in this string if it non-zero. + * This value will change in the subsequent releases of ICU + * @stable ICU 2.4 + */ +#define U_ICU_VERSION "4.6.1" + +/** The current ICU library major/minor version as a string without dots, for library name suffixes. + * This value will change in the subsequent releases of ICU + * @stable ICU 2.6 + */ +#define U_ICU_VERSION_SHORT "46" + +/** Data version in ICU4C. + * @internal ICU 4.4 Internal Use Only + **/ +#define U_ICU_DATA_VERSION "4.6" + +/*=========================================================================== + * ICU collation framework version information + * 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 + *=========================================================================== + */ + +/** + * Collation runtime version (sort key generator, strcoll). + * If the version is different, sort keys for the same string could be different. + * This value may change in subsequent releases of ICU. + * @stable ICU 2.4 + */ +#define UCOL_RUNTIME_VERSION 7 + +/** + * Collation builder code version. + * When this is different, the same tailoring might result + * in assigning different collation elements to code points. + * This value may change in subsequent releases of ICU. + * @stable ICU 2.4 + */ +#define UCOL_BUILDER_VERSION 8 + +/** + * This is the version of collation tailorings. + * This value may change in subsequent releases of ICU. + * @stable ICU 2.4 + */ +#define UCOL_TAILORINGS_VERSION 1 + +#endif diff --git a/Source/WTF/icu/unicode/uversion.h b/Source/WTF/icu/unicode/uversion.h index f9a7755b9..e54cd55a6 100644 --- a/Source/WTF/icu/unicode/uversion.h +++ b/Source/WTF/icu/unicode/uversion.h @@ -1,6 +1,6 @@ /* ******************************************************************************* -* Copyright (C) 2000-2004, International Business Machines +* Copyright (C) 2000-2010, International Business Machines * Corporation and others. All Rights Reserved. ******************************************************************************* * @@ -11,10 +11,13 @@ * * Created by: Vladimir Weinstein * -* Contains all the important version numbers for ICU. * Gets included by utypes.h and Windows .rc files */ +/** + * \file + * \brief C API: API for accessing ICU version numbers. + */ /*===========================================================================*/ /* Main ICU version information */ /*===========================================================================*/ @@ -22,72 +25,16 @@ #ifndef UVERSION_H #define UVERSION_H -/** IMPORTANT: When updating version, the following things need to be done: */ -/** source/common/unicode/uversion.h - this file: update major, minor, */ -/** patchlevel, suffix, version, short version constants, namespace, */ -/** and copyright */ -/** source/common/common.dsp - update 'Output file name' on the link tab so */ -/** that it contains the new major/minor combination */ -/** source/i18n/i18n.dsp - same as for the common.dsp */ -/** source/layout/layout.dsp - same as for the common.dsp */ -/** source/stubdata/stubdata.dsp - same as for the common.dsp */ -/** source/extra/ustdio/ustdio.dsp - same as for the common.dsp */ -/** source/data/makedata.mak - change U_ICUDATA_NAME so that it contains */ -/** the new major/minor combination */ -/** source/tools/genren/genren.pl - use this script according to the README */ -/** in that folder */ - #include "unicode/umachine.h" -/** The standard copyright notice that gets compiled into each library. - * This value will change in the subsequent releases of ICU - * @stable ICU 2.4 - */ -#define U_COPYRIGHT_STRING \ - " Copyright (C) 2004, International Business Machines Corporation and others. All Rights Reserved. " +/* Actual version info lives in uvernum.h */ +#include "unicode/uvernum.h" /** Maximum length of the copyright string. * @stable ICU 2.4 */ #define U_COPYRIGHT_STRING_LENGTH 128 -/** The current ICU major version as an integer. - * This value will change in the subsequent releases of ICU - * @stable ICU 2.4 - */ -#define U_ICU_VERSION_MAJOR_NUM 3 - -/** The current ICU minor version as an integer. - * This value will change in the subsequent releases of ICU - * @stable ICU 2.6 - */ -#define U_ICU_VERSION_MINOR_NUM 2 - -/** The current ICU patchlevel version as an integer. - * This value will change in the subsequent releases of ICU - * @stable ICU 2.4 - */ -#define U_ICU_VERSION_PATCHLEVEL_NUM 0 - -/** Glued version suffix for renamers - * This value will change in the subsequent releases of ICU - * @stable ICU 2.6 - */ -#define U_ICU_VERSION_SUFFIX _3_2 - -/** The current ICU library version as a dotted-decimal string. The patchlevel - * only appears in this string if it non-zero. - * This value will change in the subsequent releases of ICU - * @stable ICU 2.4 - */ -#define U_ICU_VERSION "3.2" - -/** The current ICU library major/minor version as a string without dots, for library name suffixes. - * This value will change in the subsequent releases of ICU - * @stable ICU 2.6 - */ -#define U_ICU_VERSION_SHORT "32" - /** An ICU version consists of up to 4 numbers from 0..255. * @stable ICU 2.4 */ @@ -104,23 +51,89 @@ #define U_MAX_VERSION_STRING_LENGTH 20 /** The binary form of a version on ICU APIs is an array of 4 uint8_t. + * To compare two versions, use memcmp(v1,v2,sizeof(UVersionInfo)). * @stable ICU 2.4 */ typedef uint8_t UVersionInfo[U_MAX_VERSION_LENGTH]; -#if U_HAVE_NAMESPACE && defined(XP_CPLUSPLUS) -#if U_DISABLE_RENAMING -#define U_ICU_NAMESPACE icu -namespace U_ICU_NAMESPACE { } +/*===========================================================================*/ +/* C++ namespace if supported. Versioned unless versioning is disabled. */ +/*===========================================================================*/ + +/** + * \def U_NAMESPACE_BEGIN + * This is used to begin a declaration of a public ICU C++ API. + * When not compiling for C++, it does nothing. + * When compiling for C++, it begins an extern "C++" linkage block (to protect + * against cases in which an external client includes ICU header files inside + * an extern "C" linkage block). + * If the C++ compiler supports namespaces, it also begins a namespace block. + * @stable ICU 2.4 + */ + +/** + * \def U_NAMESPACE_END + * This is used to end a declaration of a public ICU C++ API. + * When not compiling for C++, it does nothing. + * When compiling for C++, it ends the extern "C++" block begun by + * U_NAMESPACE_BEGIN. + * If the C++ compiler supports namespaces, it also ends the namespace block + * begun by U_NAMESPACE_BEGIN. + * @stable ICU 2.4 + */ + +/** + * \def U_NAMESPACE_USE + * This is used to specify that the rest of the code uses the + * public ICU C++ API namespace. + * If the compiler doesn't support namespaces, this does nothing. + * @stable ICU 2.4 + */ + +/** + * \def U_NAMESPACE_QUALIFIER + * This is used to qualify that a function or class is part of + * the public ICU C++ API namespace. + * If the compiler doesn't support namespaces, this does nothing. + * @stable ICU 2.4 + */ + +/* Define namespace symbols if the compiler supports it. */ +#ifdef XP_CPLUSPLUS +#if U_HAVE_NAMESPACE +# if U_DISABLE_RENAMING +# define U_ICU_NAMESPACE icu + namespace U_ICU_NAMESPACE { } +# else +# define U_ICU_NAMESPACE U_ICU_ENTRY_POINT_RENAME(icu) + namespace U_ICU_NAMESPACE { } + namespace icu = U_ICU_NAMESPACE; +# endif + +# define U_NAMESPACE_BEGIN extern "C++" { namespace U_ICU_NAMESPACE { +# define U_NAMESPACE_END } } +# define U_NAMESPACE_USE using namespace U_ICU_NAMESPACE; +# define U_NAMESPACE_QUALIFIER U_ICU_NAMESPACE:: + +# ifndef U_USING_ICU_NAMESPACE +# define U_USING_ICU_NAMESPACE 1 +# endif +# if U_USING_ICU_NAMESPACE + U_NAMESPACE_USE +# endif #else -#define U_ICU_NAMESPACE icu_3_2 -namespace U_ICU_NAMESPACE { } -namespace icu = U_ICU_NAMESPACE; +# define U_NAMESPACE_BEGIN extern "C++" { +# define U_NAMESPACE_END } +# define U_NAMESPACE_USE +# define U_NAMESPACE_QUALIFIER #endif -U_NAMESPACE_USE +#else +# define U_NAMESPACE_BEGIN +# define U_NAMESPACE_END +# define U_NAMESPACE_USE +# define U_NAMESPACE_QUALIFIER #endif - /*===========================================================================*/ /* General version helper functions. Definitions in putil.c */ /*===========================================================================*/ @@ -140,6 +153,21 @@ U_STABLE void U_EXPORT2 u_versionFromString(UVersionInfo versionArray, const char *versionString); /** + * Parse a Unicode string with dotted-decimal version information and + * fill in a UVersionInfo structure with the result. + * Definition of this function lives in putil.c + * + * @param versionArray The destination structure for the version information. + * @param versionString A Unicode string with dotted-decimal version + * information, with up to four non-negative number + * fields with values of up to 255 each. + * @stable ICU 4.2 + */ +U_STABLE void U_EXPORT2 +u_versionFromUString(UVersionInfo versionArray, const UChar *versionString); + + +/** * Write a string with dotted-decimal version information according * to the input UVersionInfo. * Definition of this function lives in putil.c @@ -164,53 +192,4 @@ u_versionToString(UVersionInfo versionArray, char *versionString); */ U_STABLE void U_EXPORT2 u_getVersion(UVersionInfo versionArray); - - -/*=========================================================================== - * ICU collation framework version information - * 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 - *=========================================================================== - */ - -/** Collation runtime version (sort key generator, strcoll). - * If the version is different, sortkeys for the same string could be different - * version 2 was in ICU 1.8.1. changed is: compression intervals, French secondary - * compression, generating quad level always when strength is quad or more - * version 4 - ICU 2.2 - tracking UCA changes, ignore completely ignorables - * in contractions, ignore primary ignorables after shifted - * version 5 - ICU 2.8 - changed implicit generation code - * This value may change in the subsequent releases of ICU - * @stable ICU 2.4 - */ -#define UCOL_RUNTIME_VERSION 5 - -/** Builder code version. When this is different, same tailoring might result - * in assigning different collation elements to code points - * version 2 was in ICU 1.8.1. added support for prefixes, tweaked canonical - * closure. However, the tailorings should probably get same CEs assigned - * version 5 - ICU 2.2 - fixed some bugs, renamed some indirect values. - * version 6 - ICU 2.8 - fixed bug in builder that allowed 0xFF in primary values - * Backward compatible with the old rules. - * This value may change in the subsequent releases of ICU - * @stable ICU 2.4 - */ -#define UCOL_BUILDER_VERSION 6 - -/** *** Removed *** Instead we use the data we read from FractionalUCA.txt - * This is the version of FractionalUCA.txt tailoring rules - * Version 1 was in ICU 1.8.1. Version two contains canonical closure for - * supplementary code points - * Version 4 in ICU 2.2, following UCA=3.1.1d6, UCD=3.2.0 - * This value may change in the subsequent releases of ICU - * @stable ICU 2.4 - */ -/*#define UCOL_FRACTIONAL_UCA_VERSION 4*/ - -/** This is the version of the tailorings - * This value may change in the subsequent releases of ICU - * @stable ICU 2.4 - */ -#define UCOL_TAILORINGS_VERSION 1 - #endif diff --git a/Source/WTF/wtf/Atomics.h b/Source/WTF/wtf/Atomics.h index b16f455d2..9f89df140 100644 --- a/Source/WTF/wtf/Atomics.h +++ b/Source/WTF/wtf/Atomics.h @@ -160,7 +160,7 @@ inline bool weakCompareAndSwap(unsigned* location, unsigned expected, unsigned n "bne.n 0f\n\t" "strex %1, %4, %0\n\t" "0:" - : "+m"(*location), "=&r"(result), "=&r"(tmp) + : "+Q"(*location), "=&r"(result), "=&r"(tmp) : "r"(expected), "r"(newValue) : "memory"); result = !result; diff --git a/Source/WTF/wtf/Forward.h b/Source/WTF/wtf/Forward.h index b81ab2580..5c2acfe7a 100644 --- a/Source/WTF/wtf/Forward.h +++ b/Source/WTF/wtf/Forward.h @@ -46,6 +46,8 @@ namespace WTF { class Int8Array; class Int16Array; class Int32Array; + class MemoryInstrumentation; + class MemoryObjectInfo; class String; template <typename T> class StringBuffer; class StringBuilder; @@ -78,6 +80,8 @@ using WTF::Float64Array; using WTF::Int8Array; using WTF::Int16Array; using WTF::Int32Array; +using WTF::MemoryInstrumentation; +using WTF::MemoryObjectInfo; using WTF::String; using WTF::StringBuffer; using WTF::StringBuilder; diff --git a/Source/WTF/wtf/MemoryInstrumentation.h b/Source/WTF/wtf/MemoryInstrumentation.h index ac67ffff6..04ca8d20e 100644 --- a/Source/WTF/wtf/MemoryInstrumentation.h +++ b/Source/WTF/wtf/MemoryInstrumentation.h @@ -35,7 +35,7 @@ #include <wtf/PassOwnPtr.h> #include <wtf/RefPtr.h> -namespace WebCore { +namespace WTF { class MemoryClassInfo; class MemoryObjectInfo; @@ -43,29 +43,18 @@ class MemoryInstrumentation; typedef const char* MemoryObjectType; -class GenericMemoryTypes { -public: - static MemoryObjectType Undefined; -}; - enum MemoryOwningType { byPointer, byReference }; -class MemoryInstrumentationTraits { -public: - template<typename T> static void addInstrumentedObject(MemoryInstrumentation*, const T* const&, MemoryObjectType, MemoryOwningType); - template<typename T> static void addObject(MemoryInstrumentation*, const T* const&, MemoryObjectType, MemoryOwningType); -}; - class MemoryInstrumentation { public: virtual ~MemoryInstrumentation() { } template <typename T> void addRootObject(const T& t) { - addInstrumentedObject(t, GenericMemoryTypes::Undefined); + addInstrumentedObject(t, 0); processDeferredInstrumentedPointers(); } @@ -85,7 +74,6 @@ private: virtual void processDeferredInstrumentedPointers() = 0; friend class MemoryClassInfo; - friend class MemoryInstrumentationTraits; template<typename T> class InstrumentedPointer : public InstrumentedPointerBase { public: @@ -121,11 +109,11 @@ private: struct OwningTraits { // Default byReference implementation. static void addInstrumentedObject(MemoryInstrumentation* instrumentation, const T& t, MemoryObjectType ownerObjectType) { - MemoryInstrumentationTraits::addInstrumentedObject<T>(instrumentation, &t, ownerObjectType, byReference); + instrumentation->addInstrumentedObjectImpl(&t, ownerObjectType, byReference); } static void addObject(MemoryInstrumentation* instrumentation, const T& t, MemoryObjectType ownerObjectType) { - MemoryInstrumentationTraits::addObject<T>(instrumentation, &t, ownerObjectType, byReference); + instrumentation->addObjectImpl(&t, ownerObjectType, byReference); } }; @@ -133,11 +121,11 @@ private: struct OwningTraits<T*> { // Custom byPointer implementation. static void addInstrumentedObject(MemoryInstrumentation* instrumentation, const T* const& t, MemoryObjectType ownerObjectType) { - MemoryInstrumentationTraits::addInstrumentedObject<T>(instrumentation, t, ownerObjectType, byPointer); + instrumentation->addInstrumentedObjectImpl(t, ownerObjectType, byPointer); } static void addObject(MemoryInstrumentation* instrumentation, const T* const& t, MemoryObjectType ownerObjectType) { - MemoryInstrumentationTraits::addObject<T>(instrumentation, t, ownerObjectType, byPointer); + instrumentation->addObjectImpl(t, ownerObjectType, byPointer); } }; @@ -150,18 +138,6 @@ private: template<typename T> void addObjectImpl(const RefPtr<T>* const&, MemoryObjectType, MemoryOwningType); }; -template<typename T> -void MemoryInstrumentationTraits::addInstrumentedObject(MemoryInstrumentation* instrumentation, const T* const& t, MemoryObjectType ownerObjectType, MemoryOwningType owningType) -{ - instrumentation->addInstrumentedObjectImpl(t, ownerObjectType, owningType); -} - -template<typename T> -void MemoryInstrumentationTraits::addObject(MemoryInstrumentation* instrumentation, const T* const& t, MemoryObjectType ownerObjectType, MemoryOwningType owningType) -{ - instrumentation->addObjectImpl(t, ownerObjectType, owningType); -} - class MemoryObjectInfo { public: MemoryObjectInfo(MemoryInstrumentation* memoryInstrumentation, MemoryObjectType ownerObjectType) @@ -184,7 +160,7 @@ private: { if (!m_objectSize) { m_objectSize = actualSize ? actualSize : sizeof(T); - if (objectType != GenericMemoryTypes::Undefined) + if (objectType) m_objectType = objectType; } } @@ -197,7 +173,7 @@ private: class MemoryClassInfo { public: template<typename T> - MemoryClassInfo(MemoryObjectInfo* memoryObjectInfo, const T*, MemoryObjectType objectType = GenericMemoryTypes::Undefined, size_t actualSize = 0) + MemoryClassInfo(MemoryObjectInfo* memoryObjectInfo, const T*, MemoryObjectType objectType = 0, size_t actualSize = 0) : m_memoryObjectInfo(memoryObjectInfo) , m_memoryInstrumentation(memoryObjectInfo->memoryInstrumentation()) { @@ -222,6 +198,8 @@ public: template<typename VectorType> void addVectorPtr(const VectorType* const vector) { m_memoryInstrumentation->addVector(*vector, m_objectType, false); } void addRawBuffer(const void* const& buffer, size_t size) { m_memoryInstrumentation->addRawBuffer(buffer, m_objectType, size); } + void addWeakPointer(void*) { } + private: MemoryObjectInfo* m_memoryObjectInfo; MemoryInstrumentation* m_memoryInstrumentation; @@ -359,6 +337,6 @@ void MemoryInstrumentation::InstrumentedPointer<T>::process(MemoryInstrumentatio memoryInstrumentation->countObjectSize(memoryObjectInfo.objectType(), memoryObjectInfo.objectSize()); } -} // namespace WebCore +} // namespace WTF #endif // !defined(MemoryInstrumentation_h) diff --git a/Source/WTF/wtf/Platform.h b/Source/WTF/wtf/Platform.h index e5cc9ccb8..0be4bb07d 100644 --- a/Source/WTF/wtf/Platform.h +++ b/Source/WTF/wtf/Platform.h @@ -522,7 +522,7 @@ #endif /* OS(WINCE) && !PLATFORM(QT) */ -#if OS(WINCE) +#if OS(WINCE) && !PLATFORM(QT) #define WTF_USE_WCHAR_UNICODE 1 #elif PLATFORM(GTK) /* The GTK+ Unicode backend is configurable */ diff --git a/Source/WTF/wtf/PlatformEfl.cmake b/Source/WTF/wtf/PlatformEfl.cmake index 05ad8478d..2d663fa8f 100644 --- a/Source/WTF/wtf/PlatformEfl.cmake +++ b/Source/WTF/wtf/PlatformEfl.cmake @@ -1,6 +1,7 @@ LIST(APPEND WTF_SOURCES efl/MainThreadEfl.cpp efl/OwnPtrEfl.cpp + efl/RefPtrEfl.cpp gobject/GOwnPtr.cpp gobject/GRefPtr.cpp @@ -33,5 +34,6 @@ LIST(APPEND WTF_INCLUDE_DIRECTORIES ${GLIB_INCLUDE_DIRS} ${ICU_INCLUDE_DIRS} ${JAVASCRIPTCORE_DIR}/wtf/gobject - ${JAVASCRIPTCORE_DIR}/wtf/unicode/ + ${JAVASCRIPTCORE_DIR}/wtf/unicode + ${JAVASCRIPTCORE_DIR}/wtf/efl ) diff --git a/Source/WTF/wtf/efl/OwnPtrEfl.cpp b/Source/WTF/wtf/efl/OwnPtrEfl.cpp index 6501a9608..c6ca5e220 100644 --- a/Source/WTF/wtf/efl/OwnPtrEfl.cpp +++ b/Source/WTF/wtf/efl/OwnPtrEfl.cpp @@ -40,11 +40,6 @@ void deleteOwnedPtr(Ecore_Evas* ptr) ecore_evas_free(ptr); } -void deleteOwnedPtr(Evas_Object* ptr) -{ - evas_object_del(ptr); -} - void deleteOwnedPtr(Ecore_Pipe* ptr) { if (ptr) diff --git a/Source/WTF/wtf/efl/RefPtrEfl.cpp b/Source/WTF/wtf/efl/RefPtrEfl.cpp new file mode 100644 index 000000000..f5335cc7c --- /dev/null +++ b/Source/WTF/wtf/efl/RefPtrEfl.cpp @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2011 Samsung Electronics + * Copyright (C) 2012 Intel Corporation. All rights reserved. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + +#include "config.h" +#include "RefPtrEfl.h" + +#include <Evas.h> + +namespace WTF { + +template<> void refIfNotNull(Evas_Object* ptr) +{ + if (LIKELY(!!ptr)) + evas_object_ref(ptr); +} + +template<> void derefIfNotNull(Evas_Object* ptr) +{ + // Refcounting in Evas_Object is different that normal. The object is created + // with an external ref count of 0, but with one internal count of 1 which can + // only be removed by calling _del. Calling _del with an external ref count > 0, + // postposes deletion until it reaches 0. + + if (LIKELY(!!ptr)) { + if (evas_object_ref_get(ptr) > 0) + evas_object_unref(ptr); + else + evas_object_del(ptr); + } +} + +} diff --git a/Source/WTF/wtf/efl/RefPtrEfl.h b/Source/WTF/wtf/efl/RefPtrEfl.h new file mode 100644 index 000000000..48152842d --- /dev/null +++ b/Source/WTF/wtf/efl/RefPtrEfl.h @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2011 Samsung Electronics + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public License + * along with this library; see the file COPYING.LIB. If not, write to + * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + * Boston, MA 02110-1301, USA. + */ + +#ifndef RefPtrEfl_h +#define RefPtrEfl_h + +#include <wtf/RefPtr.h> + +typedef struct _Evas_Object Evas_Object; + +namespace WTF { + +template<> void refIfNotNull(Evas_Object* ptr); +template<> void derefIfNotNull(Evas_Object* ptr); + +} + +#endif // RefPtrEfl_h diff --git a/Source/WTF/wtf/text/AtomicString.h b/Source/WTF/wtf/text/AtomicString.h index efd4e2e8c..01b84da65 100644 --- a/Source/WTF/wtf/text/AtomicString.h +++ b/Source/WTF/wtf/text/AtomicString.h @@ -86,8 +86,11 @@ public: const String& string() const { return m_string; }; AtomicStringImpl* impl() const { return static_cast<AtomicStringImpl *>(m_string.impl()); } - + + bool is8Bit() const { return m_string.is8Bit(); } const UChar* characters() const { return m_string.characters(); } + const LChar* characters8() const { return m_string.characters8(); } + const UChar* characters16() const { return m_string.characters16(); } unsigned length() const { return m_string.length(); } UChar operator[](unsigned int i) const { return m_string[i]; } @@ -154,6 +157,14 @@ public: #ifndef NDEBUG void show() const; #endif + + template<typename MemoryObjectInfo> + void reportMemoryUsage(MemoryObjectInfo* memoryObjectInfo) const + { + typename MemoryObjectInfo::ClassInfo info(memoryObjectInfo, this); + info.addInstrumentedMember(m_string); + } + private: // The explicit constructors with AtomicString::ConstructFromLiteral must be used for literals. AtomicString(ASCIILiteral); diff --git a/Source/WTF/wtf/text/CString.h b/Source/WTF/wtf/text/CString.h index a78c2041b..d442af782 100644 --- a/Source/WTF/wtf/text/CString.h +++ b/Source/WTF/wtf/text/CString.h @@ -39,6 +39,12 @@ public: const char* data() { return m_data; } size_t length() { return m_length; } + template<typename MemoryObjectInfo> + void reportMemoryUsage(MemoryObjectInfo* memoryObjectInfo) const + { + typename MemoryObjectInfo::ClassInfo info(memoryObjectInfo, this, 0, sizeof(CStringBuffer) + m_length); + } + private: friend class CString; @@ -75,6 +81,13 @@ public: CStringBuffer* buffer() const { return m_buffer.get(); } + template<typename MemoryObjectInfo> + void reportMemoryUsage(MemoryObjectInfo* memoryObjectInfo) const + { + typename MemoryObjectInfo::ClassInfo info(memoryObjectInfo, this); + info.addInstrumentedMember(m_buffer); + } + private: void copyBufferIfNeeded(); void init(const char*, size_t length); diff --git a/Source/WTF/wtf/text/StringImpl.h b/Source/WTF/wtf/text/StringImpl.h index cd7e10cc5..a18f694be 100644 --- a/Source/WTF/wtf/text/StringImpl.h +++ b/Source/WTF/wtf/text/StringImpl.h @@ -714,6 +714,28 @@ public: #ifdef STRING_STATS ALWAYS_INLINE static StringStats& stringStats() { return m_stringStats; } #endif + + template<typename MemoryObjectInfo> + void reportMemoryUsage(MemoryObjectInfo* memoryObjectInfo) const + { + size_t selfSize = sizeof(StringImpl); + + // Count size used by internal buffer but skip strings that were constructed from literals. + if ((m_hashAndFlags & BufferInternal) && !hasTerminatingNullCharacter()) + // Three cases are covered here: + // 1) a normal 8-bit string with internal storage (BufferInternal) + // 2) a normal 16-bit string with internal storage (BufferInternal) + // 3) empty unique string with length = 0 (BufferInternal) + selfSize += m_length * (m_hashAndFlags & s_hashFlag8BitBuffer ? sizeof(LChar) : sizeof(UChar)); + + typename MemoryObjectInfo::ClassInfo info(memoryObjectInfo, this, 0, selfSize); + + if (m_hashAndFlags & BufferSubstring) + info.addInstrumentedMember(m_substringBuffer); + else if (m_hashAndFlags & s_hashFlagHas16BitShadow) // Substring never has its own shadow. + info.addRawBuffer(m_copyData16, (m_length + (hasTerminatingNullCharacter() ? 1 : 0)) * sizeof(UChar)); + } + private: // This number must be at least 2 to avoid sharing empty, null as well as 1 character strings from SmallStrings. static const unsigned s_copyCharsInlineCutOff = 20; diff --git a/Source/WTF/wtf/text/WTFString.h b/Source/WTF/wtf/text/WTFString.h index 636db9cd9..b7bd96c17 100644 --- a/Source/WTF/wtf/text/WTFString.h +++ b/Source/WTF/wtf/text/WTFString.h @@ -455,6 +455,13 @@ public: return (*m_impl)[index]; } + template<typename MemoryObjectInfo> + void reportMemoryUsage(MemoryObjectInfo* memoryObjectInfo) const + { + typename MemoryObjectInfo::ClassInfo info(memoryObjectInfo, this); + info.addInstrumentedMember(m_impl); + } + private: RefPtr<StringImpl> m_impl; }; diff --git a/Source/WTF/wtf/unicode/CharacterNames.h b/Source/WTF/wtf/unicode/CharacterNames.h index 78b7bf7b9..c36dfd0ef 100644 --- a/Source/WTF/wtf/unicode/CharacterNames.h +++ b/Source/WTF/wtf/unicode/CharacterNames.h @@ -49,6 +49,7 @@ const UChar ethiopicWordspace = 0x1361; const UChar fisheye = 0x25C9; const UChar hebrewPunctuationGeresh = 0x05F3; const UChar hebrewPunctuationGershayim = 0x05F4; +const UChar HiraganaLetterSmallA = 0x3041; const UChar horizontalEllipsis = 0x2026; const UChar hyphen = 0x2010; const UChar hyphenMinus = 0x002D; @@ -104,6 +105,7 @@ using WTF::Unicode::ethiopicWordspace; using WTF::Unicode::fisheye; using WTF::Unicode::hebrewPunctuationGeresh; using WTF::Unicode::hebrewPunctuationGershayim; +using WTF::Unicode::HiraganaLetterSmallA; using WTF::Unicode::horizontalEllipsis; using WTF::Unicode::hyphen; using WTF::Unicode::hyphenMinus; diff --git a/Source/WTF/wtf/unicode/icu/CollatorICU.cpp b/Source/WTF/wtf/unicode/icu/CollatorICU.cpp index bef0f7ab1..f0cfb911d 100644 --- a/Source/WTF/wtf/unicode/icu/CollatorICU.cpp +++ b/Source/WTF/wtf/unicode/icu/CollatorICU.cpp @@ -32,6 +32,7 @@ #if USE(ICU_UNICODE) && !UCONFIG_NO_COLLATION #include <wtf/Assertions.h> +#include <wtf/StringExtras.h> #include <wtf/Threading.h> #include <unicode/ucol.h> #include <string.h> |