public IAsyncResult BeginStopMonitoringSession( AsyncCallback userCallback, object state) { SupervisorMonitoringChannel monitoringChannel = _monitoringChannel; if (monitoringChannel == null) { AsyncResultNoResult result = new AsyncResultNoResult(userCallback, state); result.SetAsCompleted(null, true); return(result); } _monitoringChannel = null; requestType request = _requestProcessor.CreateRequest(ContextChannelRequestType.StopMonitoring); request.terminatemonitoringsession = new terminatemonitoringsessionType(); request.terminatemonitoringsession.sessionId = monitoringChannel.SessionId; ProcessRequestAsyncResult requestAsyncResult = new ProcessRequestAsyncResult(request, _requestProcessor, Conversation, ApplicationId, userCallback, state); _requestProcessor.AddPendingRequest(request, requestAsyncResult); requestAsyncResult.Process(); return(requestAsyncResult); }
public IAsyncResult BeginHold(AsyncCallback userCallback, object state) { requestType request = _requestProcessor.CreateRequest(ContextChannelRequestType.Hold); ProcessRequestAsyncResult requestAsyncResult = new ProcessRequestAsyncResult(request, _requestProcessor, Conversation, ApplicationId, userCallback, state); _requestProcessor.AddPendingRequest(request, requestAsyncResult); requestAsyncResult.Process(); return(requestAsyncResult); }
public IAsyncResult BeginBargeIn( AsyncCallback userCallback, object state) { requestType request = _requestProcessor.CreateRequest(ContextChannelRequestType.BargeIn); ProcessRequestAsyncResult requestAsyncResult = new ProcessRequestAsyncResult(request, _requestProcessor, SupervisorDashboardChannel.Conversation, SupervisorDashboardChannel.ApplicationId, userCallback, state); _requestProcessor.AddPendingRequest(request, requestAsyncResult); requestAsyncResult.Process(); return requestAsyncResult; }
public IAsyncResult BeginWhisper(Uri uri, AsyncCallback userCallback, object state) { requestType request = _requestProcessor.CreateRequest(ContextChannelRequestType.Whisper); request.whisper = new whisperType(); request.whisper.uri = uri.ToString(); ProcessRequestAsyncResult requestAsyncResult = new ProcessRequestAsyncResult(request, _requestProcessor, SupervisorDashboardChannel.Conversation, SupervisorDashboardChannel.ApplicationId, userCallback, state); _requestProcessor.AddPendingRequest(request, requestAsyncResult); requestAsyncResult.Process(); return requestAsyncResult; }
public IAsyncResult BeginEscalate(IEnumerable <agentSkillType> skills, AsyncCallback userCallback, object state) { requestType request = _requestProcessor.CreateRequest(ContextChannelRequestType.Escalate); request.escalate = new escalateType(); request.escalate.agentSkills = skills.ToArray(); ProcessRequestAsyncResult requestAsyncResult = new ProcessRequestAsyncResult(request, _requestProcessor, Conversation, ApplicationId, userCallback, state); _requestProcessor.AddPendingRequest(request, requestAsyncResult); requestAsyncResult.Process(); return(requestAsyncResult); }