OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef BASE_TASK_SCHEDULER_TASK_SCHEDULER_IMPL_H_ | 5 #ifndef BASE_TASK_SCHEDULER_TASK_SCHEDULER_IMPL_H_ |
6 #define BASE_TASK_SCHEDULER_TASK_SCHEDULER_IMPL_H_ | 6 #define BASE_TASK_SCHEDULER_TASK_SCHEDULER_IMPL_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 12 matching lines...) Expand all Loading... |
23 #include "base/threading/thread.h" | 23 #include "base/threading/thread.h" |
24 | 24 |
25 namespace base { | 25 namespace base { |
26 | 26 |
27 class HistogramBase; | 27 class HistogramBase; |
28 class SchedulerWorkerPoolParams; | 28 class SchedulerWorkerPoolParams; |
29 | 29 |
30 namespace internal { | 30 namespace internal { |
31 | 31 |
32 class DelayedTaskManager; | 32 class DelayedTaskManager; |
33 class SchedulerServiceThread; | |
34 class TaskTracker; | 33 class TaskTracker; |
35 | 34 |
36 // Default TaskScheduler implementation. This class is thread-safe. | 35 // Default TaskScheduler implementation. This class is thread-safe. |
37 class BASE_EXPORT TaskSchedulerImpl : public TaskScheduler { | 36 class BASE_EXPORT TaskSchedulerImpl : public TaskScheduler { |
38 public: | 37 public: |
39 // Creates and returns an initialized TaskSchedulerImpl. CHECKs on failure. | 38 // Creates and returns an initialized TaskSchedulerImpl. CHECKs on failure. |
40 // |worker_pool_params_vector| describes the worker pools to create. | 39 // |worker_pool_params_vector| describes the worker pools to create. |
41 // |worker_pool_index_for_traits_callback| returns the index in |worker_pools| | 40 // |worker_pool_index_for_traits_callback| returns the index in |worker_pools| |
42 // of the worker pool in which a task with given traits should run. | 41 // of the worker pool in which a task with given traits should run. |
43 static std::unique_ptr<TaskSchedulerImpl> Create( | 42 static std::unique_ptr<TaskSchedulerImpl> Create( |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
93 AtomicFlag join_for_testing_returned_; | 92 AtomicFlag join_for_testing_returned_; |
94 #endif | 93 #endif |
95 | 94 |
96 DISALLOW_COPY_AND_ASSIGN(TaskSchedulerImpl); | 95 DISALLOW_COPY_AND_ASSIGN(TaskSchedulerImpl); |
97 }; | 96 }; |
98 | 97 |
99 } // namespace internal | 98 } // namespace internal |
100 } // namespace base | 99 } // namespace base |
101 | 100 |
102 #endif // BASE_TASK_SCHEDULER_TASK_SCHEDULER_IMPL_H_ | 101 #endif // BASE_TASK_SCHEDULER_TASK_SCHEDULER_IMPL_H_ |
OLD | NEW |