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

Side by Side Diff: third_party/WebKit/Source/platform/scheduler/child/worker_scheduler.h

Issue 2836853003: scheduler: Use PLATFORM_EXPORT instead of BLINK_PLATFORM_EXPORT (Closed)
Patch Set: Rebased Created 3 years, 8 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WORKER_SCHEDULER_H_ 5 #ifndef THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WORKER_SCHEDULER_H_
6 #define THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WORKER_SCHEDULER_H_ 6 #define THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WORKER_SCHEDULER_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "base/message_loop/message_loop.h" 11 #include "base/message_loop/message_loop.h"
12 #include "platform/PlatformExport.h"
12 #include "platform/scheduler/base/task_queue.h" 13 #include "platform/scheduler/base/task_queue.h"
13 #include "platform/scheduler/child/scheduler_helper.h" 14 #include "platform/scheduler/child/scheduler_helper.h"
14 #include "public/platform/WebCommon.h"
15 #include "public/platform/scheduler/child/child_scheduler.h" 15 #include "public/platform/scheduler/child/child_scheduler.h"
16 #include "public/platform/scheduler/child/single_thread_idle_task_runner.h" 16 #include "public/platform/scheduler/child/single_thread_idle_task_runner.h"
17 17
18 namespace blink { 18 namespace blink {
19 namespace scheduler { 19 namespace scheduler {
20 class SchedulerTqmDelegate; 20 class SchedulerTqmDelegate;
21 21
22 class BLINK_PLATFORM_EXPORT WorkerScheduler : public ChildScheduler { 22 class PLATFORM_EXPORT WorkerScheduler : public ChildScheduler {
23 public: 23 public:
24 ~WorkerScheduler() override; 24 ~WorkerScheduler() override;
25 static std::unique_ptr<WorkerScheduler> Create( 25 static std::unique_ptr<WorkerScheduler> Create(
26 scoped_refptr<SchedulerTqmDelegate> main_task_runner); 26 scoped_refptr<SchedulerTqmDelegate> main_task_runner);
27 27
28 // Blink should use WorkerScheduler::DefaultTaskQueue instead of 28 // Blink should use WorkerScheduler::DefaultTaskQueue instead of
29 // ChildScheduler::DefaultTaskRunner. 29 // ChildScheduler::DefaultTaskRunner.
30 virtual scoped_refptr<TaskQueue> DefaultTaskQueue() = 0; 30 virtual scoped_refptr<TaskQueue> DefaultTaskQueue() = 0;
31 31
32 // Must be called before the scheduler can be used. Does any post construction 32 // Must be called before the scheduler can be used. Does any post construction
33 // initialization needed such as initializing idle period detection. 33 // initialization needed such as initializing idle period detection.
34 virtual void Init() = 0; 34 virtual void Init() = 0;
35 35
36 scoped_refptr<TaskQueue> CreateUnthrottledTaskRunner( 36 scoped_refptr<TaskQueue> CreateUnthrottledTaskRunner(
37 TaskQueue::QueueType queue_type); 37 TaskQueue::QueueType queue_type);
38 38
39 protected: 39 protected:
40 explicit WorkerScheduler(std::unique_ptr<SchedulerHelper> helper); 40 explicit WorkerScheduler(std::unique_ptr<SchedulerHelper> helper);
41 41
42 std::unique_ptr<SchedulerHelper> helper_; 42 std::unique_ptr<SchedulerHelper> helper_;
43 43
44 DISALLOW_COPY_AND_ASSIGN(WorkerScheduler); 44 DISALLOW_COPY_AND_ASSIGN(WorkerScheduler);
45 }; 45 };
46 46
47 } // namespace scheduler 47 } // namespace scheduler
48 } // namespace blink 48 } // namespace blink
49 49
50 #endif // THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WORKER_SCHEDULER_H _ 50 #endif // THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WORKER_SCHEDULER_H _
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698