WebSocketClient implementations.
| Modifier and Type | Field and Description |
|---|---|
| protected final Log | |
| private static final Set |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| protected void | |
| protected ListenableFuture | Returns: the established WebSocket session wrapped in aListenableFuture.the client-side handler for WebSocket messages webSocketHandler, HttpHeaders the HTTP headers to use for the handshake, with unwanted (forbidden)
headers filtered out (never headers, URI null)the target URI for the handshake (never uri, List<String> null)requested sub-protocols, or an empty list subProtocols, List<WebSocketExtension> requested WebSocket extensions, or an empty list extensions, Map<String, Object> the attributes to associate with the WebSocketSession, i.e. via
attributes)WebSocketSession#getAttributes(); currently always an empty map.
Deprecated
since 6.0. as of 6.0, in favor of
executeInternal(WebSocketHandler, HttpHeaders, URI, List, List, Map)
Perform the actual handshake to establish a connection to the server. |
| public CompletableFuture | execute(WebSocketHandler
the session handler webSocketHandler, String the url template uriTemplate, Object... the variables to expand the template uriVars)Implements org. Execute a handshake request to the given url and handle the resulting WebSocket session with the given handler. |
| public final CompletableFuture | execute(WebSocketHandler
the session handler webSocketHandler, WebSocketHttpHeaders headers, URI the url uri)Implements org. Execute a handshake request to the given url and handle the resulting WebSocket session with the given handler. |
| protected abstract CompletableFuture | Returns: the established WebSocket session wrapped in aCompletableFuture.the client-side handler for WebSocket messages webSocketHandler, HttpHeaders the HTTP headers to use for the handshake, with unwanted (forbidden)
headers filtered out (never headers, URI null)the target URI for the handshake (never uri, List<String> null)requested sub-protocols, or an empty list subProtocols, List<WebSocketExtension> requested WebSocket extensions, or an empty list extensions, Map<String, Object> the attributes to associate with the WebSocketSession, i.e. via
attributes)WebSocketSession#getAttributes(); currently always an empty mapPerform the actual handshake to establish a connection to the server. |
| logger | back to summary |
|---|---|
| protected final Log logger | |
| specialHeaders | back to summary |
|---|---|
| private static final Set<String> specialHeaders | |
| AbstractWebSocketClient | back to summary |
|---|---|
| public AbstractWebSocketClient() | |
| assertUri | back to summary |
|---|---|
| protected void assertUri(URI uri) | |
| doHandshakeInternal | back to summary |
|---|---|
| protected ListenableFuture Deprecated since 6.0. as of 6.0, in favor of Perform the actual handshake to establish a connection to the server.
| |
| execute | back to summary |
|---|---|
| public CompletableFuture Implements org. Doc from org. Execute a handshake request to the given url and handle the resulting WebSocket session with the given handler.
| |
| execute | back to summary |
|---|---|
| public final CompletableFuture Implements org. Doc from org. Execute a handshake request to the given url and handle the resulting WebSocket session with the given handler.
| |
| executeInternal | back to summary |
|---|---|
| protected abstract CompletableFuture Perform the actual handshake to establish a connection to the server.
| |