OLD | NEW |
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_PROVIDER_HOST_H_ | 5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_PROVIDER_HOST_H_ |
6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_PROVIDER_HOST_H_ | 6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_PROVIDER_HOST_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
189 // the request doesn't require special handling. | 189 // the request doesn't require special handling. |
190 std::unique_ptr<ServiceWorkerRequestHandler> CreateRequestHandler( | 190 std::unique_ptr<ServiceWorkerRequestHandler> CreateRequestHandler( |
191 FetchRequestMode request_mode, | 191 FetchRequestMode request_mode, |
192 FetchCredentialsMode credentials_mode, | 192 FetchCredentialsMode credentials_mode, |
193 FetchRedirectMode redirect_mode, | 193 FetchRedirectMode redirect_mode, |
194 ResourceType resource_type, | 194 ResourceType resource_type, |
195 RequestContextType request_context_type, | 195 RequestContextType request_context_type, |
196 RequestContextFrameType frame_type, | 196 RequestContextFrameType frame_type, |
197 base::WeakPtr<storage::BlobStorageContext> blob_storage_context, | 197 base::WeakPtr<storage::BlobStorageContext> blob_storage_context, |
198 scoped_refptr<ResourceRequestBodyImpl> body, | 198 scoped_refptr<ResourceRequestBodyImpl> body, |
199 bool skip_service_worker); | 199 bool skip_service_worker, |
| 200 NetworkFallbackCallback network_fallback_callback); |
200 | 201 |
201 // Used to get a ServiceWorkerObjectInfo to send to the renderer. Finds an | 202 // Used to get a ServiceWorkerObjectInfo to send to the renderer. Finds an |
202 // existing ServiceWorkerHandle, and increments its reference count, or else | 203 // existing ServiceWorkerHandle, and increments its reference count, or else |
203 // creates a new one (initialized to ref count 1). Returns the | 204 // creates a new one (initialized to ref count 1). Returns the |
204 // ServiceWorkerInfo from the handle. The renderer is expected to use | 205 // ServiceWorkerInfo from the handle. The renderer is expected to use |
205 // ServiceWorkerHandleReference::Adopt to balance out the ref count. | 206 // ServiceWorkerHandleReference::Adopt to balance out the ref count. |
206 ServiceWorkerObjectInfo GetOrCreateServiceWorkerHandle( | 207 ServiceWorkerObjectInfo GetOrCreateServiceWorkerHandle( |
207 ServiceWorkerVersion* version); | 208 ServiceWorkerVersion* version); |
208 | 209 |
209 // Returns true if |registration| can be associated with this provider. | 210 // Returns true if |registration| can be associated with this provider. |
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
423 std::unordered_map<mojom::ServiceWorkerWorkerClient*, | 424 std::unordered_map<mojom::ServiceWorkerWorkerClient*, |
424 mojom::ServiceWorkerWorkerClientAssociatedPtr> | 425 mojom::ServiceWorkerWorkerClientAssociatedPtr> |
425 worker_clients_; | 426 worker_clients_; |
426 | 427 |
427 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerProviderHost); | 428 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerProviderHost); |
428 }; | 429 }; |
429 | 430 |
430 } // namespace content | 431 } // namespace content |
431 | 432 |
432 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_PROVIDER_HOST_H_ | 433 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_PROVIDER_HOST_H_ |
OLD | NEW |