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

Unified Diff: components/offline_pages/background/request_coordinator.h

Issue 2221323003: Add an API to Pause and Resume background offlining requests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix unit test break introduced by merge Created 4 years, 4 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 | components/offline_pages/background/request_coordinator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/offline_pages/background/request_coordinator.h
diff --git a/components/offline_pages/background/request_coordinator.h b/components/offline_pages/background/request_coordinator.h
index 5f32ac82cd51d3123724f66a91e9ad8be0d51dfd..2273da556345cf3dc75e5f7df34065bd1e27fd41 100644
--- a/components/offline_pages/background/request_coordinator.h
+++ b/components/offline_pages/background/request_coordinator.h
@@ -55,7 +55,15 @@ class RequestCoordinator : public KeyedService {
// TODO(petewil): Add code to cancel an in-progress pre-render.
void RemoveRequests(const std::vector<int64_t>& request_ids);
- // Callback that receives the response for GetRequests. Client must
+ // Pause a list of requests by |request_id|. This will change the state
+ // in the request queue so the request cannot be started.
+ // TODO(petewil): Add code to cancel an in-progress pre-render.
+ void PauseRequests(const std::vector<int64_t>& request_ids);
+
+ // Resume a list of previously paused requests, making them available.
+ void ResumeRequests(const std::vector<int64_t>& request_ids);
+
+ // Callback that receives the response for GetAllRequests. Client must
// copy the result right away, it goes out of scope at the end of the
// callback.
typedef base::Callback<void(const std::vector<SavePageRequest>&)>
« no previous file with comments | « no previous file | components/offline_pages/background/request_coordinator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698