Interface WsWsocServerContainer

  • All Superinterfaces:
    javax.websocket.server.ServerContainer, javax.websocket.WebSocketContainer

    public interface WsWsocServerContainer
    extends javax.websocket.server.ServerContainer
    This interface provides WebSphere specific extensions to WebSocket ServerContainer support. Example:
     
         ServerContainer container = (ServerContainer) httpServletRequest.getServletContext().getAttribute("javax.websocket.server.ServerContainer");
         if (container instanceof WsWsocServerContainer) {
             WsWsocServerContainer ws = (WsWsocServerContainer) container;
             ...
         }
     
     
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void doUpgrade​(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp, javax.websocket.server.ServerEndpointConfig sec, java.util.Map<java.lang.String,​java.lang.String> pathParams)
      Performs a WebSocket upgrade on provided HttpServletRequest and HttpServletResponse with the specified ServerEndpointConfig.
      • Methods inherited from interface javax.websocket.server.ServerContainer

        addEndpoint, addEndpoint
      • Methods inherited from interface javax.websocket.WebSocketContainer

        connectToServer, connectToServer, connectToServer, connectToServer, getDefaultAsyncSendTimeout, getDefaultMaxBinaryMessageBufferSize, getDefaultMaxSessionIdleTimeout, getDefaultMaxTextMessageBufferSize, getInstalledExtensions, setAsyncSendTimeout, setDefaultMaxBinaryMessageBufferSize, setDefaultMaxSessionIdleTimeout, setDefaultMaxTextMessageBufferSize
    • Method Detail

      • doUpgrade

        void doUpgrade​(javax.servlet.http.HttpServletRequest req,
                       javax.servlet.http.HttpServletResponse resp,
                       javax.websocket.server.ServerEndpointConfig sec,
                       java.util.Map<java.lang.String,​java.lang.String> pathParams)
                throws javax.servlet.ServletException,
                       java.io.IOException
        Performs a WebSocket upgrade on provided HttpServletRequest and HttpServletResponse with the specified ServerEndpointConfig. After a call to doUpgrade, the servlet response is committed and you will be unable to write additional data or change the response code.
        Parameters:
        req - -
        resp - -
        serverEndpointConfig - - server endpoint config object representing a WebSocket endpoint - either programmatic or annotated.
        pathParams - - additional parameters that will be made availble thorugh wsoc Session.getRequestParameterMap
        Throws:
        javax.servlet.ServletException
        java.io.IOException