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

Side by Side Diff: content/browser/service_worker/service_worker_dispatcher_host.h

Issue 2653493009: Add two interfaces for ServiceWorkerProviderContext/ProviderHost (Closed)
Patch Set: Skip unittest for CrossSiteTransfer when PlzNavigate Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ 5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_
6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ 6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 94
95 using StatusCallback = base::Callback<void(ServiceWorkerStatusCode status)>; 95 using StatusCallback = base::Callback<void(ServiceWorkerStatusCode status)>;
96 enum class ProviderStatus { OK, NO_CONTEXT, DEAD_HOST, NO_HOST, NO_URL }; 96 enum class ProviderStatus { OK, NO_CONTEXT, DEAD_HOST, NO_HOST, NO_URL };
97 97
98 // Called when mojom::ServiceWorkerDispatcherHostPtr is created on the 98 // Called when mojom::ServiceWorkerDispatcherHostPtr is created on the
99 // renderer-side. 99 // renderer-side.
100 void AddMojoBinding(mojo::ScopedInterfaceEndpointHandle handle); 100 void AddMojoBinding(mojo::ScopedInterfaceEndpointHandle handle);
101 101
102 // mojom::ServiceWorkerDispatcherHost implementation 102 // mojom::ServiceWorkerDispatcherHost implementation
103 void OnProviderCreated(ServiceWorkerProviderHostInfo info) override; 103 void OnProviderCreated(ServiceWorkerProviderHostInfo info) override;
104 void OnProviderDestroyed(int provider_id) override;
105 void OnSetHostedVersionId(int provider_id, 104 void OnSetHostedVersionId(int provider_id,
106 int64_t version_id, 105 int64_t version_id,
107 int embedded_worker_id) override; 106 int embedded_worker_id) override;
108 107
109 // IPC Message handlers 108 // IPC Message handlers
110 void OnRegisterServiceWorker(int thread_id, 109 void OnRegisterServiceWorker(int thread_id,
111 int request_id, 110 int request_id,
112 int provider_id, 111 int provider_id,
113 const GURL& pattern, 112 const GURL& pattern,
114 const GURL& script_url); 113 const GURL& script_url);
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
269 mojo::AssociatedBindingSet<mojom::ServiceWorkerDispatcherHost> bindings_; 268 mojo::AssociatedBindingSet<mojom::ServiceWorkerDispatcherHost> bindings_;
270 269
271 base::WeakPtrFactory<ServiceWorkerDispatcherHost> weak_factory_; 270 base::WeakPtrFactory<ServiceWorkerDispatcherHost> weak_factory_;
272 271
273 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDispatcherHost); 272 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDispatcherHost);
274 }; 273 };
275 274
276 } // namespace content 275 } // namespace content
277 276
278 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ 277 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698