WsRemoteEndpointImplClient (Apache Tomcat 9.0.119 API Documentation)
Description: declaration: package: org.apache.tomcat.websocket, class: WsRemoteEndpointImplClient

# Class WsRemoteEndpointImplClient

java.lang.Object
org.apache.tomcat.websocket.WsRemoteEndpointImplBase
org.apache.tomcat.websocket.WsRemoteEndpointImplClient

All Implemented Interfaces:
  `RemoteEndpoint`

public class WsRemoteEndpointImplClient extends WsRemoteEndpointImplBase
Client-side implementation of a WebSocket remote endpoint.

- ## Nested Class Summary

  ### Nested classes/interfaces inherited from interface RemoteEndpoint

  `RemoteEndpoint.Async, RemoteEndpoint.Basic`

- ## Field Summary

  ### Fields inherited from class WsRemoteEndpointImplBase

  `messagePartInProgress, SENDRESULT_OK, sm`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `WsRemoteEndpointImplClient(AsyncChannelWrapper channel)`
  Constructs a client-side remote endpoint for the given channel.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `protected void`
  `doClose()`
  Performs the actual close operation on the underlying connection.
  `protected void`
  `doWrite(SendHandler handler, long blockingWriteTimeoutExpiry, ByteBuffer... data)`
  Writes data to the underlying connection.
  `protected ReentrantLock`
  `getLock()`
  Returns the lock used for thread-safe operations.
  `protected boolean`
  `isMasked()`
  Checks if frames should be masked.

  ### Methods inherited from class WsRemoteEndpointImplBase

  `acquireMessagePartInProgressSemaphore, close, flushBatch, getBatchingAllowed, getSendStream, getSendTimeout, getSendWriter, sendBytes, sendBytesByCompletion, sendBytesByFuture, sendObject, sendObjectByCompletion, sendObjectByFuture, sendPartialBytes, sendPartialString, sendPing, sendPong, sendString, sendStringByCompletion, sendStringByFuture, setBatchingAllowed, setEncoders, setSendTimeout, setSession, setTransformation, updateStats`

  ### Methods inherited from class Object

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

- ## Constructor Details

  - ### WsRemoteEndpointImplClient

    public WsRemoteEndpointImplClient(AsyncChannelWrapper channel)
    Constructs a client-side remote endpoint for the given channel.
    Parameters:
      `channel` - the async channel wrapper

- ## Method Details

  - ### isMasked

    protected boolean isMasked()
    Description copied from class: `WsRemoteEndpointImplBase`
    Checks if frames should be masked.
    Specified by:
      `isMasked` in class `WsRemoteEndpointImplBase`
    Returns:
      true if masking is required

  - ### doWrite

    protected void doWrite(SendHandler handler, long blockingWriteTimeoutExpiry, ByteBuffer... data)
    Description copied from class: `WsRemoteEndpointImplBase`
    Writes data to the underlying connection.
    Specified by:
      `doWrite` in class `WsRemoteEndpointImplBase`
    Parameters:
      `handler` - the send handler
      `blockingWriteTimeoutExpiry` - the timeout expiry time
      `data` - the data buffers to write

  - ### doClose

    protected void doClose()
    Description copied from class: `WsRemoteEndpointImplBase`
    Performs the actual close operation on the underlying connection.
    Specified by:
      `doClose` in class `WsRemoteEndpointImplBase`

  - ### getLock

    protected ReentrantLock getLock()
    Description copied from class: `WsRemoteEndpointImplBase`
    Returns the lock used for thread-safe operations.
    Specified by:
      `getLock` in class `WsRemoteEndpointImplBase`
    Returns:
      the reentrant lock