UNPKG

infobip-rtc

Version:

Infobip RTC JavaScript SDK - Infobip WebRTC API Implementation

117 lines 3.48 kB
import { CameraOrientation } from "./CameraOrientation"; import { VideoOptions } from "./VideoOptions"; import { AudioOptions } from "./AudioOptions"; import { VideoMode } from "./VideoMode"; import { AudioQualityMode } from "./AudioQualityMode"; import { PlatformOptions } from "./PlatformOptions"; export class ApplicationCallOptions { constructor(_audio, _audioOptions, _video, _videoOptions, _customData, _dataChannel, _platformOptions, _autoReconnect) { this._audio = _audio; this._audioOptions = _audioOptions; this._video = _video; this._videoOptions = _videoOptions; this._customData = _customData; this._dataChannel = _dataChannel; this._platformOptions = _platformOptions; this._autoReconnect = _autoReconnect; } get audio() { return this._audio; } set audio(value) { this._audio = value; } get audioOptions() { return this._audioOptions; } set audioOptions(value) { this._audioOptions = value; } get video() { return this._video; } set video(value) { this._video = value; } get videoOptions() { return this._videoOptions; } set videoOptions(value) { this._videoOptions = value; } get customData() { return this._customData; } set customData(value) { this._customData = value; } get dataChannel() { return this._dataChannel; } set dataChannel(value) { this._dataChannel = value; } get platformOptions() { return this._platformOptions; } set platformOptions(value) { this._platformOptions = value; } get autoReconnect() { return this._autoReconnect; } set autoReconnect(value) { this._autoReconnect = value; } static builder() { return new ApplicationCallOptionsBuilder(); } } class ApplicationCallOptionsBuilder { constructor() { this._audio = true; this._audioOptions = new AudioOptions(null, AudioQualityMode.AUTO); this._video = false; this._videoOptions = new VideoOptions(CameraOrientation.FRONT, null, VideoMode.PRESENTATION, 24, 8); this._customData = {}; this._dataChannel = false; this._platformOptions = PlatformOptions.builder().build(); this._autoReconnect = false; } setAudio(_audio) { this._audio = _audio; return this; } setAudioOptions(_audioOptions) { this._audioOptions = _audioOptions; return this; } setVideo(_video) { this._video = _video; return this; } setVideoOptions(_videoOptions) { this._videoOptions = _videoOptions; return this; } setCustomData(_customData) { this._customData = _customData; return this; } setDataChannel(_dataChannel) { this._dataChannel = _dataChannel; return this; } setPlatformOptions(_platformOptions) { this._platformOptions = _platformOptions; return this; } setAutoReconnect(_autoReconnect) { this._autoReconnect = _autoReconnect; return this; } build() { return new ApplicationCallOptions(this._audio, this._audioOptions, this._video, this._videoOptions, this._customData, this._dataChannel, this._platformOptions, this._autoReconnect); } } //# sourceMappingURL=ApplicationCallOptions.js.map