bind Websocket
fun <REQ, RES> bindWebsocket(route: String? = null, function: suspend T.(<ERROR CLASS><REQ>, <ERROR CLASS><RES>) -> Unit, requestSerializerFactory: () -> <ERROR CLASS><REQ>, responseSerializerFactory: () -> <ERROR CLASS><RES>)
Content copied to clipboard
Binds a given web socket connection with a function of the receiver.
Parameters
request Message Type
the type of each message received via websocket
response Message Type
the type of each message to be sent via websocket
function
a function of the receiver
route
a route