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

Side by Side Diff: content/public/browser/browser_child_process_host.h

Issue 12662019: Split the ProcessType enum into process types that content knows about (which will remain in src\co… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 years, 9 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 | Annotate | Revision Log
OLDNEW
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_BROWSER_BROWSER_CHILD_PROCESS_HOST_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_BROWSER_CHILD_PROCESS_HOST_H_
6 #define CONTENT_PUBLIC_BROWSER_BROWSER_CHILD_PROCESS_HOST_H_ 6 #define CONTENT_PUBLIC_BROWSER_BROWSER_CHILD_PROCESS_HOST_H_
7 7
8 #include "base/process_util.h" 8 #include "base/process_util.h"
9 #include "base/string16.h" 9 #include "base/string16.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
(...skipping 12 matching lines...) Expand all
23 class BrowserChildProcessHostDelegate; 23 class BrowserChildProcessHostDelegate;
24 class ChildProcessHost; 24 class ChildProcessHost;
25 class SandboxedProcessLauncherDelegate; 25 class SandboxedProcessLauncherDelegate;
26 struct ChildProcessData; 26 struct ChildProcessData;
27 27
28 // This represents child processes of the browser process, i.e. plugins. They 28 // This represents child processes of the browser process, i.e. plugins. They
29 // will get terminated at browser shutdown. 29 // will get terminated at browser shutdown.
30 class CONTENT_EXPORT BrowserChildProcessHost : public IPC::Sender { 30 class CONTENT_EXPORT BrowserChildProcessHost : public IPC::Sender {
31 public: 31 public:
32 // Used to create a child process host. The delegate must outlive this object. 32 // Used to create a child process host. The delegate must outlive this object.
33 // |process_type| needs to be either an enum value from ProcessType or an
34 // embedder-defined value.
33 static BrowserChildProcessHost* Create( 35 static BrowserChildProcessHost* Create(
34 ProcessType type, 36 int process_type,
35 BrowserChildProcessHostDelegate* delegate); 37 BrowserChildProcessHostDelegate* delegate);
36 38
37 virtual ~BrowserChildProcessHost() {} 39 virtual ~BrowserChildProcessHost() {}
38 40
39 // Derived classes call this to launch the child process asynchronously. 41 // Derived classes call this to launch the child process asynchronously.
40 // Takes ownership of |cmd_line| and |delegate|. 42 // Takes ownership of |cmd_line| and |delegate|.
41 virtual void Launch( 43 virtual void Launch(
42 #if defined(OS_WIN) 44 #if defined(OS_WIN)
43 SandboxedProcessLauncherDelegate* delegate, 45 SandboxedProcessLauncherDelegate* delegate,
44 #elif defined(OS_POSIX) 46 #elif defined(OS_POSIX)
(...skipping 25 matching lines...) Expand all
70 72
71 #if defined(OS_MACOSX) && !defined(OS_IOS) 73 #if defined(OS_MACOSX) && !defined(OS_IOS)
72 // Returns a PortProvider used to get process metrics for child processes. 74 // Returns a PortProvider used to get process metrics for child processes.
73 static base::ProcessMetrics::PortProvider* GetPortProvider(); 75 static base::ProcessMetrics::PortProvider* GetPortProvider();
74 #endif 76 #endif
75 }; 77 };
76 78
77 }; // namespace content 79 }; // namespace content
78 80
79 #endif // CONTENT_PUBLIC_BROWSER_BROWSER_CHILD_PROCESS_HOST_H_ 81 #endif // CONTENT_PUBLIC_BROWSER_BROWSER_CHILD_PROCESS_HOST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698