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

Unified Diff: mojo/system/raw_channel.h

Issue 137273003: Mojo: Rename PlatformChannelHandle to PlatformHandle, etc. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 6 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « mojo/system/platform_handle.cc ('k') | mojo/system/raw_channel_posix.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/system/raw_channel.h
diff --git a/mojo/system/raw_channel.h b/mojo/system/raw_channel.h
index c77272f58d65ebd724db8a47014a8c8a0ce362b7..168ac4df372fbfacbe85d093df8f12934499f18e 100644
--- a/mojo/system/raw_channel.h
+++ b/mojo/system/raw_channel.h
@@ -9,6 +9,7 @@
#include "base/basictypes.h"
#include "mojo/system/constants.h"
+#include "mojo/system/scoped_platform_handle.h"
#include "mojo/system/system_impl_export.h"
namespace base {
@@ -23,7 +24,7 @@ class MessageInTransit;
// This simply wraps an |int| file descriptor on POSIX and a |HANDLE| on
// Windows, but we don't want to impose, e.g., the inclusion of windows.h on
// everyone.
-struct PlatformChannelHandle;
+struct PlatformHandle;
// |RawChannel| is an interface to objects that wrap an OS "pipe". It presents
// the following interface to users:
@@ -66,10 +67,11 @@ class MOJO_SYSTEM_IMPL_EXPORT RawChannel {
virtual ~Delegate() {}
};
- // Static factory method. Takes ownership of |handle| (i.e., will close it).
- // Does *not* take ownership of |delegate| and |message_loop|, which must
- // remain alive while this object does.
- static RawChannel* Create(const PlatformChannelHandle& handle,
+ // Static factory method. |handle| should be a handle to a
+ // (platform-appropriate) bidirectional communication channel (e.g., a socket
+ // on POSIX, a named pipe on Windows). Does *not* take ownership of |delegate|
+ // and |message_loop|, which must remain alive while this object does.
+ static RawChannel* Create(ScopedPlatformHandle handle,
Delegate* delegate,
base::MessageLoop* message_loop);
« no previous file with comments | « mojo/system/platform_handle.cc ('k') | mojo/system/raw_channel_posix.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698