| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // This is the browser side of the resource dispatcher, it receives requests | 5 // This is the browser side of the resource dispatcher, it receives requests |
| 6 // from the child process (i.e. [Renderer, Plugin, Worker]ProcessHost), and | 6 // from the child process (i.e. [Renderer, Plugin, Worker]ProcessHost), and |
| 7 // dispatches them to URLRequests. It then forwards the messages from the | 7 // dispatches them to URLRequests. It then forwards the messages from the |
| 8 // URLRequests back to the correct process for handling. | 8 // URLRequests back to the correct process for handling. |
| 9 // | 9 // |
| 10 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading | 10 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 } | 54 } |
| 55 | 55 |
| 56 namespace content { | 56 namespace content { |
| 57 class ResourceContext; | 57 class ResourceContext; |
| 58 class ResourceDispatcherHostDelegate; | 58 class ResourceDispatcherHostDelegate; |
| 59 class ResourceMessageDelegate; | 59 class ResourceMessageDelegate; |
| 60 class ResourceMessageFilter; | 60 class ResourceMessageFilter; |
| 61 class ResourceRequestInfoImpl; | 61 class ResourceRequestInfoImpl; |
| 62 class SaveFileManager; | 62 class SaveFileManager; |
| 63 class WebContentsImpl; | 63 class WebContentsImpl; |
| 64 struct CommonNavigationParams; |
| 64 struct DownloadSaveInfo; | 65 struct DownloadSaveInfo; |
| 65 struct NavigationRequestInfo; | 66 struct NavigationRequestInfo; |
| 66 struct Referrer; | 67 struct Referrer; |
| 67 | 68 |
| 68 class CONTENT_EXPORT ResourceDispatcherHostImpl | 69 class CONTENT_EXPORT ResourceDispatcherHostImpl |
| 69 : public ResourceDispatcherHost, | 70 : public ResourceDispatcherHost, |
| 70 public ResourceLoaderDelegate { | 71 public ResourceLoaderDelegate { |
| 71 public: | 72 public: |
| 72 ResourceDispatcherHostImpl(); | 73 ResourceDispatcherHostImpl(); |
| 73 virtual ~ResourceDispatcherHostImpl(); | 74 virtual ~ResourceDispatcherHostImpl(); |
| (...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 245 bool HasSufficientResourcesForRequest(const net::URLRequest* request_); | 246 bool HasSufficientResourcesForRequest(const net::URLRequest* request_); |
| 246 | 247 |
| 247 // Called by a ResourceHandler after it has finished its request and is done | 248 // Called by a ResourceHandler after it has finished its request and is done |
| 248 // using its shared memory buffer. Frees up that file descriptor to be used | 249 // using its shared memory buffer. Frees up that file descriptor to be used |
| 249 // elsewhere. | 250 // elsewhere. |
| 250 void FinishedWithResourcesForRequest(const net::URLRequest* request_); | 251 void FinishedWithResourcesForRequest(const net::URLRequest* request_); |
| 251 | 252 |
| 252 // PlzNavigate | 253 // PlzNavigate |
| 253 // Called by NavigationRequest to start a navigation request in the node | 254 // Called by NavigationRequest to start a navigation request in the node |
| 254 // identified by |frame_node_id|. | 255 // identified by |frame_node_id|. |
| 255 void StartNavigationRequest(const NavigationRequestInfo& info, | 256 void StartNavigationRequest(const CommonNavigationParams& common_params, |
| 257 const NavigationRequestInfo& info, |
| 256 scoped_refptr<ResourceRequestBody> request_body, | 258 scoped_refptr<ResourceRequestBody> request_body, |
| 257 int64 navigation_request_id, | 259 int64 navigation_request_id, |
| 258 int64 frame_node_id); | 260 int64 frame_node_id); |
| 259 | 261 |
| 260 // PlzNavigate | 262 // PlzNavigate |
| 261 // Called by NavigationRequest to cancel a navigation request with the | 263 // Called by NavigationRequest to cancel a navigation request with the |
| 262 // provided |navigation_request_id| in the node identified by | 264 // provided |navigation_request_id| in the node identified by |
| 263 // |frame_node_id|. | 265 // |frame_node_id|. |
| 264 void CancelNavigationRequest(int64 navigation_request_id, | 266 void CancelNavigationRequest(int64 navigation_request_id, |
| 265 int64 frame_node_id); | 267 int64 frame_node_id); |
| (...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 536 DelegateMap delegate_map_; | 538 DelegateMap delegate_map_; |
| 537 | 539 |
| 538 scoped_ptr<ResourceScheduler> scheduler_; | 540 scoped_ptr<ResourceScheduler> scheduler_; |
| 539 | 541 |
| 540 DISALLOW_COPY_AND_ASSIGN(ResourceDispatcherHostImpl); | 542 DISALLOW_COPY_AND_ASSIGN(ResourceDispatcherHostImpl); |
| 541 }; | 543 }; |
| 542 | 544 |
| 543 } // namespace content | 545 } // namespace content |
| 544 | 546 |
| 545 #endif // CONTENT_BROWSER_LOADER_RESOURCE_DISPATCHER_HOST_IMPL_H_ | 547 #endif // CONTENT_BROWSER_LOADER_RESOURCE_DISPATCHER_HOST_IMPL_H_ |
| OLD | NEW |