Example #1
0
		private async Task OnInternalTimerEvent(TimerEventArgs e)
		{
			try
			{
				// ***
				// *** Check if it is time to fire the event
				// ***
				if (e.IsMyInterval(this.Interval))
				{
					// ***
					// *** Fire the event
					// ***
					await this.OnTimer(e);
				}
			}
			catch (Exception ex)
			{
				this.PublishException(ex);
			}
		}
Example #2
0
		protected virtual Task OnTimer(TimerEventArgs e)
		{
			return Task.FromResult(0);
		}
Example #3
0
		protected async override Task OnTimer(TimerEventArgs e)
		{
			await this.UpdateClock();
		}