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

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

Issue 2084593005: Rationalize AddAwakable...() and RemoveAwakable...() methods. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: doh Created 4 years, 6 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 | « no previous file | mojo/edk/system/awakable_list.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/system/awakable_list.h
diff --git a/mojo/edk/system/awakable_list.h b/mojo/edk/system/awakable_list.h
index 7e4b732ad1c662c7bf4fa6fe8712f9063325cb8d..d1e947dfd464e397f230dd0dc13dc6d3d10f078e 100644
--- a/mojo/edk/system/awakable_list.h
+++ b/mojo/edk/system/awakable_list.h
@@ -33,9 +33,13 @@ class AwakableList {
void OnStateChange(const HandleSignalsState& old_state,
const HandleSignalsState& new_state);
void CancelAll();
- void Add(Awakable* awakable, MojoHandleSignals signals, uint64_t context);
- void Remove(Awakable* awakable);
- void RemoveWithContext(Awakable* awakable, uint64_t context);
+
+ // Adds an awakable, identified by its pointer and its context.
+ void Add(Awakable* awakable, uint64_t context, MojoHandleSignals signals);
+
+ // Removes all awakables matching the given pointer and, if |match_context| is
+ // true, the given context.
+ void Remove(bool match_context, Awakable* awakable, uint64_t context);
private:
struct AwakeInfo {
« no previous file with comments | « no previous file | mojo/edk/system/awakable_list.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698