public class

JiraLocaleUtils

extends LocaleUtils
java.lang.Object
   ↳ com.atlassian.core.util.LocaleUtils
     ↳ com.atlassian.jira.web.util.JiraLocaleUtils

This class is deprecated.
Should use the LocaleManager interface or LocaleParser instead.

Summary

Constants
String DEFAULT_LOCALE_I18N_KEY
String DEFAULT_LOCALE_ID
[Expand]
Inherited Constants
From class com.atlassian.core.util.LocaleUtils
[Expand]
Inherited Fields
From class com.atlassian.core.util.LocaleUtils
Public Constructors
JiraLocaleUtils()
Public Methods
synchronized List<Locale> getInstalledLocales()
This method is deprecated. Use getInstalledLocales() ) instead. Since v4.2
Map<StringString> getInstalledLocalesWithDefault(Locale defaultLocale, I18nHelper helper)
static Locale parseLocale(String locale)
This method is deprecated. Use {@link com.atlassian.jira.util.LocaleParser#parseLocale) instead. Since v4.2
synchronized void resetInstalledLocales()
Protected Methods
List<Locale> calculateAvailableLocales(Locale userLocale)
[Expand]
Inherited Methods
From class com.atlassian.core.util.LocaleUtils
From class java.lang.Object

Constants

public static final String DEFAULT_LOCALE_I18N_KEY

Constant Value: "admin.common.phrases.default.locale"

public static final String DEFAULT_LOCALE_ID

Constant Value: "-1"

Public Constructors

public JiraLocaleUtils ()

Public Methods

public synchronized List<Locale> getInstalledLocales ()

This method is deprecated.
Use getInstalledLocales() ) instead. Since v4.2

Returns a lazily-instantiated, unmodifiable List containing the installed locales.

Returns
  • an unmodifiable List of Locale

public Map<StringString> getInstalledLocalesWithDefault (Locale defaultLocale, I18nHelper helper)

This method is deprecated.
Use getInstalledLocalesWithDefault(java.util.Locale, com.atlassian.jira.util.I18nHelper) ) instead. Since v4.2

Retrieve the installed locales for the UI. Add 'Default' so that the JVM default can be used.

The display name for each locale is written in that same locale to ensure that users are able to identify their own language.

Parameters
defaultLocale default locale
helper i18n helper
Returns
  • a map of locale (as String) to locale display name

public static Locale parseLocale (String locale)

This method is deprecated.
Use {@link com.atlassian.jira.util.LocaleParser#parseLocale) instead. Since v4.2

Creates a locale from the given string. Similar to LocaleUtils, but this one is static

Parameters
locale locale
Returns
  • new locale based on the parameter, or null if parameter not set

public synchronized void resetInstalledLocales ()

Protected Methods

protected List<Locale> calculateAvailableLocales (Locale userLocale)