Exemplo n.º 1
0
        public Task AddSyncAction(SyncAction syncAction)
        {
            Console.WriteLine($"Add SyncAction to Buffer at {DateTime.Now}");
            Console.WriteLine($"SyncAction = {syncAction}");

            return(buffer.SendAsync(syncAction));
        }
Exemplo n.º 2
0
        private void timerBlockAction(SyncAction obj)
        {
            if (!timerIsRunning)
            {
                Console.ForegroundColor = ConsoleColor.Blue;
                Console.WriteLine($"Start Timer at {DateTime.Now} with timeout = {timeout}");
                Console.ResetColor();

                timer             = Observable.Interval(timeout).Timestamp();
                timerSubscription = timer.Subscribe(timerTriggered);
                timerIsRunning    = true;
            }
        }