WsFrameServer (Apache Tomcat 11.0.21 API Documentation)
Description: declaration: package: org.apache.tomcat.websocket.server, class: WsFrameServer

# Class WsFrameServer

java.lang.Object
org.apache.tomcat.websocket.WsFrameBase
org.apache.tomcat.websocket.server.WsFrameServer

public class WsFrameServer extends WsFrameBase

- ## Nested Class Summary

  ### Nested classes/interfaces inherited from class WsFrameBase

  `WsFrameBase.ReadState`

- ## Field Summary

  ### Fields inherited from class WsFrameBase

  `inputBuffer, wsSession`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `WsFrameServer(SocketWrapperBase<?> socketWrapper, UpgradeInfo upgradeInfo, WsSession wsSession, Transformation transformation, ClassLoader applicationClassLoader)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `protected Log`
  `getLog()`
  `protected Transformation`
  `getTransformation()`
  `protected boolean`
  `isMasked()`
  `protected boolean`
  `isOpen()`
  `protected void`
  `resumeProcessing()`
  This method will be invoked when the read operation is resumed.
  `protected void`
  `sendMessageBinary(ByteBuffer msg, boolean last)`
  `protected void`
  `sendMessageText(boolean last)`
  `protected void`
  `updateStats(long payloadLength)`
  Hook for updating server side statistics.

  ### Methods inherited from class WsFrameBase

  `byteArrayToLong, changeReadState, changeReadState, getReadState, isSuspended, processInputBuffer, resume, suspend`

  ### Methods inherited from class Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### WsFrameServer

    public WsFrameServer(SocketWrapperBase<?> socketWrapper, UpgradeInfo upgradeInfo, WsSession wsSession, Transformation transformation, ClassLoader applicationClassLoader)

- ## Method Details

  - ### updateStats

    protected void updateStats(long payloadLength)
    Description copied from class: `WsFrameBase`
    Hook for updating server side statistics. Called on every frame received.
    Overrides:
      `updateStats` in class `WsFrameBase`
    Parameters:
      `payloadLength` - Size of message payload

  - ### isMasked

    protected boolean isMasked()
    Specified by:
      `isMasked` in class `WsFrameBase`

  - ### getTransformation

    protected Transformation getTransformation()
    Overrides:
      `getTransformation` in class `WsFrameBase`

  - ### isOpen

    protected boolean isOpen()
    Overrides:
      `isOpen` in class `WsFrameBase`

  - ### getLog

    protected Log getLog()
    Specified by:
      `getLog` in class `WsFrameBase`

  - ### sendMessageText

    protected void sendMessageText(boolean last) throws WsIOException
    Overrides:
      `sendMessageText` in class `WsFrameBase`
    Throws:
      `WsIOException`

  - ### sendMessageBinary

    protected void sendMessageBinary(ByteBuffer msg, boolean last) throws WsIOException
    Overrides:
      `sendMessageBinary` in class `WsFrameBase`
    Throws:
      `WsIOException`

  - ### resumeProcessing

    protected void resumeProcessing()
    Description copied from class: `WsFrameBase`
    This method will be invoked when the read operation is resumed. Since suspend of the read operation can be invoked at any time, when implementing this method one should consider that there might still be data remaining into the internal buffers that needs to be processed before reading again from the socket.
    Specified by:
      `resumeProcessing` in class `WsFrameBase`