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

Side by Side Diff: mojo/system/message_pipe.h

Issue 145483005: Mojo: More work towards sending message pipe handles over remote message pipes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 10 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 MOJO_SYSTEM_MESSAGE_PIPE_H_ 5 #ifndef MOJO_SYSTEM_MESSAGE_PIPE_H_
6 #define MOJO_SYSTEM_MESSAGE_PIPE_H_ 6 #define MOJO_SYSTEM_MESSAGE_PIPE_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 MojoResult EnqueueMessage(unsigned port, 70 MojoResult EnqueueMessage(unsigned port,
71 MessageInTransit* message, 71 MessageInTransit* message,
72 const std::vector<Dispatcher*>* dispatchers); 72 const std::vector<Dispatcher*>* dispatchers);
73 73
74 // These are used by |Channel|. 74 // These are used by |Channel|.
75 void Attach(unsigned port, 75 void Attach(unsigned port,
76 scoped_refptr<Channel> channel, 76 scoped_refptr<Channel> channel,
77 MessageInTransit::EndpointId local_id); 77 MessageInTransit::EndpointId local_id);
78 void Run(unsigned port, MessageInTransit::EndpointId remote_id); 78 void Run(unsigned port, MessageInTransit::EndpointId remote_id);
79 79
80 // This is used by |ProxyMessagePipeEndpoint| in sending an endpoint over
81 // another message pipe.
DaveMoore 2014/02/03 20:01:15 What is used?
viettrungluu 2014/02/03 20:09:11 Oops (stale comment), deleted.
82
80 private: 83 private:
81 friend class base::RefCountedThreadSafe<MessagePipe>; 84 friend class base::RefCountedThreadSafe<MessagePipe>;
82 virtual ~MessagePipe(); 85 virtual ~MessagePipe();
83 86
84 // Used by |EnqueueMessage()| to handle control messages that are actually 87 // Used by |EnqueueMessage()| to handle control messages that are actually
85 // meant for us. 88 // meant for us.
86 MojoResult HandleControlMessage(unsigned port, MessageInTransit* message); 89 MojoResult HandleControlMessage(unsigned port, MessageInTransit* message);
87 90
88 base::Lock lock_; // Protects the following members. 91 base::Lock lock_; // Protects the following members.
89 scoped_ptr<MessagePipeEndpoint> endpoints_[2]; 92 scoped_ptr<MessagePipeEndpoint> endpoints_[2];
90 93
91 DISALLOW_COPY_AND_ASSIGN(MessagePipe); 94 DISALLOW_COPY_AND_ASSIGN(MessagePipe);
92 }; 95 };
93 96
94 } // namespace system 97 } // namespace system
95 } // namespace mojo 98 } // namespace mojo
96 99
97 #endif // MOJO_SYSTEM_MESSAGE_PIPE_H_ 100 #endif // MOJO_SYSTEM_MESSAGE_PIPE_H_
OLDNEW
« no previous file with comments | « no previous file | mojo/system/message_pipe_dispatcher.h » ('j') | mojo/system/message_pipe_dispatcher.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698