Class WebSocketConfig.CustomSessionHandshakeInterceptor

  • All Implemented Interfaces:
    org.springframework.web.socket.server.HandshakeInterceptor
    Enclosing class:
    WebSocketConfig

    public class WebSocketConfig.CustomSessionHandshakeInterceptor
    extends org.springframework.web.socket.server.support.HttpSessionHandshakeInterceptor
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static String HTTP_SESSION_ATTR_NAME  
      • Fields inherited from class org.springframework.web.socket.server.support.HttpSessionHandshakeInterceptor

        HTTP_SESSION_ID_ATTR_NAME
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean beforeHandshake​(org.springframework.http.server.ServerHttpRequest request, org.springframework.http.server.ServerHttpResponse response, org.springframework.web.socket.WebSocketHandler wsHandler, Map<String,​Object> attributes)  
      • Methods inherited from class org.springframework.web.socket.server.support.HttpSessionHandshakeInterceptor

        afterHandshake, getAttributeNames, isCopyAllAttributes, isCopyHttpSessionId, isCreateSession, setCopyAllAttributes, setCopyHttpSessionId, setCreateSession
    • Constructor Detail

      • CustomSessionHandshakeInterceptor

        public CustomSessionHandshakeInterceptor()
    • Method Detail

      • beforeHandshake

        public boolean beforeHandshake​(org.springframework.http.server.ServerHttpRequest request,
                                       org.springframework.http.server.ServerHttpResponse response,
                                       org.springframework.web.socket.WebSocketHandler wsHandler,
                                       Map<String,​Object> attributes)
                                throws Exception
        Specified by:
        beforeHandshake in interface org.springframework.web.socket.server.HandshakeInterceptor
        Overrides:
        beforeHandshake in class org.springframework.web.socket.server.support.HttpSessionHandshakeInterceptor
        Throws:
        Exception