private ITask GetNextTask() { var list = taskService.GetTaskList(); foreach (var task in list) { if (task.status == (int)StockMan.Message.Model.TaskStatus.stop) { var trigger = new TimeTrigger(task.time); if (trigger.IsTrigger()) { return(this.Build(task)); } } } return(null); }