Socket Builder
class SocketBuilder
A builder class used to configure WebSocket server sessions.
This class allows for the setup of WebSocket event handlers such as connection, message reception, and disconnection. It also provides middleware support to process events before passing to the handler.
Functions
Link copied to clipboard
Sets the callback to be invoked when the WebSocket connection is closed.
Link copied to clipboard
Sets the callback to be invoked when a WebSocket connection is established.
Link copied to clipboard
Sets the callback to be invoked when a message is received through the WebSocket connection.
Link copied to clipboard
Adds middleware to the WebSocket session.