public void Run(Action action) { if (action != null) { Console.WriteLine("Invoking nested"); var asyncResult = action.BeginInvoke(ar => { action.EndInvoke(ar); }, null); asyncResult.AsyncWaitHandle.WaitOne(); } CallCompleted.Set(); }
private void HandleCallCompleted(Completed completed) { var eventToStore = new CallCompleted() { ConversationId = Guid.Parse(FormatUuid(completed.ConversationUuid)), StartTime = completed.StartTime, EndTime = completed.EndTime, Duration = int.Parse(completed.Duration) }; this._session.Events.Append(eventToStore.ConversationId, eventToStore); }
public void Apply(CallCompleted completed) { this.EndedAt = completed.EndTime; this.Duration = completed.Duration; }
/// <summary> /// Call this function to trigger notification /// </summary> /// <param name="e"></param> protected virtual void OnCallCompleted(EventArgs e) { CallCompleted?.Invoke(this, e); }
internal void OnCompleted(RestClient client, RestCallData callData) { CallCompleted?.Invoke(client, new RestClientEventArgs(callData)); }