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_PUBLIC_COMMON_CHILD_PROCESS_HOST_H_ | 5 #ifndef CONTENT_PUBLIC_COMMON_CHILD_PROCESS_HOST_H_ |
6 #define CONTENT_PUBLIC_COMMON_CHILD_PROCESS_HOST_H_ | 6 #define CONTENT_PUBLIC_COMMON_CHILD_PROCESS_HOST_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include "base/files/scoped_file.h" | 10 #include "base/files/scoped_file.h" |
(...skipping 22 matching lines...) Expand all Loading... |
33 // processes like plugins, or an embedder could even use this for long lived | 33 // processes like plugins, or an embedder could even use this for long lived |
34 // processes that run independent of the browser process. | 34 // processes that run independent of the browser process. |
35 class CONTENT_EXPORT ChildProcessHost : public IPC::Sender { | 35 class CONTENT_EXPORT ChildProcessHost : public IPC::Sender { |
36 public: | 36 public: |
37 ~ChildProcessHost() override {} | 37 ~ChildProcessHost() override {} |
38 | 38 |
39 // This is a value never returned as the unique id of any child processes of | 39 // This is a value never returned as the unique id of any child processes of |
40 // any kind, including the values returned by RenderProcessHost::GetID(). | 40 // any kind, including the values returned by RenderProcessHost::GetID(). |
41 static int kInvalidUniqueID; | 41 static int kInvalidUniqueID; |
42 | 42 |
43 // This value is used as the tracing id of the browser process for identifying | |
44 // cross-process shared memory segments when tracing. | |
45 // Note: In single-process mode all the clients of tracing will use this id. | |
46 static uint64_t kBrowserTracingProcessId; | |
47 | |
48 // Used to create a child process host. The delegate must outlive this object. | 43 // Used to create a child process host. The delegate must outlive this object. |
49 static ChildProcessHost* Create(ChildProcessHostDelegate* delegate); | 44 static ChildProcessHost* Create(ChildProcessHostDelegate* delegate); |
50 | 45 |
51 // These flags may be passed to GetChildPath in order to alter its behavior, | 46 // These flags may be passed to GetChildPath in order to alter its behavior, |
52 // causing it to return a child path more suited to a specific task. | 47 // causing it to return a child path more suited to a specific task. |
53 enum { | 48 enum { |
54 // No special behavior requested. | 49 // No special behavior requested. |
55 CHILD_NORMAL = 0, | 50 CHILD_NORMAL = 0, |
56 | 51 |
57 #if defined(OS_LINUX) | 52 #if defined(OS_LINUX) |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
101 | 96 |
102 // Returns the service_manager::InterfaceProvider the process host can use to | 97 // Returns the service_manager::InterfaceProvider the process host can use to |
103 // bind | 98 // bind |
104 // interfaces exposed to it from the child. | 99 // interfaces exposed to it from the child. |
105 virtual service_manager::InterfaceProvider* GetRemoteInterfaces() = 0; | 100 virtual service_manager::InterfaceProvider* GetRemoteInterfaces() = 0; |
106 }; | 101 }; |
107 | 102 |
108 }; // namespace content | 103 }; // namespace content |
109 | 104 |
110 #endif // CONTENT_PUBLIC_COMMON_CHILD_PROCESS_HOST_H_ | 105 #endif // CONTENT_PUBLIC_COMMON_CHILD_PROCESS_HOST_H_ |
OLD | NEW |