import { Server } from "https://deno.land/x/snel@v0.7.1/imports/wocket.ts";
The SocketServer
class is responsible for creating a users socket server.
Similar to how Drash.Http.Server creates a server instance.
Properties
A property to hold the Deno server. This property is set in this.run() like so:
this.deno_server = serve();
A property to hold the transmitter. The transmitter is in charge of transmitting data throughout the server-client lifecycle.
Methods
Handle a binary message sent by the socket client.
Handle a message in the format of a JSON string.
Handle a string message sent by the socket client.
Handles websocket connection. After a successful connection, the client will be added to EventEmitter.clients and the server will start listening to events.
Handles websocket secure connection. After a successful connection, the client will be added to EventEmitter.clients and the server will start listening to events.