Skip to main content

Class: SocketBroadcastHandler

Defined in: socket/broadcast.ts:6

A subclass of the SocketEventHandler that handles the broadcast events.

Extends

Constructors

Constructor

new SocketBroadcastHandler(room, eventName, source, payload): SocketBroadcastHandler

Defined in: socket/index.ts:41

Parameters

room

Room

The Room where the event is happening

eventName

string

The name of the event

source

User

The User associated with the event

payload

IKeyValue

The input values of the event

Returns

SocketBroadcastHandler

Inherited from

SocketEventHandler.constructor

Properties

eventName

protected eventName: string

Defined in: socket/index.ts:21

The event name of a socket event

Inherited from

SocketEventHandler.eventName


input

protected input: IKeyValue

Defined in: socket/index.ts:27

The input of the socket event

Inherited from

SocketEventHandler.input


output

protected output: SocketIOContextOutput

Defined in: socket/index.ts:24

The output of the socket event

Inherited from

SocketEventHandler.output


room

protected room: Room

Defined in: socket/index.ts:30

The room where the event is occurring

Inherited from

SocketEventHandler.room


source

protected source: User

Defined in: socket/index.ts:33

The user associated with the event

Inherited from

SocketEventHandler.source

Methods

passthru()

protected passthru(): Promise<void>

Defined in: socket/index.ts:52

Event to Trigger a sendToRooms event.

Returns

Promise<void>

Inherited from

SocketEventHandler.passthru


process()

protected process(): Promise<any>

Defined in: socket/broadcast.ts:11

Processes whether a user is muting their audio/video and when chat messages have been sent.

Returns

Promise<any>

either a chat or mute event

Overrides

SocketEventHandler.process


result()

result(): Promise<SocketIOContextOutput>

Defined in: socket/index.ts:72

The output produced from this.process

Returns

Promise<SocketIOContextOutput>

Inherited from

SocketEventHandler.result