Constructor
new activeChannel(server, chanDB)
Instantiates an activeChannel object
Parameters:
| Name | Type | Description |
|---|---|---|
server |
channelManager | Parent Server Object |
chanDB |
Mongoose.Document | chanDB to rehydrate buffer from |
- Source:
Methods
(async) broadcastChanEmotes(chanDB)
Broadcasts channel emote list to connected users
Parameters:
| Name | Type | Description |
|---|---|---|
chanDB |
Mongoose.Document | Channnel Document Passthrough to save on DB Access |
- Source:
broadcastUserList()
Broadcasts user list to all users
- Source:
(async) handleConnection(userDB, chanDB, socket)
Handles server-side initialization for new connections to the channel
Parameters:
| Name | Type | Description |
|---|---|---|
userDB |
Mongoose.Document | User Document Passthrough to save on DB Access |
chanDB |
Mongoose.Document | Channnel Document Passthrough to save on DB Access |
socket |
Socket | Requesting Socket |
- Source:
handleDisconnect(socket)
Handles server-side initialization for disconnecting from the channel
Parameters:
| Name | Type | Description |
|---|---|---|
socket |
Socket | Requesting Socket |
- Source: