Exemplo n.º 1
0
        void timerClearCompletedObject_Elapsed(object sender, System.Timers.ElapsedEventArgs e)
        {
            /* Pause the timer till the process is completed. */
            timerClearCompletedObject.Stop();

            /*Processing new notifications and adding them to queue.*/
            target.AlarmGarbageCollector();

            /* Start the timer once ConstructSensorObjects process completed. */
            timerClearCompletedObject.Start();
        }
Exemplo n.º 2
0
 void timerClearCompletedObject_Elapsed(object sender, System.Timers.ElapsedEventArgs e)
 {
     try
     {
         timerClearCompletedObject.Stop();
         _target.AlarmGarbageCollector();
         timerClearCompletedObject.Start();
     }
     catch (Exception ex)
     {
         throw ex;
     }
     finally
     {
         timerClearCompletedObject.Start();
     }
 }