public class WebSocketTransport extends Object implements Transport, org.springframework.context.Lifecycle
Transport
that uses a
WebSocketClient
.Constructor and Description |
---|
WebSocketTransport(WebSocketClient webSocketClient) |
Modifier and Type | Method and Description |
---|---|
org.springframework.util.concurrent.ListenableFuture<WebSocketSession> |
connect(TransportRequest request,
WebSocketHandler handler)
Connect the transport.
|
List<TransportType> |
getTransportTypes()
Return the SockJS transport types that this transport can be used for.
|
WebSocketClient |
getWebSocketClient()
Return the configured
WebSocketClient . |
boolean |
isRunning() |
void |
start() |
void |
stop() |
String |
toString() |
public WebSocketTransport(WebSocketClient webSocketClient)
public WebSocketClient getWebSocketClient()
WebSocketClient
.public List<TransportType> getTransportTypes()
Transport
XhrTransport
could do both.getTransportTypes
in interface Transport
public org.springframework.util.concurrent.ListenableFuture<WebSocketSession> connect(TransportRequest request, WebSocketHandler handler)
Transport
public void start()
start
in interface org.springframework.context.Lifecycle
public void stop()
stop
in interface org.springframework.context.Lifecycle
public boolean isRunning()
isRunning
in interface org.springframework.context.Lifecycle