OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 MOJO_RUNNER_TASK_RUNNERS_H_ | 5 #ifndef MOJO_SHELL_STANDALONE_TASK_RUNNERS_H_ |
6 #define MOJO_RUNNER_TASK_RUNNERS_H_ | 6 #define MOJO_SHELL_STANDALONE_TASK_RUNNERS_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
11 #include "base/threading/thread.h" | 11 #include "base/threading/thread.h" |
12 | 12 |
13 namespace base { | 13 namespace base { |
14 class SequencedWorkerPool; | 14 class SequencedWorkerPool; |
15 } | 15 } |
16 | 16 |
17 namespace mojo { | 17 namespace mojo { |
18 namespace runner { | 18 namespace shell { |
19 | 19 |
20 // A context object that contains the common task runners for the shell's main | 20 // A context object that contains the common task runners for the shell's main |
21 // process. | 21 // process. |
22 class TaskRunners { | 22 class TaskRunners { |
23 public: | 23 public: |
24 explicit TaskRunners( | 24 explicit TaskRunners( |
25 const scoped_refptr<base::SingleThreadTaskRunner>& shell_runner); | 25 const scoped_refptr<base::SingleThreadTaskRunner>& shell_runner); |
26 ~TaskRunners(); | 26 ~TaskRunners(); |
27 | 27 |
28 base::SingleThreadTaskRunner* shell_runner() const { | 28 base::SingleThreadTaskRunner* shell_runner() const { |
(...skipping 10 matching lines...) Expand all Loading... |
39 | 39 |
40 private: | 40 private: |
41 scoped_refptr<base::SingleThreadTaskRunner> shell_runner_; | 41 scoped_refptr<base::SingleThreadTaskRunner> shell_runner_; |
42 scoped_ptr<base::Thread> io_thread_; | 42 scoped_ptr<base::Thread> io_thread_; |
43 | 43 |
44 scoped_refptr<base::SequencedWorkerPool> blocking_pool_; | 44 scoped_refptr<base::SequencedWorkerPool> blocking_pool_; |
45 | 45 |
46 DISALLOW_COPY_AND_ASSIGN(TaskRunners); | 46 DISALLOW_COPY_AND_ASSIGN(TaskRunners); |
47 }; | 47 }; |
48 | 48 |
49 } // namespace runner | 49 } // namespace shell |
50 } // namespace mojo | 50 } // namespace mojo |
51 | 51 |
52 #endif // MOJO_RUNNER_TASK_RUNNERS_H_ | 52 #endif // MOJO_SHELL_STANDALONE_TASK_RUNNERS_H_ |
OLD | NEW |