- java.lang.Object
-
- org.omnifaces.filter.HttpFilter
-
- org.omnifaces.facesviews.FacesViewsForwardingFilter
-
- All Implemented Interfaces:
Filter
public class FacesViewsForwardingFilter extends HttpFilter
This filter makes sure extensionless requests arrive at the FacesServlet using an extension on which that Servlet is mapped, and that non-extensionless requests are handled according to a set preference.A filter like this is needed for extensionless requests, since the FacesServlet does not take into account any other mapping than prefix- and extension (suffix) mapping.
For a guide on FacesViews, please see the package summary.
- Author:
- Arjan Tijms
- See Also:
FacesViews,ExtensionAction,PathAction,UriExtensionRequestWrapper
-
-
Constructor Summary
Constructors Constructor Description FacesViewsForwardingFilter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddoFilter(HttpServletRequest request, HttpServletResponse response, HttpSession session, FilterChain chain)Filter the HTTP request.voidinit()Convenience init() method without FilterConfig parameter which will be called by init(FilterConfig).-
Methods inherited from class org.omnifaces.filter.HttpFilter
destroy, doFilter, getFilterConfig, getInitParameter, getServletContext, init
-
-
-
-
Method Detail
-
init
public void init() throws ServletExceptionDescription copied from class:HttpFilterConvenience init() method without FilterConfig parameter which will be called by init(FilterConfig).- Overrides:
initin classHttpFilter- Throws:
ServletException- When filter's initialization failed.
-
doFilter
public void doFilter(HttpServletRequest request, HttpServletResponse response, HttpSession session, FilterChain chain) throws ServletException, IOException
Description copied from class:HttpFilterFilter the HTTP request. The session argument isnullif there is no session.- Specified by:
doFilterin classHttpFilter- Parameters:
request- The HTTP request.response- The HTTP response.session- The HTTP session, if any, elsenull.chain- The filter chain to continue.- Throws:
ServletException- As wrapper exception when something fails in the request processing.IOException- Whenever something fails at I/O level.- See Also:
Filter.doFilter(ServletRequest, ServletResponse, FilterChain)
-
-