public interface LocaleResolver
Modifier and Type | Method and Description |
---|---|
Locale |
getLocale()
Resolve the Locale that should be used in internationalization and localization.
|
Locale |
getLocale(javax.servlet.http.HttpServletRequest request)
Given a request, resolve the
Locale that should be used in internationalization and localization. |
Locale |
getLocale(UserKey userKey)
Resolve the Locale that should be used in internationalization and localization.
|
Set<Locale> |
getSupportedLocales()
Returns a set of all the supported locales by the host application.
|
Locale getLocale(javax.servlet.http.HttpServletRequest request)
Locale
that should be used in internationalization and localization.
The locale should be determined by first checking the remote users preferences, then defaulting to the
application default locale if no preferred locale is set. May consult the given request for the preferred
browser locales (if supported by the product).request
- Request to checkLocale.getDefault()
if none found.Locale getLocale()
Locale.getDefault()
if none found.Locale getLocale(@Nullable UserKey userKey)
userKey
- the user. Can be null.Locale.getDefault()
if none found.Copyright © 2015 Atlassian. All rights reserved.