import { IRtcPeer } from "../model/IRtcPeer"; import { RtcConnectionStatus } from "../model/RtcConnectionStatus"; import { Timestamp } from "../model/Timestamp"; import { Uuid } from "../model/Uuid"; import { IRtcClientConfigurationV1 } from "./models-v1/IRtcClientConfigurationV1"; import { IIceMode } from "./models/IIceMode"; import { IRtcSendConfiguration } from "./models/IRtcSendConfiguration"; import { IRtcStreamMessage } from "./models/IRtcStreamMessage"; import { IStreamControl } from "./models/IStreamControl"; /** * RtcClient to be used by browsers. * Interacts with signaling API v1. */ export declare class RtcClientV1 { private config; private localPeer; private updateInterval; private connections; private connectingSessions; private rtcInstancesConstructed; constructor(config: IRtcClientConfigurationV1); send(peerId: Uuid, message: IRtcStreamMessage, config: IRtcSendConfiguration): void; controlRemoteStream(peerId: Uuid, streamControl: IStreamControl): void; /** * Connects to a peer given its id. * Returns the id of the session, if one is created. */ connect(peerId: Uuid): Promise; getConnectionStatus(peerId: Uuid): RtcConnectionStatus; getIceMode(peerId: Uuid): IIceMode | undefined; disconnect(peerId: Uuid): Promise; getLocalPeer(): Promise; getPeers(): Promise; getPing(peerId: Uuid): number | undefined; getLastMessageTimestamp(remotePeerId: Uuid): Timestamp | undefined; shutdown(): Promise; private closeConnection; private getSessions; private createPeer; private createRTCPeerConnection; private closeConnections; private reset; private getActiveConnection; private update; private handleSessions; private syncConnectionsAndSessions; private maintainConnection; private connectToSession; private setupHandlers; private consumeSignals; private sendSignal; }