Modifier and Type | Class and Description |
---|---|
class |
HostnameUnverifiedException
The certificate of the peer does not match the expected hostname.
|
class |
OpeningHandshakeException
An exception raised due to a violation against the WebSocket protocol.
|
Modifier and Type | Method and Description |
---|---|
void |
WebSocketAdapter.onConnectError(WebSocket websocket,
WebSocketException exception) |
void |
WebSocketListener.onConnectError(WebSocket websocket,
WebSocketException cause)
Called when
WebSocket.connectAsynchronously() failed. |
void |
WebSocketAdapter.onError(WebSocket websocket,
WebSocketException cause) |
void |
WebSocketListener.onError(WebSocket websocket,
WebSocketException cause)
Call when an error occurred.
|
void |
WebSocketAdapter.onFrameError(WebSocket websocket,
WebSocketException cause,
WebSocketFrame frame) |
void |
WebSocketListener.onFrameError(WebSocket websocket,
WebSocketException cause,
WebSocketFrame frame)
Called when a WebSocket frame failed to be read from the WebSocket.
|
void |
WebSocketAdapter.onMessageDecompressionError(WebSocket websocket,
WebSocketException cause,
byte[] compressed) |
void |
WebSocketListener.onMessageDecompressionError(WebSocket websocket,
WebSocketException cause,
byte[] compressed)
Called when a message failed to be decompressed.
|
void |
WebSocketAdapter.onMessageError(WebSocket websocket,
WebSocketException cause,
List<WebSocketFrame> frames) |
void |
WebSocketListener.onMessageError(WebSocket websocket,
WebSocketException cause,
List<WebSocketFrame> frames)
Called when it failed to concatenate payloads of multiple frames
to construct a message.
|
void |
WebSocketAdapter.onSendError(WebSocket websocket,
WebSocketException cause,
WebSocketFrame frame) |
void |
WebSocketListener.onSendError(WebSocket websocket,
WebSocketException cause,
WebSocketFrame frame)
Called when an error occurred when a frame was tried to be sent
to the server.
|
void |
WebSocketAdapter.onTextMessageError(WebSocket websocket,
WebSocketException cause,
byte[] data) |
void |
WebSocketListener.onTextMessageError(WebSocket websocket,
WebSocketException cause,
byte[] data)
Called when it failed to convert payload data into a string.
|
void |
WebSocketAdapter.onUnexpectedError(WebSocket websocket,
WebSocketException cause) |
void |
WebSocketListener.onUnexpectedError(WebSocket websocket,
WebSocketException cause)
Called when an uncaught throwable was detected in either the
reading thread (which reads frames from the server) or the
writing thread (which sends frames to the server).
|
Modifier and Type | Method and Description |
---|---|
WebSocket |
WebSocket.connect()
Connect to the server, send an opening handshake to the server,
receive the response and then start threads to communicate with
the server.
|
Socket |
WebSocket.getConnectedSocket()
Get the raw socket which this WebSocket uses internally.
|
Copyright © 2021. All rights reserved.