Beispiel #1
0
 public RoutineArgs(RoutineTemplate routine, StatusSetter setter, IPTableModel[] tables, int index)
 {
     Routine = routine;
     Setter  = setter;
     Tables  = tables;
     Index   = index;
 }
Beispiel #2
0
        public RoutineWorker(RoutineTemplate routine, StatusSetter setter, IPTableModel[] tables, int index)
        {
            worker                       = new Thread(ThreadRoutine);
            timeWaitController           = new System.Timers.Timer(TimeWait);
            timeWaitController.AutoReset = true;
            timeWaitController.Elapsed  += (a, b) =>
            {
                workerWaitControl.Set();
            };

            this.routine = routine;
            worker.Start(new RoutineArgs(routine, setter, tables, index));
            timeWaitController.Start();
        }
 private void RegisterWorker(RoutineTemplate routine, int index)
 {
     workers.Add(new RoutineWorker(routine, observer, IPTable.ToArray(), index));
 }