WebSocketExtension

A WebSocket extension instance. This instance is created for each WebSocket request, for every installed extension by WebSocketExtensionFactory.

Functions

Link copied to clipboard
abstract fun clientNegotiation(negotiatedProtocols: List<WebSocketExtensionHeader>): Boolean

This method is called only for the client, when it receives the WebSocket upgrade response.

Link copied to clipboard
abstract fun processIncomingFrame(frame: Frame): Frame

This method is called on each incoming frame before handling it in WebSocket session.

Link copied to clipboard
abstract fun processOutgoingFrame(frame: Frame): Frame

This method is called on each outgoing frame and handle it before sending.

Link copied to clipboard

This method is called only for the server, when it receives WebSocket session.

Properties

Link copied to clipboard

Reference to the WebSocketExtensionFactory, which produced this extension.

Link copied to clipboard

List of WebSocket extension protocols which will be sent by client in headers. They are required to inform server that client wants to negotiate the current extension.

Inheritors

Link copied to clipboard