예제 #1
0
        public virtual void DoWork(WorkPerformedEventArgs e)
        {
            Console.WriteLine($"Start {e.Name} ...");
            int time = e.Hours * 1000;

            Thread.Sleep(time);

            WorkPerformed?.Invoke(e);
        }
예제 #2
0
 public void workPerformed(WorkPerformedEventArgs e)
 {
     Console.WriteLine($"Finished after {e.Hours} hours");
 }