• Home
  • Raw
  • Download

Lines Matching refs:task

58   Task* task = new Task(closure, time_->CreateTimer(), min_delay, max_delay);  in ScheduleTask()  local
59 tasks_.insert(task); in ScheduleTask()
61 RunAndDeleteTask(task); in ScheduleTask()
63 MakeTaskEligible(task); in ScheduleTask()
65 MakeTaskWaiting(task); in ScheduleTask()
79 Task* task = *it; in RunEligibleTasks() local
80 DCHECK(task); in RunEligibleTasks()
81 DCHECK(task->eligible); in RunEligibleTasks()
82 RunAndDeleteTask(task); in RunEligibleTasks()
86 void DomainReliabilityDispatcher::MakeTaskWaiting(Task* task) { in MakeTaskWaiting() argument
87 DCHECK(task); in MakeTaskWaiting()
88 DCHECK(!task->eligible); in MakeTaskWaiting()
89 DCHECK(!task->timer->IsRunning()); in MakeTaskWaiting()
90 task->timer->Start(FROM_HERE, in MakeTaskWaiting()
91 task->min_delay, in MakeTaskWaiting()
94 task)); in MakeTaskWaiting()
98 DomainReliabilityDispatcher::MakeTaskEligible(Task* task) { in MakeTaskEligible() argument
99 DCHECK(task); in MakeTaskEligible()
100 DCHECK(!task->eligible); in MakeTaskEligible()
101 task->eligible = true; in MakeTaskEligible()
102 eligible_tasks_.insert(task); in MakeTaskEligible()
103 task->timer->Start(FROM_HERE, in MakeTaskEligible()
104 task->max_delay - task->min_delay, in MakeTaskEligible()
107 task)); in MakeTaskEligible()
110 void DomainReliabilityDispatcher::RunAndDeleteTask(Task* task) { in RunAndDeleteTask() argument
111 DCHECK(task); in RunAndDeleteTask()
112 DCHECK(!task->closure.is_null()); in RunAndDeleteTask()
113 task->closure.Run(); in RunAndDeleteTask()
114 if (task->eligible) in RunAndDeleteTask()
115 eligible_tasks_.erase(task); in RunAndDeleteTask()
116 tasks_.erase(task); in RunAndDeleteTask()
117 delete task; in RunAndDeleteTask()