示例#1
0
 internal void AutoNext()
 {
     while (m_WaitingTaskList.Count > 0 && (m_MaxTask <= 0 || m_RunningTaskList.Count < m_MaxTask))
     {
         cGatherTask task = m_WaitingTaskList[0];
         task.Start();
     }
 }
示例#2
0
 internal void StartTask(cGatherTask task)
 {
     if (task.TaskState == cGlobalParas.TaskState.UnStart || task.TaskState == cGlobalParas.TaskState.Stopped || task.TaskState == cGlobalParas.TaskState.Failed || task.TaskState == cGlobalParas.TaskState.Aborted)
     {
         if (m_MaxTask <= 0 || m_RunningTaskList.Count < m_MaxTask)
         {
             task.Start();
         }
         else
         {
             task.ReadyToStart();
         }
     }
 }