public TaskStateManager(ITaskKeeper taskKeeper, ITaskChecker taskChecker)
        {
            if (taskKeeper == null)
            {
                throw new ArgumentNullException("taskKeeper");
            }

            UpdateInterval = TimeSpan.FromSeconds(10);

            _taskKeeper  = taskKeeper;
            _taskChecker = taskChecker;

            _timer.Interval = 10000;
            _timer.Elapsed += (sender, args) => Update();

            _state = TaskProviderState.Stopped;
        }
示例#2
0
        public TaskStateManager(ITaskKeeper taskKeeper, ITaskChecker taskChecker)
        {
            if (taskKeeper == null)
            {
                throw new ArgumentNullException("taskKeeper");
            }

            UpdateInterval = TimeSpan.FromSeconds(10);

            _taskKeeper = taskKeeper;
            _taskChecker = taskChecker;

            _timer.Interval = 10000;
            _timer.Elapsed += (sender, args) => Update();

            _state = TaskProviderState.Stopped;
        }
 private void ChangeState(TaskProviderState state)
 {
     _state = state;
 }
示例#4
0
 private void ChangeState(TaskProviderState state)
 {
     _state = state;
 }