Interface LocaleManager

    • Field Detail

      • DEFAULT_LOCALE

        static final Locale DEFAULT_LOCALE
    • Method Detail

      • getLocale

        Locale getLocale​(com.atlassian.user.User user)
      • getLocaleInfo

        default @NonNull LocaleInfo getLocaleInfo​(@Nullable com.atlassian.user.User user)
        Parameters:
        user -
        Returns:
        a locale info with requested , selected and selection reason
        Since:
        6.2.0
      • invalidateLocaleInfoCache

        default void invalidateLocaleInfoCache​(@Nullable com.atlassian.user.User user)
        Since:
        6.2.0
      • setRequestLanguages

        void setRequestLanguages​(String languageString)
        Should set the language string from the request in a THREAD LOCAL cache.
        Parameters:
        languageString - comma- or semicolon-separated languages
      • setLanguage

        void setLanguage​(String language)
        Should set the language string as given by Locale (en-gb for example) in a THREAD LOCAL cache. Does nothing if the language string is invalid.
        Parameters:
        language - target language
      • getSiteDefaultLocale

        Locale getSiteDefaultLocale()
        Returns:
        The default site locale, or DEFAULT_LOCALE if none is set.
        Since:
        4.3