Package com.avoka.fc.core.servlet
Class RequestContextFilter
- java.lang.Object
-
- com.avoka.fc.core.servlet.RequestContextFilter
-
-
Constructor Summary
Constructors Constructor Description RequestContextFilter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
destroy()
Called by the web container to indicate to a filter that it is being taken out of service.void
doFilter(ServletRequest servletRequest, ServletResponse servletResponse, FilterChain chain)
Binds the request context to the current thread before pass the filter to the filter chain.void
init(FilterConfig config)
Called by the web container to indicate to a filter that it is being placed into service.
-
-
-
Method Detail
-
init
public void init(FilterConfig config) throws ServletException
Called by the web container to indicate to a filter that it is being placed into service.- Specified by:
init
in interfaceFilter
- Parameters:
config
- the filter config- Throws:
ServletException
- if an error occurs during initiation.- See Also:
Filter.init(FilterConfig)
-
destroy
public void destroy()
Called by the web container to indicate to a filter that it is being taken out of service.- Specified by:
destroy
in interfaceFilter
- See Also:
Filter.destroy()
-
doFilter
public void doFilter(ServletRequest servletRequest, ServletResponse servletResponse, FilterChain chain) throws IOException, ServletException
Binds the request context to the current thread before pass the filter to the filter chain. Unbinds the request context at the end of each request.- Specified by:
doFilter
in interfaceFilter
- Parameters:
servletRequest
- the servlet requestservletResponse
- the servlet responsechain
- the filter chain- Throws:
IOException
- if an I/O error occursServletException
- if a servlet error occurs- See Also:
Filter.doFilter(ServletRequest, ServletResponse, FilterChain)
-
-