| OLD | NEW | 
|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_URL_REQUEST_JOB_H_ | 5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_URL_REQUEST_JOB_H_ | 
| 6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_URL_REQUEST_JOB_H_ | 6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_URL_REQUEST_JOB_H_ | 
| 7 | 7 | 
| 8 #include <stdint.h> | 8 #include <stdint.h> | 
| 9 | 9 | 
| 10 #include <map> | 10 #include <map> | 
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 93     // was a main resource. | 93     // was a main resource. | 
| 94     virtual void MainResourceLoadFailed() {} | 94     virtual void MainResourceLoadFailed() {} | 
| 95 | 95 | 
| 96     // Returns the origin of the page/context which initiated this request. | 96     // Returns the origin of the page/context which initiated this request. | 
| 97     virtual GURL GetRequestingOrigin() = 0; | 97     virtual GURL GetRequestingOrigin() = 0; | 
| 98   }; | 98   }; | 
| 99 | 99 | 
| 100   ServiceWorkerURLRequestJob( | 100   ServiceWorkerURLRequestJob( | 
| 101       net::URLRequest* request, | 101       net::URLRequest* request, | 
| 102       net::NetworkDelegate* network_delegate, | 102       net::NetworkDelegate* network_delegate, | 
|  | 103       const std::string& client_id, | 
| 103       base::WeakPtr<storage::BlobStorageContext> blob_storage_context, | 104       base::WeakPtr<storage::BlobStorageContext> blob_storage_context, | 
| 104       const ResourceContext* resource_context, | 105       const ResourceContext* resource_context, | 
| 105       FetchRequestMode request_mode, | 106       FetchRequestMode request_mode, | 
| 106       FetchCredentialsMode credentials_mode, | 107       FetchCredentialsMode credentials_mode, | 
| 107       FetchRedirectMode redirect_mode, | 108       FetchRedirectMode redirect_mode, | 
| 108       bool is_main_resource_load, | 109       bool is_main_resource_load, | 
| 109       RequestContextType request_context_type, | 110       RequestContextType request_context_type, | 
| 110       RequestContextFrameType frame_type, | 111       RequestContextFrameType frame_type, | 
| 111       scoped_refptr<ResourceRequestBody> body, | 112       scoped_refptr<ResourceRequestBody> body, | 
| 112       Delegate* delegate); | 113       Delegate* delegate); | 
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 242   net::HttpByteRange byte_range_; | 243   net::HttpByteRange byte_range_; | 
| 243   scoped_ptr<net::HttpResponseInfo> range_response_info_; | 244   scoped_ptr<net::HttpResponseInfo> range_response_info_; | 
| 244   scoped_ptr<net::HttpResponseInfo> http_response_info_; | 245   scoped_ptr<net::HttpResponseInfo> http_response_info_; | 
| 245   // Headers that have not yet been committed to |http_response_info_|. | 246   // Headers that have not yet been committed to |http_response_info_|. | 
| 246   scoped_refptr<net::HttpResponseHeaders> http_response_headers_; | 247   scoped_refptr<net::HttpResponseHeaders> http_response_headers_; | 
| 247   GURL response_url_; | 248   GURL response_url_; | 
| 248   blink::WebServiceWorkerResponseType service_worker_response_type_; | 249   blink::WebServiceWorkerResponseType service_worker_response_type_; | 
| 249 | 250 | 
| 250   // Used when response type is FORWARD_TO_SERVICE_WORKER. | 251   // Used when response type is FORWARD_TO_SERVICE_WORKER. | 
| 251   scoped_ptr<ServiceWorkerFetchDispatcher> fetch_dispatcher_; | 252   scoped_ptr<ServiceWorkerFetchDispatcher> fetch_dispatcher_; | 
|  | 253   std::string client_id_; | 
| 252   base::WeakPtr<storage::BlobStorageContext> blob_storage_context_; | 254   base::WeakPtr<storage::BlobStorageContext> blob_storage_context_; | 
| 253   const ResourceContext* resource_context_; | 255   const ResourceContext* resource_context_; | 
| 254   scoped_ptr<net::URLRequest> blob_request_; | 256   scoped_ptr<net::URLRequest> blob_request_; | 
| 255   scoped_refptr<Stream> stream_; | 257   scoped_refptr<Stream> stream_; | 
| 256   GURL waiting_stream_url_; | 258   GURL waiting_stream_url_; | 
| 257   scoped_refptr<net::IOBuffer> stream_pending_buffer_; | 259   scoped_refptr<net::IOBuffer> stream_pending_buffer_; | 
| 258   int stream_pending_buffer_size_; | 260   int stream_pending_buffer_size_; | 
| 259 | 261 | 
| 260   FetchRequestMode request_mode_; | 262   FetchRequestMode request_mode_; | 
| 261   FetchCredentialsMode credentials_mode_; | 263   FetchCredentialsMode credentials_mode_; | 
| (...skipping 12 matching lines...) Expand all  Loading... | 
| 274   bool did_record_result_ = false; | 276   bool did_record_result_ = false; | 
| 275 | 277 | 
| 276   base::WeakPtrFactory<ServiceWorkerURLRequestJob> weak_factory_; | 278   base::WeakPtrFactory<ServiceWorkerURLRequestJob> weak_factory_; | 
| 277 | 279 | 
| 278   DISALLOW_COPY_AND_ASSIGN(ServiceWorkerURLRequestJob); | 280   DISALLOW_COPY_AND_ASSIGN(ServiceWorkerURLRequestJob); | 
| 279 }; | 281 }; | 
| 280 | 282 | 
| 281 }  // namespace content | 283 }  // namespace content | 
| 282 | 284 | 
| 283 #endif  // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_URL_REQUEST_JOB_H_ | 285 #endif  // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_URL_REQUEST_JOB_H_ | 
| OLD | NEW | 
|---|