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

Unified Diff: mojo/system/shared_buffer_dispatcher.h

Issue 304233005: Mojo: Implement passing of shared buffers across processes on POSIX. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 6 years, 7 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/remote_message_pipe_unittest.cc ('k') | mojo/system/shared_buffer_dispatcher.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/system/shared_buffer_dispatcher.h
diff --git a/mojo/system/shared_buffer_dispatcher.h b/mojo/system/shared_buffer_dispatcher.h
index ff1fdbc0e9b615005523676883bf0ffa15eea890..3249a62b70f88cc7f09947cf2e15a61280df5a00 100644
--- a/mojo/system/shared_buffer_dispatcher.h
+++ b/mojo/system/shared_buffer_dispatcher.h
@@ -35,6 +35,14 @@ class MOJO_SYSTEM_IMPL_EXPORT SharedBufferDispatcher : public SimpleDispatcher {
// |Dispatcher| public methods:
virtual Type GetType() const OVERRIDE;
+ // The "opposite" of |SerializeAndClose()|. (Typically this is called by
+ // |Dispatcher::Deserialize()|.)
+ static scoped_refptr<SharedBufferDispatcher> Deserialize(
+ Channel* channel,
+ const void* source,
+ size_t size,
+ embedder::PlatformHandleVector* platform_handles);
+
private:
explicit SharedBufferDispatcher(
scoped_refptr<RawSharedBuffer> shared_buffer_);
@@ -52,6 +60,14 @@ class MOJO_SYSTEM_IMPL_EXPORT SharedBufferDispatcher : public SimpleDispatcher {
uint64_t num_bytes,
MojoMapBufferFlags flags,
scoped_ptr<RawSharedBufferMapping>* mapping) OVERRIDE;
+ virtual void StartSerializeImplNoLock(Channel* channel,
+ size_t* max_size,
+ size_t* max_platform_handles) OVERRIDE;
+ virtual bool EndSerializeAndCloseImplNoLock(
+ Channel* channel,
+ void* destination,
+ size_t* actual_size,
+ embedder::PlatformHandleVector* platform_handles) OVERRIDE;
// |SimpleDispatcher| methods:
virtual MojoWaitFlags SatisfiedFlagsNoLock() const OVERRIDE;
« no previous file with comments | « mojo/system/remote_message_pipe_unittest.cc ('k') | mojo/system/shared_buffer_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698