org.apache.wicket.protocol.ws.tomcat7
Class Tomcat7WebSocketFilter

java.lang.Object
  extended by org.apache.wicket.protocol.http.WicketFilter
      extended by org.apache.wicket.protocol.ws.AbstractUpgradeFilter
          extended by org.apache.wicket.protocol.ws.tomcat7.Tomcat7WebSocketFilter
All Implemented Interfaces:
javax.servlet.Filter

public class Tomcat7WebSocketFilter
extends AbstractUpgradeFilter

An upgrade filter that uses code borrowed from Tomcat's WebSocketServlet to decide whether to upgrade the request protocol to websocket or not.

Since:
6.0

Field Summary
 
Fields inherited from class org.apache.wicket.protocol.http.WicketFilter
APP_FACT_PARAM, FILTER_MAPPING_PARAM, IGNORE_PATHS_PARAM
 
Constructor Summary
Tomcat7WebSocketFilter()
           
 
Method Summary
protected  boolean acceptWebSocket(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp)
           
 void init(boolean isServlet, javax.servlet.FilterConfig filterConfig)
           
 
Methods inherited from class org.apache.wicket.protocol.ws.AbstractUpgradeFilter
getTokensFromHeader, processRequestCycle, selectSubProtocol, verifyOrigin
 
Methods inherited from class org.apache.wicket.protocol.http.WicketFilter
checkIfRedirectRequired, destroy, doFilter, getApplication, getApplicationFactory, getClassLoader, getFilterConfig, getFilterPath, getFilterPath, getFilterPathFromAnnotation, getFilterPathFromConfig, getFilterPathFromWebXml, getRelativePath, init, setFilterPath
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Tomcat7WebSocketFilter

public Tomcat7WebSocketFilter()
Method Detail

init

public void init(boolean isServlet,
                 javax.servlet.FilterConfig filterConfig)
          throws javax.servlet.ServletException
Overrides:
init in class org.apache.wicket.protocol.http.WicketFilter
Throws:
javax.servlet.ServletException

acceptWebSocket

protected boolean acceptWebSocket(javax.servlet.http.HttpServletRequest req,
                                  javax.servlet.http.HttpServletResponse resp)
                           throws javax.servlet.ServletException,
                                  IOException
Overrides:
acceptWebSocket in class AbstractUpgradeFilter
Throws:
javax.servlet.ServletException
IOException


Copyright © 2006–2016 Apache Software Foundation. All rights reserved.