public Beeper( IBeeperRequirements requirements, IBeepRequirements beepRequirements, ICountingManualTimer workTimer, ICountingManualTimer restTimer) { this.requirements = requirements; this.beepRequirements = beepRequirements; this.workTimer = workTimer; this.restTimer = restTimer; this.workTimer.SetCallback(this.CallBackWork); this.restTimer.SetCallback(this.CallBackRest); }
private static void SetCounting(ICountingManualTimer timer, string actionName) { timer.SetCounting( TimeSpan.FromSeconds(1), x => Counting(actionName, timer.StartTime, timer.NextCallBackTime)); }