/// <summary> /// 开始通话 /// </summary> /// <param name="phone">手机号</param> /// <param name="callId">通话ID</param> /// <returns>{code:number,msg:string}</returns> public void startTalk(string phone) { VoipHelper.callId = Utils.GetCallId(); VoipHelper.callState = VoipHelper.telState.OUT; VoipHelper.callNumber = phone; VoipHelper.Call(phone); VoipHelper.OffOnHook(1); }
/// <summary> /// 挂断 /// </summary> /// <returns>{code:number,msg:string}</returns> public void stopTalk() { VoipHelper.OffOnHook(0); }
/// <summary> /// 接听来电 /// </summary> /// <param name="callId">通话ID</param> /// <returns>{code:number,msg:string}</returns> public void answerCall() { VoipHelper.OffOnHook(1); }