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

Unified Diff: mojo/system/dispatcher.h

Issue 136343004: Mojo: Add a "GetType()" to Dispatchers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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/data_pipe_producer_dispatcher.cc ('k') | mojo/system/dispatcher_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/system/dispatcher.h
diff --git a/mojo/system/dispatcher.h b/mojo/system/dispatcher.h
index b405d1aad402235440abd5421d201755b925caa8..ca7aa4f2a4dff7eb822443279dd3dbc2482b853d 100644
--- a/mojo/system/dispatcher.h
+++ b/mojo/system/dispatcher.h
@@ -27,6 +27,14 @@ class Waiter;
class MOJO_SYSTEM_IMPL_EXPORT Dispatcher :
public base::RefCountedThreadSafe<Dispatcher> {
public:
+ enum Type {
+ kTypeUnknown = 0,
+ kTypeMessagePipe,
+ kTypeDataPipeProducer,
+ kTypeDataPipeConsumer
+ };
+ virtual Type GetType() = 0;
+
// These methods implement the various primitives named |Mojo...()|. These
// take |lock_| and handle races with |Close()|. Then they call out to
// subclasses' |...ImplNoLock()| methods (still under |lock_|), which actually
« no previous file with comments | « mojo/system/data_pipe_producer_dispatcher.cc ('k') | mojo/system/dispatcher_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698