Socket defines how to connect via websocket. Therefore, it needs an baseUrl and an optional list of protocols. The Session will be established after calling the connect method.
Appends the given subUrl to the baseUrl and returns a new instance of Socket.
Creates a Session by trying to connect to the websocket endpoint. When connection was successfully made, you can send and receive message via websockets.
sets or overrides the given list of protocols for the Socket and returns a new instance of Socket.