You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by Oliver Lietz <ap...@oliverlietz.de> on 2015/06/10 18:53:44 UTC
i18n: RequestLocaleResolver#resolveLocale(HttpServletRequest request):List
hi all,
is the type of parameter request in resolveLocale(HttpServletRequest request)
a bug? Shouldn't that be SlingHttpServletRequest like it is in LocaleResolver
and described in javadoc instead?
Regards,
O.
https://svn.apache.org/repos/asf/sling/trunk/bundles/extensions/i18n/src/main/java/org/apache/sling/i18n/RequestLocaleResolver.java
Re: i18n: RequestLocaleResolver#resolveLocale(HttpServletRequest request):List
Posted by Oliver Lietz <ap...@oliverlietz.de>.
On Wednesday 10 June 2015 18:17:41 Alexander Klimetschek wrote:
> On 10.06.2015, at 09:53, Oliver Lietz <ap...@oliverlietz.de> wrote:
> > is the type of parameter request in resolveLocale(HttpServletRequest
> > request) a bug? Shouldn't that be SlingHttpServletRequest like it is in
> > LocaleResolver and described in javadoc instead?
>
> No, this might be called in the filter chain before sling request/response
> objects are available:
>
> https://github.com/apache/sling/blob/trunk/bundles/extensions/i18n/src/main/
> java/org/apache/sling/i18n/impl/I18NFilter.java#L114-L126
I see! Thanks, Alex. So we have to fix the javadoc.
O.
> Cheers,
> Alex
Re: i18n: RequestLocaleResolver#resolveLocale(HttpServletRequest
request):List
Posted by Alexander Klimetschek <ak...@adobe.com>.
On 10.06.2015, at 09:53, Oliver Lietz <ap...@oliverlietz.de> wrote:
> is the type of parameter request in resolveLocale(HttpServletRequest request)
> a bug? Shouldn't that be SlingHttpServletRequest like it is in LocaleResolver
> and described in javadoc instead?
No, this might be called in the filter chain before sling request/response objects are available:
https://github.com/apache/sling/blob/trunk/bundles/extensions/i18n/src/main/java/org/apache/sling/i18n/impl/I18NFilter.java#L114-L126
Cheers,
Alex