| Modifier and Type | Field and Description |
|---|---|
| private static final Logger |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public OutputStream | getSendStream()
Implements jakarta. Opens an output stream on which a binary message may be sent. |
| public Writer | getSendWriter()
Implements jakarta. Opens a character stream on which a text message may be sent. |
| public void | sendBinary(ByteBuffer
the message to be sent. data)Implements jakarta. Send a binary message, returning when all of the message has been transmitted. |
| public void | sendBinary(ByteBuffer
the part of the message being sent. partialByte, boolean Whether the partial message being sent is the last part of the message. isLast)Implements jakarta. Send a binary message in parts, blocking until all of the message has been transmitted. |
| public void | sendObject(Object
the object to be sent. data)Implements jakarta. Sends a custom developer object, blocking until it has been transmitted. |
| public void | sendText(String
the message to be sent. text)Implements jakarta. Send a text message, blocking until all of the message has been transmitted. |
| public void | sendText(String
the parts of the message being sent. partialMessage, boolean Whether the partial message being sent is the last part of the message. isLast)Implements jakarta. Send a text message in parts, blocking until all of the message has been transmitted. |
| LOG | back to summary |
|---|---|
| private static final Logger LOG Hides org. | |
| JakartaWebSocketBasicRemote | back to summary |
|---|---|
| protected JakartaWebSocketBasicRemote(JakartaWebSocketSession session, CoreSession coreSession) | |
| getSendStream | back to summary |
|---|---|
| public OutputStream getSendStream() throws IOException Implements jakarta. Doc from jakarta. Opens an output stream on which a binary message may be sent. The developer must close the output stream in
order to indicate that the complete message has been placed into the output stream. If no calls are made to
one of the
| |
| getSendWriter | back to summary |
|---|---|
| public Writer getSendWriter() throws IOException Implements jakarta. Doc from jakarta. Opens a character stream on which a text message may be sent. The developer must close the writer in order to
indicate that the complete message has been placed into the character stream. If no calls are made to one of
the
| |
| sendBinary | back to summary |
|---|---|
| public void sendBinary(ByteBuffer data) throws IOException Implements jakarta. Doc from jakarta. Send a binary message, returning when all of the message has been transmitted. It is not safe for other threads to use the ByteBuffer until the sending of this message is complete. If the sending of the message completes successfully, the buffer's limit will be unchanged and the buffer's position will be equal to the limit. If the sending of the message does not complete successfully, the state of the buffer is undefined.
| |
| sendBinary | back to summary |
|---|---|
| public void sendBinary(ByteBuffer partialByte, boolean isLast) throws IOException Implements jakarta. Doc from jakarta. Send a binary message in parts, blocking until all of the message has been transmitted. The runtime reads the message in order. Non-final parts are sent with isLast set to false. The final piece must be sent with isLast set to true. It is not safe for other threads to use the ByteBuffer until the sending of this partial message is complete. If the sending of the partial message completes successfully, the buffer's limit will be unchanged and the buffer's position will be equal to the limit. If the sending of the partial message does not complete successfully, the state of the buffer is undefined.
| |
| sendObject | back to summary |
|---|---|
| public void sendObject(Object data) throws IOException, EncodeException Implements jakarta. Doc from jakarta. Sends a custom developer object, blocking until it has been transmitted. Containers will by default be able to encode java primitive types and their object equivalents, otherwise the developer must have provided an encoder for the object type in the endpoint configuration. A developer-provided encoder for a Java primitive type and its object equivalent overrides the container default encoder.
| |
| sendText | back to summary |
|---|---|
| public void sendText(String text) throws IOException Implements jakarta. Doc from jakarta. Send a text message, blocking until all of the message has been transmitted.
| |
| sendText | back to summary |
|---|---|
| public void sendText(String partialMessage, boolean isLast) throws IOException Implements jakarta. Doc from jakarta. Send a text message in parts, blocking until all of the message has been transmitted. The runtime reads the message in order. Non-final parts of the message are sent with isLast set to false. The final part must be sent with isLast set to true.
| |