Interface BaseWebsocketListener

All Known Implementing Classes:
SessionWebsocketListener

public interface BaseWebsocketListener
  • Method Details

    • connectionOpened

      default void connectionOpened(BaseWebsocket websocket, SecurityContext securityContext)
      Called when a new client has connected to the web socket.
    • connectionClosed

      default void connectionClosed(BaseWebsocket websocket, SecurityContext securityContext)
      Called when a web socket connection has been closed by the server or client.
    • messageReceived

      default boolean messageReceived(BaseWebsocket websocket, SecurityContext securityContext)
      Called when a message has been received from the client.
      Returns:
      true if the message should be processed; false if the message should be ignored
    • messageSent

      default boolean messageSent(BaseWebsocket websocket, SecurityContext securityContext)
      Called before the server send a message to the client.
      Returns:
      true if the message should be sent; false if the message should be ignored