19 #include "unicode/udisplaycontext.h"
52 #if !UCONFIG_NO_FORMATTING
79 #if U_SHOW_CPLUSPLUS_API
136 int32_t maxResultSize,
156 int32_t maxResultSize,
174 int32_t maxResultSize,
192 int32_t maxResultSize,
210 int32_t maxResultSize,
228 int32_t maxResultSize,
246 int32_t maxResultSize,
266 int32_t maxResultSize,
269 #ifndef U_HIDE_INTERNAL_API
int32_t uldn_keyDisplayName(const ULocaleDisplayNames *ldn, const char *key, UChar *result, int32_t maxResultSize, UErrorCode *pErrorCode)
Returns the display name of the provided locale key.
UDialectHandling uldn_getDialectHandling(const ULocaleDisplayNames *ldn)
Returns the dialect handling used in the display names.
int32_t uldn_localeDisplayName(const ULocaleDisplayNames *ldn, const char *locale, UChar *result, int32_t maxResultSize, UErrorCode *pErrorCode)
Returns the display name of the provided locale.
UScriptCode
Constants for ISO 15924 script codes.
#define U_INTERNAL
This is used to declare a function as an internal ICU C API.
UDisplayContext uldn_getContext(const ULocaleDisplayNames *ldn, UDisplayContextType type, UErrorCode *pErrorCode)
Returns the UDisplayContext value for the specified UDisplayContextType.
C API: Unicode Script Information.
int32_t uldn_scriptDisplayName(const ULocaleDisplayNames *ldn, const char *script, UChar *result, int32_t maxResultSize, UErrorCode *pErrorCode)
Returns the display name of the provided script.
int32_t uldn_regionDisplayName(const ULocaleDisplayNames *ldn, const char *region, UChar *result, int32_t maxResultSize, UErrorCode *pErrorCode)
Returns the display name of the provided region code.
#define U_NAMESPACE_BEGIN
This is used to begin a declaration of a public ICU C++ API.
#define U_DEFINE_LOCAL_OPEN_POINTER(LocalPointerClassName, Type, closeFunction)
"Smart pointer" definition macro, deletes objects via the closeFunction.
ULocaleDisplayNames * uldn_openForContext(const char *locale, UDisplayContext *contexts, int32_t length, UErrorCode *pErrorCode)
Returns an instance of LocaleDisplayNames that returns names formatted for the provided locale...
C++ API: "Smart pointers" for use with and in ICU4C C++ code.
ULocaleDisplayNames * uldn_open(const char *locale, UDialectHandling dialectHandling, UErrorCode *pErrorCode)
Returns an instance of LocaleDisplayNames that returns names formatted for the provided locale...
int32_t uldn_variantDisplayName(const ULocaleDisplayNames *ldn, const char *variant, UChar *result, int32_t maxResultSize, UErrorCode *pErrorCode)
Returns the display name of the provided variant.
Use dialect names, when generating a locale name, e.g.
struct ULocaleDisplayNames ULocaleDisplayNames
C typedef for struct ULocaleDisplayNames.
Use standard names when generating a locale name, e.g.
UDialectHandling
Enum used in LocaleDisplayNames::createInstance.
int32_t uldn_scriptCodeDisplayName(const ULocaleDisplayNames *ldn, UScriptCode scriptCode, UChar *result, int32_t maxResultSize, UErrorCode *pErrorCode)
Returns the display name of the provided script code.
uint16_t UChar
Define UChar to be UCHAR_TYPE, if that is #defined (for example, to char16_t), or wchar_t if that is ...
void uldn_close(ULocaleDisplayNames *ldn)
Closes a ULocaleDisplayNames instance obtained from uldn_open().
int32_t uldn_languageDisplayName(const ULocaleDisplayNames *ldn, const char *lang, UChar *result, int32_t maxResultSize, UErrorCode *pErrorCode)
Returns the display name of the provided language code.
#define U_NAMESPACE_END
This is used to end a declaration of a public ICU C++ API.
UErrorCode
Error code to replace exception handling, so that the code is compatible with all C++ compilers...
const char * uldn_getLocale(const ULocaleDisplayNames *ldn)
Returns the locale used to determine the display names.
Basic definitions for ICU, for both C and C++ APIs.
int32_t uldn_keyValueDisplayName(const ULocaleDisplayNames *ldn, const char *key, const char *value, UChar *result, int32_t maxResultSize, UErrorCode *pErrorCode)
Returns the display name of the provided value (used with the provided key).
"Smart pointer" class, closes a ULocaleDisplayNames via uldn_close().
#define U_STABLE
This is used to declare a function as a stable public ICU C API.