How to use the react-native-voximplant.Voximplant.getInstance function in react-native-voximplant

To help you get started, we’ve selected a few react-native-voximplant examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github voximplant / react-native-demo / src / manager / LoginManager.js View on Github external
constructor() {
        this.client = Voximplant.getInstance();
        // Connection to the Voximplant Cloud is stayed alive on reloading of the app's
        // JavaScript code. Calling "disconnect" API here makes the SDK and app states
        // synchronized.
        PushManager.init();
        (async() => {
            try {
                this.client.disconnect();
            } catch (e) {

            }
        })();
        this.client.on(Voximplant.ClientEvents.ConnectionClosed, this._connectionClosed);
    }
github voximplant / react-native-demo / src / screens / CallScreen.js View on Github external
(async() => {
                this.call = await Voximplant.getInstance().call(this.callTo, callSettings);
                this.setupListeners();
                let callManager = CallManager.getInstance();
                callManager.addCall(this.call);
                if (callSettings.setupCallKit) {
                    callManager.startOutgoingCallViaCallKit(this.isVideoCall, this.callTo);
                }
            })();
        }
github voximplant / react-native-demo / src / manager / CallManager.js View on Github external
constructor() {
        this.client = Voximplant.getInstance();
        this.currentAppState = AppState.currentState;
        if (Platform.OS === 'ios') {
            this.callKitManager = CallKitManager.getInstance();
        }
    }