X-Git-Url: https://git.saurik.com/apple/icu.git/blobdiff_plain/374ca955a76ecab1204ca8bfa63ff9238d998416..c5116b9f5a666b9d59f443b3770acd6ef64dc6c3:/icuSources/common/ustrenum.h diff --git a/icuSources/common/ustrenum.h b/icuSources/common/ustrenum.h index f43e0ad2..a82162e2 100644 --- a/icuSources/common/ustrenum.h +++ b/icuSources/common/ustrenum.h @@ -1,6 +1,8 @@ +// © 2016 and later: Unicode, Inc. and others. +// License & terms of use: http://www.unicode.org/copyright.html /* ********************************************************************** -* Copyright (c) 2002-2004, International Business Machines +* Copyright (c) 2002-2014, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************** * Author: Alan Liu @@ -14,23 +16,6 @@ #include "unicode/uenum.h" #include "unicode/strenum.h" -/** - * 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). - */ -U_CAPI UEnumeration* U_EXPORT2 -uenum_openStringEnumeration(StringEnumeration* adopted, UErrorCode* ec); - -/** - * Given an array of const char* strings (invariant chars only), - * return a UEnumeration. Must have strings[i] != 0 for i in - * 0..count-1. - */ -U_CAPI UEnumeration* U_EXPORT2 -uenum_openCharStringsEnumeration(const char** strings, int32_t count, - UErrorCode* ec); - //---------------------------------------------------------------------- U_NAMESPACE_BEGIN @@ -64,6 +49,8 @@ public: */ virtual int32_t count(UErrorCode& status) const; + virtual const char* next(int32_t *resultLength, UErrorCode& status); + /** * Returns the next element a UnicodeString*. If there are no * more elements, returns NULL. @@ -88,6 +75,8 @@ public: */ static UClassID U_EXPORT2 getStaticClassID(); + static UStringEnumeration * U_EXPORT2 fromUEnumeration( + UEnumeration *enumToAdopt, UErrorCode &status); private: UEnumeration *uenum; // owned };