OLD | NEW |
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 CONTENT_COMMON_IN_PROCESS_CHILD_THREAD_PARAMS_H_ | 5 #ifndef CONTENT_COMMON_IN_PROCESS_CHILD_THREAD_PARAMS_H_ |
6 #define CONTENT_COMMON_IN_PROCESS_CHILD_THREAD_PARAMS_H_ | 6 #define CONTENT_COMMON_IN_PROCESS_CHILD_THREAD_PARAMS_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
11 #include "base/sequenced_task_runner.h" | 11 #include "base/single_thread_task_runner.h" |
12 #include "content/common/content_export.h" | 12 #include "content/common/content_export.h" |
13 | 13 |
14 namespace content { | 14 namespace content { |
15 | 15 |
16 // Tells ChildThreadImpl to run in in-process mode. There are a couple of | 16 // Tells ChildThreadImpl to run in in-process mode. There are a couple of |
17 // parameters to run in the mode: An emulated io task runner used by | 17 // parameters to run in the mode: An emulated io task runner used by |
18 // ChnanelMojo, an IPC channel name to open. | 18 // ChnanelMojo, an IPC channel name to open. |
19 class CONTENT_EXPORT InProcessChildThreadParams { | 19 class CONTENT_EXPORT InProcessChildThreadParams { |
20 public: | 20 public: |
21 InProcessChildThreadParams(scoped_refptr<base::SequencedTaskRunner> io_runner, | 21 InProcessChildThreadParams( |
22 const std::string& service_request_token); | 22 scoped_refptr<base::SingleThreadTaskRunner> io_runner, |
| 23 const std::string& service_request_token); |
23 InProcessChildThreadParams(const InProcessChildThreadParams& other); | 24 InProcessChildThreadParams(const InProcessChildThreadParams& other); |
24 ~InProcessChildThreadParams(); | 25 ~InProcessChildThreadParams(); |
25 | 26 |
26 scoped_refptr<base::SequencedTaskRunner> io_runner() const { | 27 scoped_refptr<base::SingleThreadTaskRunner> io_runner() const { |
27 return io_runner_; | 28 return io_runner_; |
28 } | 29 } |
29 const std::string& service_request_token() const { | 30 const std::string& service_request_token() const { |
30 return service_request_token_; | 31 return service_request_token_; |
31 } | 32 } |
32 | 33 |
33 private: | 34 private: |
34 scoped_refptr<base::SequencedTaskRunner> io_runner_; | 35 scoped_refptr<base::SingleThreadTaskRunner> io_runner_; |
35 std::string service_request_token_; | 36 std::string service_request_token_; |
36 }; | 37 }; |
37 | 38 |
38 } // namespace content | 39 } // namespace content |
39 | 40 |
40 #endif // CONTENT_COMMON_IN_PROCESS_CHILD_THREAD_PARAMS_H_ | 41 #endif // CONTENT_COMMON_IN_PROCESS_CHILD_THREAD_PARAMS_H_ |
OLD | NEW |