Package-level declarations
Types
Represents a server-side web socket session with all default implementations
WebSockets support plugin. It is required to be installed first before binding any websocket endpoints
Represents a server-side web socket session
An OutgoingContent response object that could be used to respond()
: it will cause application engine to perform HTTP upgrade and start websocket RAW session.
Properties
Functions
Dequeues a frame and deserializes it to the type T using WebSocket content converter. May throw an exception WebsocketDeserializeException if the converter can't deserialize frame data to type T. May throw WebsocketDeserializeException if the received frame type is not Frame.Text or Frame.Binary. In this case, WebsocketDeserializeException.frame contains the received frame. May throw ClosedReceiveChannelException if a channel was closed
Serializes data to a frame and enqueues this frame. May suspend if the outgoing queue is full. If the outgoing channel is already closed, throws an exception, so it is impossible to transfer any message. Frames sent after a Close frame are silently ignored. Note that a Close frame could be sent automatically in reply to a peer's Close frame unless it is a raw WebSocket session.
Bind WebSocket at the current route optionally checking for the WebSocket protocol (ignored if null
) Requires WebSockets plugin to be installed.
Bind WebSocket at the current route + path optionally checking for the WebSocket protocol (ignored if null
) Requires WebSockets plugin to be installed.
Bind RAW WebSocket at the current route optionally checking for the WebSocket protocol (ignored if null
) Requires WebSockets plugin to be installed.
Binds RAW WebSocket at the current route + path optionally checking the for WebSocket protocol (ignored if null
) Requires WebSockets plugin to be installed.
Bind RAW WebSocket at the current route + path optionally checking for the WebSocket protocol (ignored if null
) Requires WebSockets plugin to be installed.
WebSockets support plugin. It is required to be installed first before binding any websocket endpoints