public interface UpgradeToWebSocket extends UpgradeToWebSocket
Modifier and Type | Method and Description |
---|---|
akka.stream.Graph<akka.stream.FlowShape<Message,Message>,akka.NotUsed> |
createScalaFlow(akka.stream.Graph<akka.stream.SinkShape<Message>,?> inSink,
akka.stream.Graph<akka.stream.SourceShape<Message>,?> outSource)
Java API
|
java.lang.Iterable<java.lang.String> |
getRequestedProtocols()
Java API
|
HttpResponse |
handleMessages(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,java.lang.Object> handlerFlow,
scala.Option<java.lang.String> subprotocol)
The high-level interface to create a WebSocket server based on "messages".
|
HttpResponse |
handleMessagesWith(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,?> handlerFlow)
Java API
|
HttpResponse |
handleMessagesWith(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,?> handlerFlow,
java.lang.String subprotocol)
Java API
|
HttpResponse |
handleMessagesWith(akka.stream.Graph<akka.stream.SinkShape<Message>,?> inSink,
akka.stream.Graph<akka.stream.SourceShape<Message>,?> outSource)
Java API
|
HttpResponse |
handleMessagesWith(akka.stream.Graph<akka.stream.SinkShape<Message>,?> inSink,
akka.stream.Graph<akka.stream.SourceShape<Message>,?> outSource,
java.lang.String subprotocol)
Java API
|
HttpResponse |
handleMessagesWithSinkSource(akka.stream.Graph<akka.stream.SinkShape<Message>,java.lang.Object> inSink,
akka.stream.Graph<akka.stream.SourceShape<Message>,java.lang.Object> outSource,
scala.Option<java.lang.String> subprotocol)
The high-level interface to create a WebSocket server based on "messages".
|
scala.collection.immutable.Seq<java.lang.String> |
requestedProtocols()
A sequence of protocols the client accepts.
|
akka.stream.Graph<akka.stream.FlowShape<Message,Message>,akka.NotUsed> createScalaFlow(akka.stream.Graph<akka.stream.SinkShape<Message>,?> inSink, akka.stream.Graph<akka.stream.SourceShape<Message>,?> outSource)
inSink
- (undocumented)outSource
- (undocumented)java.lang.Iterable<java.lang.String> getRequestedProtocols()
getRequestedProtocols
in interface UpgradeToWebSocket
HttpResponse handleMessages(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,java.lang.Object> handlerFlow, scala.Option<java.lang.String> subprotocol)
Returns a response to return in a request handler that will signal the low-level HTTP implementation to upgrade the connection to WebSocket and use the supplied handler to handle incoming WebSocket messages.
Optionally, a subprotocol out of the ones requested by the client can be chosen.
handlerFlow
- (undocumented)subprotocol
- (undocumented)HttpResponse handleMessagesWith(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,?> handlerFlow)
handleMessagesWith
in interface UpgradeToWebSocket
handlerFlow
- (undocumented)HttpResponse handleMessagesWith(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,?> handlerFlow, java.lang.String subprotocol)
handleMessagesWith
in interface UpgradeToWebSocket
handlerFlow
- (undocumented)subprotocol
- (undocumented)HttpResponse handleMessagesWith(akka.stream.Graph<akka.stream.SinkShape<Message>,?> inSink, akka.stream.Graph<akka.stream.SourceShape<Message>,?> outSource)
handleMessagesWith
in interface UpgradeToWebSocket
inSink
- (undocumented)outSource
- (undocumented)HttpResponse handleMessagesWith(akka.stream.Graph<akka.stream.SinkShape<Message>,?> inSink, akka.stream.Graph<akka.stream.SourceShape<Message>,?> outSource, java.lang.String subprotocol)
handleMessagesWith
in interface UpgradeToWebSocket
inSink
- (undocumented)outSource
- (undocumented)subprotocol
- (undocumented)HttpResponse handleMessagesWithSinkSource(akka.stream.Graph<akka.stream.SinkShape<Message>,java.lang.Object> inSink, akka.stream.Graph<akka.stream.SourceShape<Message>,java.lang.Object> outSource, scala.Option<java.lang.String> subprotocol)
Returns a response to return in a request handler that will signal the low-level HTTP implementation to upgrade the connection to WebSocket and use the supplied inSink to consume messages received from the client and the supplied outSource to produce message to sent to the client.
Optionally, a subprotocol out of the ones requested by the client can be chosen.
inSink
- (undocumented)outSource
- (undocumented)subprotocol
- (undocumented)scala.collection.immutable.Seq<java.lang.String> requestedProtocols()
See http://tools.ietf.org/html/rfc6455#section-1.9