OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_CHILD_CHILD_THREAD_IMPL_H_ | 5 #ifndef CONTENT_CHILD_CHILD_THREAD_IMPL_H_ |
6 #define CONTENT_CHILD_CHILD_THREAD_IMPL_H_ | 6 #define CONTENT_CHILD_CHILD_THREAD_IMPL_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
11 #include <memory> | 11 #include <memory> |
12 #include <string> | 12 #include <string> |
13 | 13 |
14 #include "base/macros.h" | 14 #include "base/macros.h" |
15 #include "base/memory/shared_memory.h" | 15 #include "base/memory/shared_memory.h" |
16 #include "base/memory/weak_ptr.h" | 16 #include "base/memory/weak_ptr.h" |
17 #include "base/power_monitor/power_monitor.h" | 17 #include "base/power_monitor/power_monitor.h" |
18 #include "base/single_thread_task_runner.h" | 18 #include "base/single_thread_task_runner.h" |
19 #include "base/tracked_objects.h" | 19 #include "base/tracked_objects.h" |
20 #include "build/build_config.h" | 20 #include "build/build_config.h" |
21 #include "content/common/associated_interfaces.mojom.h" | 21 #include "content/common/associated_interfaces.mojom.h" |
22 #include "content/common/content_export.h" | 22 #include "content/common/content_export.h" |
23 #include "content/public/child/child_thread.h" | 23 #include "content/public/child/child_thread.h" |
24 #include "ipc/ipc.mojom.h" | 24 #include "ipc/ipc.mojom.h" |
25 #include "ipc/ipc_message.h" // For IPC_MESSAGE_LOG_ENABLED. | 25 #include "ipc/ipc_features.h" // For BUILDFLAG(IPC_MESSAGE_LOG_ENABLED). |
26 #include "ipc/ipc_platform_file.h" | 26 #include "ipc/ipc_platform_file.h" |
27 #include "ipc/message_router.h" | 27 #include "ipc/message_router.h" |
28 #include "mojo/public/cpp/bindings/associated_binding.h" | 28 #include "mojo/public/cpp/bindings/associated_binding.h" |
29 #include "mojo/public/cpp/bindings/associated_binding_set.h" | 29 #include "mojo/public/cpp/bindings/associated_binding_set.h" |
30 #include "services/service_manager/public/cpp/bind_source_info.h" | 30 #include "services/service_manager/public/cpp/bind_source_info.h" |
31 | 31 |
32 namespace base { | 32 namespace base { |
33 class MessageLoop; | 33 class MessageLoop; |
34 } // namespace base | 34 } // namespace base |
35 | 35 |
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
210 | 210 |
211 // We create the channel first without connecting it so we can add filters | 211 // We create the channel first without connecting it so we can add filters |
212 // prior to any messages being received, then connect it afterwards. | 212 // prior to any messages being received, then connect it afterwards. |
213 void ConnectChannel(); | 213 void ConnectChannel(); |
214 | 214 |
215 // IPC message handlers. | 215 // IPC message handlers. |
216 void OnShutdown(); | 216 void OnShutdown(); |
217 void OnSetProfilerStatus(tracked_objects::ThreadData::Status status); | 217 void OnSetProfilerStatus(tracked_objects::ThreadData::Status status); |
218 void OnGetChildProfilerData(int sequence_number, int current_profiling_phase); | 218 void OnGetChildProfilerData(int sequence_number, int current_profiling_phase); |
219 void OnProfilingPhaseCompleted(int profiling_phase); | 219 void OnProfilingPhaseCompleted(int profiling_phase); |
220 #ifdef IPC_MESSAGE_LOG_ENABLED | 220 #if BUILDFLAG(IPC_MESSAGE_LOG_ENABLED) |
221 void OnSetIPCLoggingEnabled(bool enable); | 221 void OnSetIPCLoggingEnabled(bool enable); |
222 #endif | 222 #endif |
223 | 223 |
224 void EnsureConnected(); | 224 void EnsureConnected(); |
225 | 225 |
226 // mojom::RouteProvider: | 226 // mojom::RouteProvider: |
227 void GetRoute( | 227 void GetRoute( |
228 int32_t routing_id, | 228 int32_t routing_id, |
229 mojom::AssociatedInterfaceProviderAssociatedRequest request) override; | 229 mojom::AssociatedInterfaceProviderAssociatedRequest request) override; |
230 | 230 |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
316 | 316 |
317 private: | 317 private: |
318 struct Options options_; | 318 struct Options options_; |
319 | 319 |
320 DISALLOW_COPY_AND_ASSIGN(Builder); | 320 DISALLOW_COPY_AND_ASSIGN(Builder); |
321 }; | 321 }; |
322 | 322 |
323 } // namespace content | 323 } // namespace content |
324 | 324 |
325 #endif // CONTENT_CHILD_CHILD_THREAD_IMPL_H_ | 325 #endif // CONTENT_CHILD_CHILD_THREAD_IMPL_H_ |
OLD | NEW |