Package org.apache.struts2.interceptor
Class I18nInterceptor.LocaleHandlerAdapter
java.lang.Object
org.apache.struts2.interceptor.I18nInterceptor.LocaleHandlerAdapter
- All Implemented Interfaces:
LocaleHandler,I18nInterceptor.LocaleHandler
- Direct Known Subclasses:
I18nInterceptor.AcceptLanguageLocaleHandler,I18nInterceptor.CookieLocaleHandler,I18nInterceptor.RequestLocaleHandler,I18nInterceptor.SessionLocaleHandler
- Enclosing class:
- I18nInterceptor
@Deprecated(forRemoval=true,
since="7.2.0")
protected abstract class I18nInterceptor.LocaleHandlerAdapter
extends Object
implements I18nInterceptor.LocaleHandler
Deprecated, for removal: This API element is subject to removal in a future version.
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedLocaleHandlerAdapter(LocaleHandler delegate) Deprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Modifier and TypeMethodDescriptionfind()Deprecated, for removal: This API element is subject to removal in a future version.Looks for an explicit locale override in request-scoped sources.read(ActionInvocation invocation) Deprecated, for removal: This API element is subject to removal in a future version.Reads locale from persistent/context sources whenLocaleHandler.find()did not resolve one.booleanDeprecated, for removal: This API element is subject to removal in a future version.Indicates if the locale should be persisted for the current request.store(ActionInvocation invocation, Locale locale) Deprecated, for removal: This API element is subject to removal in a future version.Persists the resolved locale when storage is enabled for the current handler.
-
Constructor Details
-
LocaleHandlerAdapter
Deprecated, for removal: This API element is subject to removal in a future version.
-
-
Method Details
-
find
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:LocaleHandlerLooks for an explicit locale override in request-scoped sources.- Specified by:
findin interfaceLocaleHandler- Returns:
- a locale override or
nullwhen no explicit override is present
-
read
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:LocaleHandlerReads locale from persistent/context sources whenLocaleHandler.find()did not resolve one.- Specified by:
readin interfaceLocaleHandler- Parameters:
invocation- current action invocation- Returns:
- resolved locale or
nullwhen no locale could be resolved
-
store
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:LocaleHandlerPersists the resolved locale when storage is enabled for the current handler.- Specified by:
storein interfaceLocaleHandler- Parameters:
invocation- current action invocationlocale- locale to store- Returns:
- the effective locale to apply to the invocation context
-
shouldStore
public boolean shouldStore()Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:LocaleHandlerIndicates if the locale should be persisted for the current request.- Specified by:
shouldStorein interfaceLocaleHandler- Returns:
truewhenLocaleHandler.store(ActionInvocation, Locale)should be invoked
-
org.apache.struts2.interceptor.i18n. Scheduled for removal in the next release cycle.