Class UserLocaleProvider
java.lang.Object
org.nuxeo.ecm.platform.web.common.locale.DefaultLocaleProvider
org.nuxeo.ecm.user.center.profile.localeProvider.UserLocaleProvider
- All Implemented Interfaces:
LocaleProvider
Provides user local stored in profile doc model
- Since:
- 5.6
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetLocale(CoreSession repo) getLocale(DocumentModel userProfileDoc) Gets the locale stored in the given user profile.getLocaleWithDefault(CoreSession session) getLocaleWithDefault(DocumentModel userProfileDoc) getTimeZone(CoreSession repo) Methods inherited from class org.nuxeo.ecm.platform.web.common.locale.DefaultLocaleProvider
getDefaultLocale, getDefaultTimezone, getLocaleWithDefault
-
Constructor Details
-
UserLocaleProvider
public UserLocaleProvider()
-
-
Method Details
-
getLocale
- Specified by:
getLocalein interfaceLocaleProvider- Overrides:
getLocalein classDefaultLocaleProvider- Returns:
- the Locale to be used or null to let the caller decides.
-
getLocale
Description copied from interface:LocaleProviderGets the locale stored in the given user profile.- Specified by:
getLocalein interfaceLocaleProvider- Overrides:
getLocalein classDefaultLocaleProvider- Returns:
- the Locale to be used or null to let the caller decide
-
getTimeZone
- Specified by:
getTimeZonein interfaceLocaleProvider- Overrides:
getTimeZonein classDefaultLocaleProvider- Returns:
- the Timezone to be used or null to let the caller decides.
-
getLocaleWithDefault
- Specified by:
getLocaleWithDefaultin interfaceLocaleProvider- Overrides:
getLocaleWithDefaultin classDefaultLocaleProvider- Returns:
- the Locale to be used or a default Locale
-
getLocaleWithDefault
- Specified by:
getLocaleWithDefaultin interfaceLocaleProvider- Overrides:
getLocaleWithDefaultin classDefaultLocaleProvider- Returns:
- the Locale stored in userProfile or a default Locale
-