|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.atlassian.jira.config.DefaultLocaleManager
public class DefaultLocaleManager
| Field Summary |
|---|
| Fields inherited from interface com.atlassian.jira.config.LocaleManager |
|---|
DEFAULT_LOCALE |
| Constructor Summary | |
|---|---|
DefaultLocaleManager(JiraLocaleUtils jiraLocaleUtils,
I18nHelper.BeanFactory beanFactory)
|
|
| Method Summary | |
|---|---|
Set<Locale> |
getInstalledLocales()
Returns a set of locales supported by this JIRA instance. |
Map<String,String> |
getInstalledLocalesWithDefault(Locale defaultLocale,
I18nHelper i18nHelper)
Returns a mapping of localeString to its displayname. |
Locale |
getLocale(String locale)
Given a string, return the corresponding Locale. |
Locale |
getLocaleFor(ApplicationUser user)
Returns the locale for the given user. |
void |
validateUserLocale(com.atlassian.crowd.embedded.api.User loggedInUser,
String locale,
ErrorCollection errorCollection)
Given a user entered locale string this method ensures that it is in fact a locale that exists in this instance |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultLocaleManager(JiraLocaleUtils jiraLocaleUtils,
I18nHelper.BeanFactory beanFactory)
| Method Detail |
|---|
public Set<Locale> getInstalledLocales()
LocaleManager
getInstalledLocales in interface LocaleManager
public Map<String,String> getInstalledLocalesWithDefault(Locale defaultLocale,
I18nHelper i18nHelper)
LocaleManager
getInstalledLocalesWithDefault in interface LocaleManagerdefaultLocale - The locale to use as the defaulti18nHelper - Required to internationalize the 'Default'
public Locale getLocale(String locale)
LocaleManager
getLocale in interface LocaleManagerlocale - Locale in string form
Locale objectpublic Locale getLocaleFor(ApplicationUser user)
LocaleManager
getLocaleFor in interface LocaleManageruser - The user
public void validateUserLocale(com.atlassian.crowd.embedded.api.User loggedInUser,
String locale,
ErrorCollection errorCollection)
LocaleManager
validateUserLocale in interface LocaleManagerloggedInUser - The user performing the operationlocale - the locale String to validate (e.g. en_UK)errorCollection - Error collection to record errors in
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||