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

Side by Side Diff: mojo/public/cpp/bindings/interface_endpoint_controller.h

Issue 2100683002: Mojo C++ Bindings: Extract AssociatedGroupController from MultiplexRouter (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: oops more gyp ugh Created 4 years, 5 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_INTERFACE_ENDPOINT_CONTROLLER_H_ 5 #ifndef MOJO_PUBLIC_CPP_BINDINGS_INTERFACE_ENDPOINT_CONTROLLER_H_
6 #define MOJO_PUBLIC_CPP_BINDINGS_LIB_INTERFACE_ENDPOINT_CONTROLLER_H_ 6 #define MOJO_PUBLIC_CPP_BINDINGS_INTERFACE_ENDPOINT_CONTROLLER_H_
7 7
8 namespace mojo { 8 namespace mojo {
9 9
10 class Message; 10 class Message;
11 11
12 namespace internal { 12 // A control interface exposed by AssociatedGroupController for interface
13 13 // endpoints.
14 // A control interface exposed by MultiplexRouter for interface endpoints.
15 class InterfaceEndpointController { 14 class InterfaceEndpointController {
16 public: 15 public:
17 virtual ~InterfaceEndpointController() {} 16 virtual ~InterfaceEndpointController() {}
18 17
19 virtual bool SendMessage(Message* message) = 0; 18 virtual bool SendMessage(Message* message) = 0;
20 19
21 // Allows the interface endpoint to watch for incoming sync messages while 20 // Allows the interface endpoint to watch for incoming sync messages while
22 // others perform sync handle watching on the same thread. Please see comments 21 // others perform sync handle watching on the same thread. Please see comments
23 // of SyncHandleWatcher::AllowWokenUpBySyncWatchOnSameThread(). 22 // of SyncHandleWatcher::AllowWokenUpBySyncWatchOnSameThread().
24 virtual void AllowWokenUpBySyncWatchOnSameThread() = 0; 23 virtual void AllowWokenUpBySyncWatchOnSameThread() = 0;
25 24
26 // Watches the interface endpoint for incoming sync messages. (It also watches 25 // Watches the interface endpoint for incoming sync messages. (It also watches
27 // other other handles registered to be watched together.) 26 // other other handles registered to be watched together.)
28 // This method: 27 // This method:
29 // - returns true when |should_stop| is set to true; 28 // - returns true when |should_stop| is set to true;
30 // - return false otherwise, including 29 // - return false otherwise, including
31 // MultiplexRouter::DetachEndpointClient() being called for the same 30 // MultiplexRouter::DetachEndpointClient() being called for the same
32 // interface endpoint. 31 // interface endpoint.
33 virtual bool SyncWatch(const bool* should_stop) = 0; 32 virtual bool SyncWatch(const bool* should_stop) = 0;
34 }; 33 };
35 34
36 } // namespace internal
37 } // namespace mojo 35 } // namespace mojo
38 36
39 #endif // MOJO_PUBLIC_CPP_BINDINGS_LIB_INTERFACE_ENDPOINT_CONTROLLER_H_ 37 #endif // MOJO_PUBLIC_CPP_BINDINGS_INTERFACE_ENDPOINT_CONTROLLER_H_
OLDNEW
« no previous file with comments | « mojo/public/cpp/bindings/interface_endpoint_client.h ('k') | mojo/public/cpp/bindings/interface_id.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698