/// <summary> /// Initializes the supervisor. /// </summary> public static void Initialize(IStatsStrategy stats) { if (stats == null) { throw new ArgumentNullException ("stats"); } _stats = stats; _taskQueue = new Queue<TaskWrapper>(); _tasks = new List<TaskWrapper>(); _threads = new List<TaskThread>(); _stats.MaxThreads.RawValue = TaskMaxThreads; ZeroPerformanceCounters(); }
/// <summary> /// Initializes the supervisor. /// </summary> public static void Initialize(IStatsStrategy stats) { if (stats == null) { throw new ArgumentNullException("stats"); } _stats = stats; _taskQueue = new Queue <TaskWrapper>(); _tasks = new List <TaskWrapper>(); _threads = new List <TaskThread>(); _stats.MaxThreads.RawValue = TaskMaxThreads; ZeroPerformanceCounters(); }