private void Next(object source, ElapsedEventArgs e)
 {
     if (_index >= _data.Capacity)
     {
         _sink.Complete();
         _timer.Stop();
         _promise.TrySetResult(true);
     }
     else
     {
         _sink.Deliver(_data[_index++]);
     }
 }
Esempio n. 2
0
 private void Next(object sender, ElapsedEventArgs e)
 {
     _sink.Deliver(_counter++);
 }