Пример #1
0
 static void Main(string[] args)
 {
     Alarmer alarmer = new Alarmer();
     using (BreakCalculator calculator = new BreakCalculator(60*60))
     {
         BreakMediator mediator = new BreakMediator(alarmer, calculator);
         mediator.Start();
         Console.WriteLine("press <enter> to exit");
         Console.ReadLine();
     }
 }
Пример #2
0
 public BreakMediator(Alarmer alarmer, BreakCalculator calculator)
 {
     this.alarmer = alarmer;
     this.calculator = calculator;
 }