Index: content/browser/service_worker/service_worker_context_core.h |
diff --git a/content/browser/service_worker/service_worker_context_core.h b/content/browser/service_worker/service_worker_context_core.h |
index 3cc735fc38913331d22f262369cfcc9f5b6ddaa1..ec02ba3273c60552db22e624fe6aa96b44a5a2cd 100644 |
--- a/content/browser/service_worker/service_worker_context_core.h |
+++ b/content/browser/service_worker/service_worker_context_core.h |
@@ -159,6 +159,14 @@ class CONTENT_EXPORT ServiceWorkerContextCore |
scoped_ptr<ProviderHostIterator> GetClientProviderHostIterator( |
const GURL& origin); |
+ // PlzNavigate |
+ // Methods to manage the list of ProviderHosts for navigation requests. |
+ void AddNavigationProviderHost(ServiceWorkerProviderHost* provider_host); |
+ // Returns nullptr if the ProviderHost with id |provider_id| is not present. |
+ ServiceWorkerProviderHost* TakeNavigationProviderHost(int provider_id); |
+ // Noop if the ProviderHost with id |provider_id| is not present. |
+ void RemoveNavigationProviderHost(int provider_id); |
+ |
// Maintains a map from Client UUID to ProviderHost. |
// (Note: instead of maintaining 2 maps we might be able to uniformly use |
// UUID instead of process_id+provider_id elsewhere. For now I'm leaving |
@@ -289,6 +297,11 @@ class CONTENT_EXPORT ServiceWorkerContextCore |
std::map<int64, ServiceWorkerRegistration*> live_registrations_; |
std::map<int64, ServiceWorkerVersion*> live_versions_; |
std::map<int64, scoped_refptr<ServiceWorkerVersion>> protected_versions_; |
+ |
+ // PlzNavigate |
+ // Map of ServiceWorkerProviderHost used for navigation requests. |
+ std::map<int, ServiceWorkerProviderHost*> navigation_provider_host_map_; |
+ |
int next_handle_id_; |
int next_registration_handle_id_; |
// Set in RegisterServiceWorker(), cleared in ClearAllServiceWorkersForTest(). |