- Preparing search index...
- The search index is not available
Chess Bots
Constructors
constructor
- new ClientManager(socketManager: SocketManager, hostId?: string, clientId?: string): ClientManager
-
Parameters
-
-
Optional
hostId: string
-
Optional
clientId: string
Properties
Private
Optional
clientId
clientId?: string
Private
Optional
hostId
hostId?: string
Methods
assignPlayer
- assignPlayer(id: string): void
-
Returns void
getClientSocket
- getClientSocket(): undefined | WebSocket
-
Returns undefined | WebSocket
getHostSocket
- getHostSocket(): undefined | WebSocket
-
Returns undefined | WebSocket
sendToClient
- sendToClient(message: Message): boolean
-
Returns boolean
sendToHost
- sendToHost(message: Message): boolean
-
Returns boolean
A class which maps client ids to their corresponding sockets (if any).