package websocket
- Alphabetic
- Public
- All
Type Members
- case class BinaryMessage(data: ByteString) extends Message with Product with Serializable
A binary message.
A binary message.
- data
The data of the binary message.
- case class CloseMessage(statusCode: Option[Int] = Some(CloseCodes.Regular), reason: String = "") extends Message with Product with Serializable
A close message.
A close message.
- statusCode
The close status code.
- reason
The reason it was closed.
- sealed trait Message extends AnyRef
A WebSocket message.
A WebSocket message.
This is a high level API intended for common simple use cases. It allows handling and sending of full WebSocket messages, as well as close and ping/pong messages. It will buffer fragmented messages up until a limit, and does not allow streaming in fragments.
- case class PingMessage(data: ByteString) extends Message with Product with Serializable
A ping message.
A ping message.
- data
The application data.
- case class PongMessage(data: ByteString) extends Message with Product with Serializable
A pong message.
A pong message.
- data
The application data.
- case class TextMessage(data: String) extends Message with Product with Serializable
A text message.
A text message.
- data
The data of the text message.
- case class WebSocketCloseException(message: CloseMessage) extends RuntimeException with Product with Serializable
An exception that, if thrown by a WebSocket source, will cause the WebSocket to be closed with the given close message.
An exception that, if thrown by a WebSocket source, will cause the WebSocket to be closed with the given close message. This is a convenience that allows the WebSocket to close with a particular close code without having to produce generic Messages.
Value Members
- object CloseCodes
WebSocket close codes
- object CloseMessage extends Serializable