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

Side by Side Diff: content/public/common/child_process_host_delegate.h

Issue 725353003: Don't pass ProcessHandle through ChildProcessHostDelegate. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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
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_COMMON_CHILD_PROCESS_HOST_DELEGATE_H_ 5 #ifndef CONTENT_PUBLIC_COMMON_CHILD_PROCESS_HOST_DELEGATE_H_
6 #define CONTENT_PUBLIC_COMMON_CHILD_PROCESS_HOST_DELEGATE_H_ 6 #define CONTENT_PUBLIC_COMMON_CHILD_PROCESS_HOST_DELEGATE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/process/process.h" 10 #include "base/process/process.h"
(...skipping 10 matching lines...) Expand all
21 // Delegates return true if it's ok to shut down the child process (which is 21 // Delegates return true if it's ok to shut down the child process (which is
22 // the default return value). The exception is if the host is in the middle of 22 // the default return value). The exception is if the host is in the middle of
23 // sending a request to the process, in which case the other side might think 23 // sending a request to the process, in which case the other side might think
24 // it's ok to shutdown, when really it's not. 24 // it's ok to shutdown, when really it's not.
25 CONTENT_EXPORT virtual bool CanShutdown(); 25 CONTENT_EXPORT virtual bool CanShutdown();
26 26
27 // Called when the child process unexpected closes the IPC channel. Delegates 27 // Called when the child process unexpected closes the IPC channel. Delegates
28 // would normally delete the object in this case. 28 // would normally delete the object in this case.
29 virtual void OnChildDisconnected() {} 29 virtual void OnChildDisconnected() {}
30 30
31 // Returns the handle of the child process. This can be called only after 31 // Returns a reference to the child process. This can be called only after
32 // OnProcessLaunched is called or it will be invalid and may crash. 32 // OnProcessLaunched is called or it will be invalid and may crash.
33 virtual base::ProcessHandle GetHandle() const = 0; 33 virtual const base::Process& GetProcess() const = 0;
34 }; 34 };
35 35
36 }; // namespace content 36 }; // namespace content
37 37
38 #endif // CONTENT_PUBLIC_COMMON_CHILD_PROCESS_HOST_DELEGATE_H_ 38 #endif // CONTENT_PUBLIC_COMMON_CHILD_PROCESS_HOST_DELEGATE_H_
OLDNEW
« content/public/browser/browser_ppapi_host.h ('K') | « content/public/browser/browser_ppapi_host.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698