更新時間:2019-11-20
描述
用戶在移動客戶端通過會議列表一鍵入會的方式加入會議。
前提條件
業(yè)務(wù)流程
在加入會議時,需要傳入的參數(shù)為:是否接入視頻會議以及入會參數(shù)。
//Java code public int joinConf(TsdkConfJoinParam confJoinParam, boolean isVideo, String joinNumber) { Log.i(TAG, "join conf."); int result = TsdkManager.getInstance().getConferenceManager().joinConference(confJoinParam, isVideo, joinNumber); if (result != 0) { Log.e(TAG, "joinConf result ->" + result); currentConference = null; return result; } return 0; } |
//Java code public void handleJoinConfResult(TsdkConference tsdkConference, TsdkCommonResult commonResult, TsdkJoinConfIndInfo tsdkJoinConfIndInfo Log.i(TAG, "handleJoinConfResult"); if ((tsdkConference == null) || (commonResult == null)) { return; } int result = commonResult.getResult(); if (result == 0) { this.currentConference = tsdkConference; this.memberList = null; this.self = null; TsdkCall tsdkCall = tsdkConference.getCall(); if (null != tsdkCall) { Session newSession = CallMgr.getInstance().getCallSessionByCallID(tsdkCall.getCallInfo().getCallId()); if (null == newSession) { newSession = new Session(tsdkCall); CallMgr.getInstance().putCallSessionToMap(newSession); } if (tsdkCall.getCallInfo().getIsVideoCall() == 1) { VideoMgr.getInstance().initVideoWindow(tsdkCall.getCallInfo().getCallId()); } } mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.JOIN_CONF_SUCCESS, tsdkConference.getHandle() + ""); } else { mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.JOIN_CONF_FAILED, result); } } |
詳細(xì)流程參見會議信息及會議狀態(tài)更新描述。
//Java code public void handleGetDataConfParamsResult(TsdkConference tsdkConference, TsdkCommonResult commonResult){ Log.i(TAG, "handleJoinConfResult"); if ((tsdkConference == null) || (commonResult == null)) { return; } int result = commonResult.getResult(); mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.GET_DATA_CONF_PARAM_RESULT, result); } |
//Java code public int joinDataConf() { if (null == currentConference) { Log.e(TAG, "join data conf failed, currentConference is null "); return -1; } int result = currentConference.joinDataConference(); return result; } |
在加入數(shù)據(jù)會議后,通過TsdkNotify對象中的onEvtInfoAndStatusUpdate()方法向UI上報會議信息及狀態(tài)更新事件,UI刷新會議狀態(tài)和成員列表。
//Java code public void handleJoinDataConfResult(TsdkConference tsdkConference, TsdkCommonResult commonResult){ Log.i(TAG, "handleJoinDataConfResult"); if ((tsdkConference == null) || (commonResult == null)) { return; } int result = commonResult.getResult(); mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.JOIN_DATA_CONF_RESULT, result); } |
注意事項
無。
描述
用戶由第三方途徑獲取會議信息,通過輸入會議號和接入碼的方式加入會議。
前提條件
參見會議列表一鍵入會。
業(yè)務(wù)流程
參見會議列表一鍵入會。
注意事項
無。
描述
用戶由第三方途徑獲取會議信息,通過撥打統(tǒng)一會議接入號,使用IVR導(dǎo)航的方式加入會議。
前提條件
業(yè)務(wù)流程
// Java code TsdkCall call = TsdkManager.getInstance().getCallManager().startCall(toNumber, isVideoCall); |
//Java code public void onEvtCallConnected(TsdkCall call){ Log.i(TAG, "onCallConnected"); if (null == call) { Log.e(TAG, "call obj is null"); return; } CallInfo callInfo = getCallInfo(call); Session callSession = getCallSessionByCallID(call.getCallInfo().getCallId()); if (callSession == null) { Log.e(TAG, "call session obj is null"); return; } if (callInfo.isVideoCall()) { callSession.setCallStatus(CallConstant.CallStatus.VIDEO_CALLING); } else { callSession.setCallStatus(CallConstant.CallStatus.AUDIO_CALLING); } mCallNotification.onCallEventNotify(CallConstant.CallEvent.CALL_CONNECTED, callInfo); } |
//Java code public boolean reDial(int code) { TsdkDtmfTone tsdkDtmfTone = TsdkDtmfTone.enumOf(code); LogUtil.d(TAG, "Dtmf Tone :" + tsdkDtmfTone.getIndex()); int result = tsdkCall.sendDtmf(tsdkDtmfTone); if (result != 0) { LogUtil.e(TAG, "sendDTMF return failed, result = " + result); return false; } return true; } |
//Java code public void handleJoinConfResult(TsdkConference tsdkConference, TsdkCommonResult commonResult, TsdkJoinConfIndInfo tsdkJoinConfIndInfo Log.i(TAG, "handleJoinConfResult"); if ((tsdkConference == null) || (commonResult == null)) { return; } int result = commonResult.getResult(); if (result == 0) { this.currentConference = tsdkConference; this.memberList = null; this.self = null; TsdkCall tsdkCall = tsdkConference.getCall(); if (null != tsdkCall) { Session newSession = CallMgr.getInstance().getCallSessionByCallID(tsdkCall.getCallInfo().getCallId()); if (null == newSession) { newSession = new Session(tsdkCall); CallMgr.getInstance().putCallSessionToMap(newSession); } if (tsdkCall.getCallInfo().getIsVideoCall() == 1) { VideoMgr.getInstance().initVideoWindow(tsdkCall.getCallInfo().getCallId()); } } mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.JOIN_CONF_SUCCESS, tsdkConference.getHandle() + ""); } else { mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.JOIN_CONF_FAILED, result); } } |
詳細(xì)流程參見會議信息及會議狀態(tài)更新描述。
//Java code public void handleGetDataConfParamsResult(TsdkConference tsdkConference, TsdkCommonResult commonResult){ Log.i(TAG, "handleJoinConfResult"); if ((tsdkConference == null) || (commonResult == null)) { return; } int result = commonResult.getResult(); mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.GET_DATA_CONF_PARAM_RESULT, result); } |
//Java code public int joinDataConf() { if (null == currentConference) { Log.e(TAG, "join data conf failed, currentConference is null "); return -1; } int result = currentConference.joinDataConference(); return result; } |
在加入數(shù)據(jù)會議后,通過TsdkNotify對象中的onEvtInfoAndStatusUpdate()方法向UI上報會議信息及狀態(tài)更新事件,UI刷新會議狀態(tài)和成員列表。
//Java code public void handleJoinDataConfResult(TsdkConference tsdkConference, TsdkCommonResult commonResult){ Log.i(TAG, "handleJoinDataConfResult"); if ((tsdkConference == null) || (commonResult == null)) { return; } int result = commonResult.getResult(); mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.JOIN_DATA_CONF_RESULT, result); } |
注意事項
無。
描述
會議主席邀請新的與會者加入會議。
前提條件
與會者通過主席身份加入會議,或已申請獲取為主席。
業(yè)務(wù)流程
在會議來電通知攜帶的信息中,TsdkConference.callInfo中的對端號碼(getPeerNumber())一般默認(rèn)為會議服務(wù)的統(tǒng)一接入號碼,作為對用戶的提示意義不大,建議使用TsdkConference中的會議主題(getSubject())作為來電提示信息。
//Java code public void handleConfIncomingInd(TsdkConference conference){ if (null == conference) { return; } currentConference = conference; TsdkCall tsdkCall = conference.getCall(); if (null != tsdkCall) { Session newSession = CallMgr.getInstance().getCallSessionByCallID(tsdkCall.getCallInfo().getCallId()); if (null == newSession) { newSession = new Session(tsdkCall); CallMgr.getInstance().putCallSessionToMap(newSession); } } mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.CONF_INCOMING_TO_CALL_INCOMING, conference); } |
若用戶拒絕接聽會議來電,則通過調(diào)用TsdkConference對象中的rejectConference()方法拒接會議來電。
//Java code public int acceptConf(boolean isVideo) { Log.i(TAG, "accept conf."); if (null == currentConference) { Log.i(TAG, "accept conf, currentConference is null "); return 0; } int result = currentConference.acceptConference(isVideo); if (result == 0) { Log.i(TAG, "accept conf"); } return result; } |
//Java code public int rejectConf() { Log.i(TAG, "reject conf."); if (null == currentConference) { Log.i(TAG, "reject conf, currentConference is null "); return 0; } int result = currentConference.rejectConference(); if (result == 0) { currentConference = null; } return result; } |
//Java code public void handleJoinConfResult(TsdkConference tsdkConference, TsdkCommonResult commonResult, TsdkJoinConfIndInfo tsdkJoinConfIndInfo Log.i(TAG, "handleJoinConfResult"); if ((tsdkConference == null) || (commonResult == null)) { return; } int result = commonResult.getResult(); if (result == 0) { this.currentConference = tsdkConference; this.memberList = null; this.self = null; TsdkCall tsdkCall = tsdkConference.getCall(); if (null != tsdkCall) { Session newSession = CallMgr.getInstance().getCallSessionByCallID(tsdkCall.getCallInfo().getCallId()); if (null == newSession) { newSession = new Session(tsdkCall); CallMgr.getInstance().putCallSessionToMap(newSession); } if (tsdkCall.getCallInfo().getIsVideoCall() == 1) { VideoMgr.getInstance().initVideoWindow(tsdkCall.getCallInfo().getCallId()); } } mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.JOIN_CONF_SUCCESS, tsdkConference.getHandle() + ""); } else { mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.JOIN_CONF_FAILED, result); } } |
詳細(xì)流程參見會議信息及會議狀態(tài)更新描述。
注意事項
無。
描述
用戶在未注冊EC帳號時,通過匿名方式加入會議。
前提條件
會議已經(jīng)創(chuàng)建,且用戶通過第三方方式獲取到會議ID和密碼。
業(yè)務(wù)流程
參數(shù)TsdkConfAnonymousJoinParam中的服務(wù)器地址和端口,指會議服務(wù)器的地址和端口。
//Java code //set local IP String localIpAddress = DeviceManager.getLocalIpAddress(false); TsdkLocalAddress localAddress = new TsdkLocalAddress(localIpAddress); TsdkManager.getInstance().setConfigParam(localAddress); TsdkConfAnonymousJoinParam anonymousParam = new TsdkConfAnonymousJoinParam(); anonymousParam.setConfId(joinParam.getAnonymousConfId()); anonymousParam.setConfPassword(joinParam.getConfPassword()); anonymousParam.setDisplayName(joinParam.getDisplayName()); anonymousParam.setServerAddr(joinParam.getServiceAddress()); anonymousParam.setServerPort(Integer.valueOf(joinParam.getServicePort())); anonymousParam.setUserId(1); int result = TsdkManager.getInstance().getConferenceManager().joinConferenceByAnonymous(anonymousParam); |
若此次事件通知返回失敗,應(yīng)用程序界面應(yīng)提示用戶。
//Java code public void handleGetTempUserResult(int userId, TsdkCommonResult result) { if(result == null){ return; } mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.GET_TEMP_USER_RESULT, result); } |
匿名會議過程中,無論用戶采用主席密碼入會或是普通與會者密碼入會,均只有設(shè)置自己閉音的會控能力,其他會控能力暫不支持。
//Java code public void handleJoinConfResult(TsdkConference tsdkConference, TsdkCommonResult commonResult, TsdkJoinConfIndInfo tsdkJoinConfIndInfo Log.i(TAG, "handleJoinConfResult"); if ((tsdkConference == null) || (commonResult == null)) { return; } int result = commonResult.getResult(); if (result == 0) { this.currentConference = tsdkConference; this.memberList = null; this.self = null; TsdkCall tsdkCall = tsdkConference.getCall(); if (null != tsdkCall) { Session newSession = CallMgr.getInstance().getCallSessionByCallID(tsdkCall.getCallInfo().getCallId()); if (null == newSession) { newSession = new Session(tsdkCall); CallMgr.getInstance().putCallSessionToMap(newSession); } if (tsdkCall.getCallInfo().getIsVideoCall() == 1) { VideoMgr.getInstance().initVideoWindow(tsdkCall.getCallInfo().getCallId()); } } mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.JOIN_CONF_SUCCESS, tsdkConference.getHandle() + ""); } else { mConfNotification.onConfEventNotify(ConfConstant.CONF_EVENT.JOIN_CONF_FAILED, result); } } |