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

Unified Diff: mojo/edk/system/dispatcher.h

Issue 2744943002: Mojo: Move waiting APIs to public library (Closed)
Patch Set: . Created 3 years, 9 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/edk/system/data_pipe_unittest.cc ('k') | mojo/edk/system/dispatcher.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/system/dispatcher.h
diff --git a/mojo/edk/system/dispatcher.h b/mojo/edk/system/dispatcher.h
index 88a9de7c8509dda9969bb8bc8fe49fd4ff10aa17..175c1123be88f70fdcf464ff4c5584a156a16e1c 100644
--- a/mojo/edk/system/dispatcher.h
+++ b/mojo/edk/system/dispatcher.h
@@ -29,15 +29,13 @@
namespace mojo {
namespace edk {
-class Awakable;
class Dispatcher;
class MessageForTransit;
using DispatcherVector = std::vector<scoped_refptr<Dispatcher>>;
// A |Dispatcher| implements Mojo EDK calls that are associated with a
-// particular MojoHandle, with the exception of MojoWait and MojoWaitMany (
-// which are implemented directly in Core.).
+// particular MojoHandle.
class MOJO_SYSTEM_IMPL_EXPORT Dispatcher
: public base::RefCountedThreadSafe<Dispatcher> {
public:
@@ -174,32 +172,6 @@ class MOJO_SYSTEM_IMPL_EXPORT Dispatcher
virtual MojoResult RemoveWatcherRef(WatcherDispatcher* watcher,
uintptr_t context);
- // Adds an awakable to this dispatcher, which will be woken up when this
- // object changes state to satisfy |signals| with context |context|. It will
- // also be woken up when it becomes impossible for the object to ever satisfy
- // |signals| with a suitable error status.
- //
- // If |signals_state| is non-null, on *failure* |*signals_state| will be set
- // to the current handle signals state (on success, it is left untouched).
- //
- // Returns:
- // - |MOJO_RESULT_OK| if the awakable was added;
- // - |MOJO_RESULT_ALREADY_EXISTS| if |signals| is already satisfied;
- // - |MOJO_RESULT_INVALID_ARGUMENT| if the dispatcher has been closed; and
- // - |MOJO_RESULT_FAILED_PRECONDITION| if it is not (or no longer) possible
- // that |signals| will ever be satisfied.
- virtual MojoResult AddAwakable(Awakable* awakable,
- MojoHandleSignals signals,
- uintptr_t context,
- HandleSignalsState* signals_state);
-
- // Removes an awakable from this dispatcher. (It is valid to call this
- // multiple times for the same |awakable| on the same object, so long as
- // |AddAwakable()| was called at most once.) If |signals_state| is non-null,
- // |*signals_state| will be set to the current handle signals state.
- virtual void RemoveAwakable(Awakable* awakable,
- HandleSignalsState* signals_state);
-
// Informs the caller of the total serialized size (in bytes) and the total
// number of platform handles and ports needed to transfer this dispatcher
// across a message pipe.
« no previous file with comments | « mojo/edk/system/data_pipe_unittest.cc ('k') | mojo/edk/system/dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698