@testrtc/watchrtc-sdk
Version:
Monitor your WebRTC application by collecting WebRTC statistics from end users
24 lines (23 loc) • 825 B
TypeScript
import { ISocketService, ISocketTrace, ISocketConnectOptions, IStorage } from "./interfaces";
export default class WatchRTCSocket implements ISocketService {
static _instance: WatchRTCSocket;
connection: any | null;
wasConnected: boolean;
buffer: any[];
private sendInterval;
private onClose;
private dataCollection;
private sendPromises;
private signalsBuffer;
private timeouted;
private rawStatsStore;
private reconnectId;
constructor();
connect({ url, onData, onError, onOpen, onClose, onNewReference, options }: ISocketConnectOptions): void;
trace: ISocketTrace;
close(nailUpCallEnd?: boolean): void;
disableDataCollection(): void;
enableDataCollection(): void;
isDisabledDataCollection(): boolean;
setStatsStorage(store: IStorage): void;
}