VAD
Constructors
constructor
Methods
addEventListener
addEventListener(event: , callback: Function
): void
Adds a handler for the specified Silero.VADEvents event. Use only functions as handlers; anything except a function leads to the error and scenario termination when a handler is called.
Parameters
event:
Event class (i.e., Silero.VADEvents.Result)
callback:
Function
Handler function. A single parameter is passed - object with event information
Returns
type:
void
close
close(): void
Closes the VAD connection (over WebSocket) or connection attempt.
Returns
type:
void
id
id(): string
Returns the VAD id.
Returns
type:
string
removeEventListener
removeEventListener(event: , callback: Function
): void
Removes a handler for the specified Silero.VADEvents event.
Parameters
event:
Event class (i.e., Silero.VADEvents.Result)
callback:
Function
OptionalOptional. Handler function. If not specified, all handler functions are removed
Returns
type:
void
reset
reset(): void
Reset the VAD context.
Returns
type:
void
webSocketId
webSocketId(): string
Returns the VAD WebSocket id.
Returns
type:
string