Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.gisgraphy.webapp.filter
Class LocaleFilter

    java.lang.Object
      org.springframework.web.filter.GenericFilterBean
          org.springframework.web.filter.OncePerRequestFilter
              com.gisgraphy.webapp.filter.LocaleFilter

All Implemented Interfaces:
  javax.servlet.Filter, org.springframework.beans.factory.BeanNameAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean, org.springframework.web.context.ServletContextAware

    public class LocaleFilter

extends org.springframework.web.filter.OncePerRequestFilter

Filter to wrap request with a request including user preferred locale.

Field Summary

Fields inherited from class org.springframework.web.filter.OncePerRequestFilter
`ALREADY_FILTERED_SUFFIX`

Fields inherited from class org.springframework.web.filter.GenericFilterBean
`logger`

Constructor Summary
`LocaleFilter()`

Method Summary
`void` | `doFilterInternal(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, javax.servlet.FilterChain chain)` This method looks for a "locale" request parameter.

Methods inherited from class org.springframework.web.filter.OncePerRequestFilter
`doFilter, getAlreadyFilteredAttributeName, shouldNotFilter`

Methods inherited from class org.springframework.web.filter.GenericFilterBean
`addRequiredProperty, afterPropertiesSet, destroy, getFilterConfig, getFilterName, getServletContext, init, initBeanWrapper, initFilterBean, setBeanName, setServletContext`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### LocaleFilter

    public LocaleFilter()

Method Detail

### doFilterInternal

    public void doFilterInternal(javax.servlet.http.HttpServletRequest request,
                                 javax.servlet.http.HttpServletResponse response,
                                 javax.servlet.FilterChain chain)
                          throws java.io.IOException,
                                 javax.servlet.ServletException

  This method looks for a "locale" request parameter. If it finds one, it sets it as the preferred locale and also configures it to work with JSTL.

  Specified by:
    `doFilterInternal` in class `org.springframework.web.filter.OncePerRequestFilter`
  Parameters:
    `request` - the current request
    `response` - the current response
    `chain` - the chain
  Throws:
    `java.io.IOException` - when something goes wrong
    `javax.servlet.ServletException` - when a communication failure happens

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009. All Rights Reserved.