Index: content/browser/service_worker/service_worker_job_coordinator.h |
diff --git a/content/browser/service_worker/service_worker_job_coordinator.h b/content/browser/service_worker/service_worker_job_coordinator.h |
index 4817a52fcbaabd7e61953dba04ef0985f4b35f4b..5ade985c7b3a1c889911b15f6a6abf0d88d16464 100644 |
--- a/content/browser/service_worker/service_worker_job_coordinator.h |
+++ b/content/browser/service_worker/service_worker_job_coordinator.h |
@@ -35,6 +35,8 @@ class CONTENT_EXPORT ServiceWorkerJobCoordinator { |
const GURL& pattern, |
const ServiceWorkerUnregisterJob::UnregistrationCallback& callback); |
+ void AbortAll(); |
+ |
// Jobs are removed whenever they are finished or canceled. |
falken
2014/06/19 08:10:56
Now we have three verbs "abort", "finish", and "ca
nhiroki
2014/06/19 10:04:05
SGTM. Updated.
|
void FinishJob(const GURL& pattern, ServiceWorkerRegisterJobBase* job); |
@@ -55,6 +57,9 @@ class CONTENT_EXPORT ServiceWorkerJobCoordinator { |
bool empty() { return jobs_.empty(); } |
+ // Aborts all jobs in the queue and removes them. |
+ void AbortAll(); |
+ |
// Marks that the browser is shutting down, so jobs may be destroyed before |
// finishing. |
void ClearForShutdown(); |
@@ -68,7 +73,7 @@ class CONTENT_EXPORT ServiceWorkerJobCoordinator { |
// The ServiceWorkerContextCore object should always outlive the |
// job coordinator, the core owns the coordinator. |
base::WeakPtr<ServiceWorkerContextCore> context_; |
- RegistrationJobMap jobs_; |
+ RegistrationJobMap job_queues_; |
DISALLOW_COPY_AND_ASSIGN(ServiceWorkerJobCoordinator); |
}; |