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

Side by Side Diff: mojo/public/cpp/bindings/lib/connector.h

Issue 1823683006: Mojo C++ bindings: sync call support for associated interfaces and master interfaces (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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
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_PUBLIC_CPP_BINDINGS_LIB_CONNECTOR_H_ 5 #ifndef MOJO_PUBLIC_CPP_BINDINGS_LIB_CONNECTOR_H_
6 #define MOJO_PUBLIC_CPP_BINDINGS_LIB_CONNECTOR_H_ 6 #define MOJO_PUBLIC_CPP_BINDINGS_LIB_CONNECTOR_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 void ResumeIncomingMethodCallProcessing(); 113 void ResumeIncomingMethodCallProcessing();
114 114
115 // MessageReceiver implementation: 115 // MessageReceiver implementation:
116 bool Accept(Message* message) override; 116 bool Accept(Message* message) override;
117 117
118 MessagePipeHandle handle() const { 118 MessagePipeHandle handle() const {
119 DCHECK(thread_checker_.CalledOnValidThread()); 119 DCHECK(thread_checker_.CalledOnValidThread());
120 return message_pipe_.get(); 120 return message_pipe_.get();
121 } 121 }
122 122
123 // Allows |message_pipe_| be watched while others perform sync handle watching 123 // Allows |message_pipe_| to be watched while others perform sync handle
124 // on the same thread. Please see comments of 124 // watching on the same thread. Please see comments of
125 // SyncHandleWatcher::AllowWokenUpBySyncWatchOnSameThread(). 125 // SyncHandleWatcher::AllowWokenUpBySyncWatchOnSameThread().
126 void AllowWokenUpBySyncWatchOnSameThread(); 126 void AllowWokenUpBySyncWatchOnSameThread();
127 127
128 // Watches |message_pipe_| (as well as other handles registered to be watched 128 // Watches |message_pipe_| (as well as other handles registered to be watched
129 // together) synchronously. 129 // together) synchronously.
130 // This method: 130 // This method:
131 // - returns true when |should_stop| is set to true; 131 // - returns true when |should_stop| is set to true;
132 // - return false when any error occurs, including |message_pipe_| being 132 // - return false when any error occurs, including |message_pipe_| being
133 // closed. 133 // closed.
134 bool SyncWatch(const bool* should_stop); 134 bool SyncWatch(const bool* should_stop);
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 base::WeakPtr<Connector> weak_self_; 195 base::WeakPtr<Connector> weak_self_;
196 base::WeakPtrFactory<Connector> weak_factory_; 196 base::WeakPtrFactory<Connector> weak_factory_;
197 197
198 DISALLOW_COPY_AND_ASSIGN(Connector); 198 DISALLOW_COPY_AND_ASSIGN(Connector);
199 }; 199 };
200 200
201 } // namespace internal 201 } // namespace internal
202 } // namespace mojo 202 } // namespace mojo
203 203
204 #endif // MOJO_PUBLIC_CPP_BINDINGS_LIB_CONNECTOR_H_ 204 #endif // MOJO_PUBLIC_CPP_BINDINGS_LIB_CONNECTOR_H_
OLDNEW
« no previous file with comments | « mojo/public/cpp/bindings/lib/binding_state.h ('k') | mojo/public/cpp/bindings/lib/interface_endpoint_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698