ICU 56.1  56.1
ulistformatter.h
Go to the documentation of this file.
1 /*
2 *****************************************************************************************
3 * Copyright (C) 2015, International Business Machines
4 * Corporation and others. All Rights Reserved.
5 *****************************************************************************************
6 */
7 
8 #ifndef ULISTFORMATTER_H
9 #define ULISTFORMATTER_H
10 
11 #include "unicode/utypes.h"
12 
13 #if !UCONFIG_NO_FORMATTING
14 #ifndef U_HIDE_DRAFT_API
15 
16 #include "unicode/localpointer.h"
17 
32 struct UListFormatter;
51 U_DRAFT UListFormatter* U_EXPORT2
52 ulistfmt_open(const char* locale,
53  UErrorCode* status);
54 
61 U_DRAFT void U_EXPORT2
63 
64 
65 #if U_SHOW_CPLUSPLUS_API
66 
68 
79 
81 
82 #endif
83 
118 U_DRAFT int32_t U_EXPORT2
119 ulistfmt_format(const UListFormatter* listfmt,
120  const UChar* const strings[],
121  const int32_t * stringLengths,
122  int32_t stringCount,
123  UChar* result,
124  int32_t resultCapacity,
125  UErrorCode* status);
126 
127 #endif /* U_HIDE_DRAFT_API */
128 #endif /* #if !UCONFIG_NO_FORMATTING */
129 
130 #endif
UListFormatter * ulistfmt_open(const char *locale, UErrorCode *status)
Open a new UListFormatter object using the rules for a given locale.
#define U_NAMESPACE_BEGIN
This is used to begin a declaration of a public ICU C++ API.
Definition: uversion.h:129
void ulistfmt_close(UListFormatter *listfmt)
Close a UListFormatter object.
#define U_DEFINE_LOCAL_OPEN_POINTER(LocalPointerClassName, Type, closeFunction)
"Smart pointer" definition macro, deletes objects via the closeFunction.
Definition: localpointer.h:535
C++ API: "Smart pointers" for use with and in ICU4C C++ code.
"Smart pointer" class, closes a UListFormatter via ulistfmt_close().
int32_t ulistfmt_format(const UListFormatter *listfmt, const UChar *const strings[], const int32_t *stringLengths, int32_t stringCount, UChar *result, int32_t resultCapacity, UErrorCode *status)
Formats a list of strings using the conventions established for the UListFormatter object...
uint16_t UChar
Define UChar to be UCHAR_TYPE, if that is #defined (for example, to char16_t), or wchar_t if that is ...
Definition: umachine.h:312
#define U_NAMESPACE_END
This is used to end a declaration of a public ICU C++ API.
Definition: uversion.h:130
UErrorCode
Error code to replace exception handling, so that the code is compatible with all C++ compilers...
Definition: utypes.h:476
Basic definitions for ICU, for both C and C++ APIs.
#define U_DRAFT
This is used to declare a function as a draft public ICU C API.
Definition: umachine.h:111
struct UListFormatter UListFormatter
C typedef for struct UListFormatter.