Package akka.http.scaladsl.model.ws
Interface UpgradeToWebSocket
-
- All Superinterfaces:
UpgradeToWebSocket,WebSocketUpgrade,WebSocketUpgrade
- All Known Implementing Classes:
UpgradeToWebSocketLowLevel
public interface UpgradeToWebSocket extends UpgradeToWebSocket, WebSocketUpgrade
Deprecated.This low-level API has been replaced by an attribute. Since 10.2.0.A custom header that will be added to an WebSocket upgrade HttpRequest that enables a request handler to upgrade this connection to a WebSocket connection and registers a WebSocket handler.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method 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)Deprecated.Java APIjava.lang.Iterable<java.lang.String>getRequestedProtocols()Deprecated.Java APIHttpResponsehandleMessages(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,java.lang.Object> handlerFlow, scala.Option<java.lang.String> subprotocol)Deprecated.The high-level interface to create a WebSocket server based on "messages".HttpResponsehandleMessagesWith(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,?> handlerFlow)Deprecated.Java APIHttpResponsehandleMessagesWith(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,?> handlerFlow, java.lang.String subprotocol)Deprecated.Java APIHttpResponsehandleMessagesWith(akka.stream.Graph<akka.stream.SinkShape<Message>,?> inSink, akka.stream.Graph<akka.stream.SourceShape<Message>,?> outSource)Deprecated.Java APIHttpResponsehandleMessagesWith(akka.stream.Graph<akka.stream.SinkShape<Message>,?> inSink, akka.stream.Graph<akka.stream.SourceShape<Message>,?> outSource, java.lang.String subprotocol)Deprecated.Java APIHttpResponsehandleMessagesWithSinkSource(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)Deprecated.The high-level interface to create a WebSocket server based on "messages".scala.collection.immutable.Seq<java.lang.String>requestedProtocols()Deprecated.A sequence of protocols the client accepts.
-
-
-
Method Detail
-
createScalaFlow
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)
Deprecated.Java API- Specified by:
createScalaFlowin interfaceWebSocketUpgrade- Parameters:
inSink- (undocumented)outSource- (undocumented)- Returns:
- (undocumented)
-
getRequestedProtocols
java.lang.Iterable<java.lang.String> getRequestedProtocols()
Deprecated.Java API- Specified by:
getRequestedProtocolsin interfaceUpgradeToWebSocket- Specified by:
getRequestedProtocolsin interfaceWebSocketUpgrade- Specified by:
getRequestedProtocolsin interfaceWebSocketUpgrade- Returns:
- (undocumented)
-
handleMessages
HttpResponse handleMessages(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,java.lang.Object> handlerFlow, scala.Option<java.lang.String> subprotocol)
Deprecated.The high-level interface to create a WebSocket server based on "messages".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.
- Specified by:
handleMessagesin interfaceWebSocketUpgrade- Parameters:
handlerFlow- (undocumented)subprotocol- (undocumented)- Returns:
- (undocumented)
-
handleMessagesWith
HttpResponse handleMessagesWith(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,?> handlerFlow)
Deprecated.Java API- Specified by:
handleMessagesWithin interfaceUpgradeToWebSocket- Specified by:
handleMessagesWithin interfaceWebSocketUpgrade- Specified by:
handleMessagesWithin interfaceWebSocketUpgrade- Parameters:
handlerFlow- (undocumented)- Returns:
- (undocumented)
-
handleMessagesWith
HttpResponse handleMessagesWith(akka.stream.Graph<akka.stream.FlowShape<Message,Message>,?> handlerFlow, java.lang.String subprotocol)
Deprecated.Java API- Specified by:
handleMessagesWithin interfaceUpgradeToWebSocket- Specified by:
handleMessagesWithin interfaceWebSocketUpgrade- Specified by:
handleMessagesWithin interfaceWebSocketUpgrade- Parameters:
handlerFlow- (undocumented)subprotocol- (undocumented)- Returns:
- (undocumented)
-
handleMessagesWith
HttpResponse handleMessagesWith(akka.stream.Graph<akka.stream.SinkShape<Message>,?> inSink, akka.stream.Graph<akka.stream.SourceShape<Message>,?> outSource)
Deprecated.Java API- Specified by:
handleMessagesWithin interfaceUpgradeToWebSocket- Specified by:
handleMessagesWithin interfaceWebSocketUpgrade- Specified by:
handleMessagesWithin interfaceWebSocketUpgrade- Parameters:
inSink- (undocumented)outSource- (undocumented)- Returns:
- (undocumented)
-
handleMessagesWith
HttpResponse handleMessagesWith(akka.stream.Graph<akka.stream.SinkShape<Message>,?> inSink, akka.stream.Graph<akka.stream.SourceShape<Message>,?> outSource, java.lang.String subprotocol)
Deprecated.Java API- Specified by:
handleMessagesWithin interfaceUpgradeToWebSocket- Specified by:
handleMessagesWithin interfaceWebSocketUpgrade- Specified by:
handleMessagesWithin interfaceWebSocketUpgrade- Parameters:
inSink- (undocumented)outSource- (undocumented)subprotocol- (undocumented)- Returns:
- (undocumented)
-
handleMessagesWithSinkSource
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)
Deprecated.The high-level interface to create a WebSocket server based on "messages".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.
- Specified by:
handleMessagesWithSinkSourcein interfaceWebSocketUpgrade- Parameters:
inSink- (undocumented)outSource- (undocumented)subprotocol- (undocumented)- Returns:
- (undocumented)
-
requestedProtocols
scala.collection.immutable.Seq<java.lang.String> requestedProtocols()
Deprecated.A sequence of protocols the client accepts.See http://tools.ietf.org/html/rfc6455#section-1.9
- Specified by:
requestedProtocolsin interfaceWebSocketUpgrade- Returns:
- (undocumented)
-
-