extension/twilio.js
/**
     * Construct a {@link PreflightTest} instance.
     * @constructor
     * @param token - A Twilio JWT token string.
     * @param options
     */
Construct a  PreflightTest instance.
@constructor
@param token - A Twilio JWT token string.
@param options
Construct a PreflightTest instance . @constructor @param token - A Twilio JWT token string . @param options
function PreflightTest(token, options) {
        var _this = _super.call(this) || this;
        _this._hasInsightsErrored = false;
        _this._networkTiming = {};
        _this._options = {
            codecPreferences: [connection_1.default.Codec.PCMU, connection_1.default.Codec.Opus],
            debug: false,
            edge: 'roaming',
            fakeMicInput: false,
            signalingTimeoutMs: 10000,
        };
        _this._status = PreflightTest.Status.Connecting;
        Object.assign(_this._options, options);
        _this._samples = [];
        _this._warnings = [];
        _this._startTime = Date.now();
        _this._initDevice(token, __assign(__assign({}, _this._options), { fileInputStream: _this._options.fakeMicInput ?
                _this._getStreamFromFile() : undefined }));
        return _this;
    }
function PreflightTest ( token , options ) { var _this = _super . call ( this ) || this ; _this . _hasInsightsErrored = false ; _this . _networkTiming = { } ; _this . _options = { codecPreferences : [ connection_1 . default . Codec . PCMU , connection_1 . default . Codec . Opus ] , debug : false , edge : 'roaming' , fakeMicInput : false , signalingTimeoutMs : 10000 , } ; _this . _status = PreflightTest . Status . Connecting ; Object . assign ( _this . _options , options ) ; _this . _samples = [ ] ; _this . _warnings = [ ] ; _this . _startTime = Date . now ( ) ; _this . _initDevice ( token , __assign ( __assign ( { } , _this . _options ) , { fileInputStream : _this . _options . fakeMicInput ? _this . _getStreamFromFile ( ) : undefined } ) ) ; return _this ; }
Construct a {@link PreflightTest} instance.
Construct a { @link PreflightTest } instance .
/**
         * Whether this test has already logged an insights-connection-warning.
         */ /**
         * Network related timing measurements for this test
         */ /**
         * The options passed to {@link PreflightTest} constructor
         */ /**
         * Current status of this test
         */