Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(188)

Unified Diff: base/task_scheduler/delayed_task_manager.cc

Issue 2068853002: Rename SchedulerThreadPool* to SchedulerWorkerPool* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@rename1
Patch Set: CR Feedback fdoray@ Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/task_scheduler/delayed_task_manager.h ('k') | base/task_scheduler/delayed_task_manager_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/task_scheduler/delayed_task_manager.cc
diff --git a/base/task_scheduler/delayed_task_manager.cc b/base/task_scheduler/delayed_task_manager.cc
index 6286d5ef4f6f267a4fcfab471d5fbea8f07a9393..47f9bbc83a02dfb3bc2b5c0353ec71c2fcbee141 100644
--- a/base/task_scheduler/delayed_task_manager.cc
+++ b/base/task_scheduler/delayed_task_manager.cc
@@ -7,7 +7,7 @@
#include <utility>
#include "base/logging.h"
-#include "base/task_scheduler/scheduler_thread_pool.h"
+#include "base/task_scheduler/scheduler_worker_pool.h"
namespace base {
namespace internal {
@@ -16,12 +16,12 @@ struct DelayedTaskManager::DelayedTask {
DelayedTask(std::unique_ptr<Task> task,
scoped_refptr<Sequence> sequence,
SchedulerWorkerThread* worker_thread,
- SchedulerThreadPool* thread_pool,
+ SchedulerWorkerPool* worker_pool,
uint64_t index)
: task(std::move(task)),
sequence(std::move(sequence)),
worker_thread(worker_thread),
- thread_pool(thread_pool),
+ worker_pool(worker_pool),
index(index) {}
DelayedTask(DelayedTask&& other) = default;
@@ -30,12 +30,12 @@ struct DelayedTaskManager::DelayedTask {
DelayedTask& operator=(DelayedTask&& other) = default;
- // |task| will be posted to |thread_pool| with |sequence| and |worker_thread|
+ // |task| will be posted to |worker_pool| with |sequence| and |worker_thread|
// when it becomes ripe for execution.
std::unique_ptr<Task> task;
scoped_refptr<Sequence> sequence;
SchedulerWorkerThread* worker_thread;
- SchedulerThreadPool* thread_pool;
+ SchedulerWorkerPool* worker_pool;
// Ensures that tasks that have the same |delayed_run_time| are sorted
// according to the order in which they were added to the DelayedTaskManager.
@@ -56,10 +56,10 @@ DelayedTaskManager::~DelayedTaskManager() = default;
void DelayedTaskManager::AddDelayedTask(std::unique_ptr<Task> task,
scoped_refptr<Sequence> sequence,
SchedulerWorkerThread* worker_thread,
- SchedulerThreadPool* thread_pool) {
+ SchedulerWorkerPool* worker_pool) {
DCHECK(task);
DCHECK(sequence);
- DCHECK(thread_pool);
+ DCHECK(worker_pool);
const TimeTicks new_task_delayed_run_time = task->delayed_run_time;
TimeTicks current_delayed_run_time;
@@ -71,7 +71,7 @@ void DelayedTaskManager::AddDelayedTask(std::unique_ptr<Task> task,
current_delayed_run_time = delayed_tasks_.top().task->delayed_run_time;
delayed_tasks_.emplace(std::move(task), std::move(sequence), worker_thread,
- thread_pool, ++delayed_task_index_);
+ worker_pool, ++delayed_task_index_);
}
if (current_delayed_run_time.is_null() ||
@@ -103,7 +103,7 @@ void DelayedTaskManager::PostReadyTasks() {
// Post delayed tasks that are ready for execution.
for (auto& delayed_task : ready_tasks) {
- delayed_task.thread_pool->PostTaskWithSequenceNow(
+ delayed_task.worker_pool->PostTaskWithSequenceNow(
std::move(delayed_task.task), std::move(delayed_task.sequence),
delayed_task.worker_thread);
}
« no previous file with comments | « base/task_scheduler/delayed_task_manager.h ('k') | base/task_scheduler/delayed_task_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698