Class AbstractListenerWebSocketSession.WebSocketSendProcessor

java.lang.Object
org.springframework.http.server.reactive.AbstractListenerWriteProcessor<WebSocketMessage>
org.springframework.web.reactive.socket.adapter.AbstractListenerWebSocketSession.WebSocketSendProcessor
All Implemented Interfaces:
Processor<WebSocketMessage,Void>, Publisher<Void>, Subscriber<WebSocketMessage>
Enclosing class:
AbstractListenerWebSocketSession<T>

protected final class AbstractListenerWebSocketSession.WebSocketSendProcessor extends org.springframework.http.server.reactive.AbstractListenerWriteProcessor<WebSocketMessage>
Processor to send web socket messages.
  • Field Summary

    Fields inherited from class org.springframework.http.server.reactive.AbstractListenerWriteProcessor

    rsWriteLogger
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
     
    protected boolean
     
    protected boolean
     
    void
    setReadyToSend(boolean ready)
    Subclasses can invoke this before sending a message (false) and after receiving the async send callback (true) effective translating async completion callback into simple flow control.
    protected boolean
     

    Methods inherited from class org.springframework.http.server.reactive.AbstractListenerWriteProcessor

    cancel, dataReceived, getLogPrefix, onComplete, onError, onNext, onSubscribe, onWritePossible, subscribe, writingComplete, writingFailed, writingPaused

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • write

      protected boolean write(WebSocketMessage message) throws IOException
      Specified by:
      write in class org.springframework.http.server.reactive.AbstractListenerWriteProcessor<WebSocketMessage>
      Throws:
      IOException
    • isDataEmpty

      protected boolean isDataEmpty(WebSocketMessage message)
      Specified by:
      isDataEmpty in class org.springframework.http.server.reactive.AbstractListenerWriteProcessor<WebSocketMessage>
    • isWritePossible

      protected boolean isWritePossible()
      Specified by:
      isWritePossible in class org.springframework.http.server.reactive.AbstractListenerWriteProcessor<WebSocketMessage>
    • setReadyToSend

      public void setReadyToSend(boolean ready)
      Subclasses can invoke this before sending a message (false) and after receiving the async send callback (true) effective translating async completion callback into simple flow control.
    • discardData

      protected void discardData(WebSocketMessage message)
      Specified by:
      discardData in class org.springframework.http.server.reactive.AbstractListenerWriteProcessor<WebSocketMessage>