Beispiel #1
0
        private void AddCallAndUpdateEaCache(string destinationUri, Call call)
        {
            _activeCalls.Add(call.Id, call);
            CallStateChangedEventArgs ea;

            if (!_eaCache.TryGetValue(new ValueWrapper <int>(call.Id), out ea))
            {
                ea = new CallStateChangedEventArgs {
                    Id = call.Id
                };
                _eaCache.Add(new ValueWrapper <int>(call.Id), ea);
            }
            ea.DestinationUri = destinationUri;
        }
Beispiel #2
0
 static void CallManager_CallStateChanged(object sender, CallStateChangedEventArgs e)
 {
     System.Console.WriteLine("Call to {0}: {1}", e.DestinationUri, e.Duration);
 }
 private void AddCallAndUpdateEaCache(string destinationUri, Call call)
 {
     _activeCalls.Add(call.Id, call);
     CallStateChangedEventArgs ea;
     if (!_eaCache.TryGetValue(new ValueWrapper<int>(call.Id), out ea))
     {
         ea = new CallStateChangedEventArgs {Id = call.Id};
         _eaCache.Add(new ValueWrapper<int>(call.Id), ea);
     }
     ea.DestinationUri = destinationUri;
 }