| java.lang.Object | |
| ↳ | org.springframework.web.servlet.i18n.AcceptHeaderLocaleResolver |
Implementation of LocaleResolver that simply uses the primary locale specified in the "accept-language" header of the HTTP request (that is, the locale sent by the client browser, normally that of the client's OS).
Note: Does not support setLocale, since the accept header
can only be changed through changing the client's locale settings.
| Public Constructors | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Resolve the current locale via the given request.
| |||||||||||
Set the current locale to the given one.
| |||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
From interface
org.springframework.web.servlet.LocaleResolver
| |||||||||||
Resolve the current locale via the given request. Should return a default locale as fallback in any case.
| request | the request to resolve the locale for |
|---|
null)
Set the current locale to the given one.
| request | the request to be used for locale modification |
|---|---|
| response | the response to be used for locale modification |
| locale | the new locale, or null to clear the locale |