LocaleDisplayNames Class Reference

Returns display names of Locales and components of Locales. More...

#include <locdspnm.h>

Inheritance diagram for LocaleDisplayNames:
UMemory

Public Member Functions

virtual ~LocaleDisplayNames ()
 Destructor.
virtual const LocalegetLocale () const =0
 Returns the locale used to determine the display names.
virtual UDialectHandling getDialectHandling () const =0
 Returns the dialect handling used in the display names.
virtual UnicodeStringlocaleDisplayName (const Locale &locale, UnicodeString &result) const =0
 Returns the display name of the provided locale.
virtual UnicodeStringlocaleDisplayName (const char *localeId, UnicodeString &result) const =0
 Returns the display name of the provided locale id.
virtual UnicodeStringlanguageDisplayName (const char *lang, UnicodeString &result) const =0
 Returns the display name of the provided language code.
virtual UnicodeStringscriptDisplayName (const char *script, UnicodeString &result) const =0
 Returns the display name of the provided script code.
virtual UnicodeStringscriptDisplayName (UScriptCode scriptCode, UnicodeString &result) const =0
 Returns the display name of the provided script code.
virtual UnicodeStringregionDisplayName (const char *region, UnicodeString &result) const =0
 Returns the display name of the provided region code.
virtual UnicodeStringvariantDisplayName (const char *variant, UnicodeString &result) const =0
 Returns the display name of the provided variant.
virtual UnicodeStringkeyDisplayName (const char *key, UnicodeString &result) const =0
 Returns the display name of the provided locale key.
virtual UnicodeStringkeyValueDisplayName (const char *key, const char *value, UnicodeString &result) const =0
 Returns the display name of the provided value (used with the provided key).

Static Public Member Functions

static LocaleDisplayNamescreateInstance (const Locale &locale)
 Convenience overload of createInstance(const Locale& locale, UDialectHandling dialectHandling) that specifies STANDARD dialect handling.
static LocaleDisplayNamescreateInstance (const Locale &locale, UDialectHandling dialectHandling)
 Returns an instance of LocaleDisplayNames that returns names formatted for the provided locale, using the provided dialectHandling.

Detailed Description

Returns display names of Locales and components of Locales.

For more information on language, script, region, variant, key, and values, see Locale.

Draft:
This API may be changed in the future versions and was introduced in ICU 4.4

Definition at line 32 of file locdspnm.h.


Constructor & Destructor Documentation

LocaleDisplayNames::~LocaleDisplayNames (  )  [inline, virtual]

Destructor.

Draft:
This API may be changed in the future versions and was introduced in ICU 4.4

Definition at line 173 of file locdspnm.h.


Member Function Documentation

static LocaleDisplayNames* LocaleDisplayNames::createInstance ( const Locale locale,
UDialectHandling  dialectHandling 
) [static]

Returns an instance of LocaleDisplayNames that returns names formatted for the provided locale, using the provided dialectHandling.

Parameters:
locale the display locale
dialectHandling how to select names for locales
Returns:
a LocaleDisplayNames instance
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4
LocaleDisplayNames * LocaleDisplayNames::createInstance ( const Locale locale  )  [inline, static]

Convenience overload of createInstance(const Locale& locale, UDialectHandling dialectHandling) that specifies STANDARD dialect handling.

Parameters:
locale the display locale
Returns:
a LocaleDisplayNames instance
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4

Definition at line 176 of file locdspnm.h.

References ULDN_STANDARD_NAMES.

virtual UDialectHandling LocaleDisplayNames::getDialectHandling (  )  const [pure virtual]

Returns the dialect handling used in the display names.

Returns:
the dialect handling enum
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4
virtual const Locale& LocaleDisplayNames::getLocale (  )  const [pure virtual]

Returns the locale used to determine the display names.

This is not necessarily the same locale passed to getInstance.

Returns:
the display locale
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4
virtual UnicodeString& LocaleDisplayNames::keyDisplayName ( const char *  key,
UnicodeString result 
) const [pure virtual]

Returns the display name of the provided locale key.

Parameters:
key the locale key name
result receives the locale key's display name
Returns:
the display name of the provided locale key
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4
virtual UnicodeString& LocaleDisplayNames::keyValueDisplayName ( const char *  key,
const char *  value,
UnicodeString result 
) const [pure virtual]

Returns the display name of the provided value (used with the provided key).

Parameters:
key the locale key name
value the locale key's value
result receives the value's display name
Returns:
the display name of the provided value
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4
virtual UnicodeString& LocaleDisplayNames::languageDisplayName ( const char *  lang,
UnicodeString result 
) const [pure virtual]

Returns the display name of the provided language code.

Parameters:
lang the language code
result receives the language code's display name
Returns:
the display name of the provided language code
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4
virtual UnicodeString& LocaleDisplayNames::localeDisplayName ( const char *  localeId,
UnicodeString result 
) const [pure virtual]

Returns the display name of the provided locale id.

Parameters:
localeId the id of the locale whose display name to return
result receives the locale's display name
Returns:
the display name of the provided locale
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4
virtual UnicodeString& LocaleDisplayNames::localeDisplayName ( const Locale locale,
UnicodeString result 
) const [pure virtual]

Returns the display name of the provided locale.

Parameters:
locale the locale whose display name to return
result receives the locale's display name
Returns:
the display name of the provided locale
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4
virtual UnicodeString& LocaleDisplayNames::regionDisplayName ( const char *  region,
UnicodeString result 
) const [pure virtual]

Returns the display name of the provided region code.

Parameters:
region the region code
result receives the region code's display name
Returns:
the display name of the provided region code
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4
virtual UnicodeString& LocaleDisplayNames::scriptDisplayName ( UScriptCode  scriptCode,
UnicodeString result 
) const [pure virtual]

Returns the display name of the provided script code.

Parameters:
scriptCode the script code number
result receives the script code's display name
Returns:
the display name of the provided script code
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4
virtual UnicodeString& LocaleDisplayNames::scriptDisplayName ( const char *  script,
UnicodeString result 
) const [pure virtual]

Returns the display name of the provided script code.

Parameters:
script the script code
result receives the script code's display name
Returns:
the display name of the provided script code
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4
virtual UnicodeString& LocaleDisplayNames::variantDisplayName ( const char *  variant,
UnicodeString result 
) const [pure virtual]

Returns the display name of the provided variant.

Parameters:
variant the variant string
result receives the variant's display name
Returns:
the display name of the provided variant
Draft:
This API may be changed in the future versions and was introduced in ICU 4.4

The documentation for this class was generated from the following file:
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on Sat Jan 23 15:17:43 2010 for ICU 4.3.4 by  doxygen 1.6.1