19 #ifndef __LISTFORMATTER_H__ 20 #define __LISTFORMATTER_H__ 24 #if U_SHOW_CPLUSPLUS_API 33 class FieldPositionHandler;
34 class FormattedListData;
41 struct ListFormatInternal;
48 struct ListFormatData :
public UMemory {
49 UnicodeString twoPattern;
50 UnicodeString startPattern;
51 UnicodeString middlePattern;
52 UnicodeString endPattern;
55 ListFormatData(
const UnicodeString& two,
const UnicodeString& start,
const UnicodeString& middle,
const UnicodeString& end,
57 twoPattern(two), startPattern(start), middlePattern(middle), endPattern(end), locale(loc) {}
68 #if !UCONFIG_NO_FORMATTING 130 FormattedListData *fData;
135 : fData(
nullptr), fErrorCode(errorCode) {}
138 #endif // !UCONFIG_NO_FORMATTING 188 #ifndef U_HIDE_DRAFT_API 203 #ifndef U_HIDE_INTERNAL_API 240 #if !UCONFIG_NO_FORMATTING 256 #endif // !UCONFIG_NO_FORMATTING 258 #ifndef U_HIDE_INTERNAL_API 276 ListFormatter(
const ListFormatInternal* listFormatterInternal);
280 static void initializeHash(
UErrorCode& errorCode);
281 static const ListFormatInternal* getListFormatInternal(
const Locale& locale,
const char *style,
UErrorCode& errorCode);
282 struct ListPatternsSink;
283 static ListFormatInternal* loadListFormatInternal(
const Locale& locale,
const char* style,
UErrorCode& errorCode);
287 int32_t index, int32_t &offset, FieldPositionHandler* handler,
UErrorCode& errorCode)
const;
291 ListFormatInternal* owned;
292 const ListFormatInternal* data;
299 #endif // __LISTFORMATTER_H__
#define U_OVERRIDE
Defined to the C++11 "override" keyword if available.
#define U_I18N_API
Set to export library symbols from inside the i18n library, and to import them from outside...
Represents a span of a string containing a given field.
UErrorCode
Standard ICU4C error code type, a substitute for exceptions.
C++ API: Locale ID object.
Basic definitions for ICU, for both C and C++ APIs.
UnicodeString is a string class that stores Unicode characters directly and provides similar function...
UObject is the common ICU "boilerplate" class.
UMemory is the common ICU base class.
Requested operation can not be completed with ICU in its current state.
int8_t UBool
The ICU boolean type.
Base class for objects to which Unicode characters and strings can be appended.
A Locale object represents a specific geographical, political, or cultural region.