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 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading | 5 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading |
6 | 6 |
7 #ifndef CONTENT_CHILD_RESOURCE_DISPATCHER_H_ | 7 #ifndef CONTENT_CHILD_RESOURCE_DISPATCHER_H_ |
8 #define CONTENT_CHILD_RESOURCE_DISPATCHER_H_ | 8 #define CONTENT_CHILD_RESOURCE_DISPATCHER_H_ |
9 | 9 |
10 #include <deque> | 10 #include <deque> |
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
183 void OnUploadProgress(int request_id, int64 position, int64 size); | 183 void OnUploadProgress(int request_id, int64 position, int64 size); |
184 void OnReceivedResponse(int request_id, const ResourceResponseHead&); | 184 void OnReceivedResponse(int request_id, const ResourceResponseHead&); |
185 void OnReceivedCachedMetadata(int request_id, const std::vector<char>& data); | 185 void OnReceivedCachedMetadata(int request_id, const std::vector<char>& data); |
186 void OnReceivedRedirect(int request_id, | 186 void OnReceivedRedirect(int request_id, |
187 const net::RedirectInfo& redirect_info, | 187 const net::RedirectInfo& redirect_info, |
188 const ResourceResponseHead& response_head); | 188 const ResourceResponseHead& response_head); |
189 void OnSetDataBuffer(int request_id, | 189 void OnSetDataBuffer(int request_id, |
190 base::SharedMemoryHandle shm_handle, | 190 base::SharedMemoryHandle shm_handle, |
191 int shm_size, | 191 int shm_size, |
192 base::ProcessId renderer_pid); | 192 base::ProcessId renderer_pid); |
193 // TODO(erikchen): This dummy variable is temporary and is only intended to be | |
194 // present for one Canary release. http://crbug.com/527588. | |
195 void OnReceivedData(int request_id, | 193 void OnReceivedData(int request_id, |
196 int /* dummy variable */, | |
197 int data_offset, | 194 int data_offset, |
198 int data_length, | 195 int data_length, |
199 int encoded_data_length); | 196 int encoded_data_length); |
200 void OnDownloadedData(int request_id, int data_len, int encoded_data_length); | 197 void OnDownloadedData(int request_id, int data_len, int encoded_data_length); |
201 void OnRequestComplete( | 198 void OnRequestComplete( |
202 int request_id, | 199 int request_id, |
203 const ResourceMsg_RequestCompleteData& request_complete_data); | 200 const ResourceMsg_RequestCompleteData& request_complete_data); |
204 | 201 |
205 // Dispatch the message to one of the message response handlers. | 202 // Dispatch the message to one of the message response handlers. |
206 void DispatchMessage(const IPC::Message& message); | 203 void DispatchMessage(const IPC::Message& message); |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
254 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_; | 251 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_; |
255 | 252 |
256 base::WeakPtrFactory<ResourceDispatcher> weak_factory_; | 253 base::WeakPtrFactory<ResourceDispatcher> weak_factory_; |
257 | 254 |
258 DISALLOW_COPY_AND_ASSIGN(ResourceDispatcher); | 255 DISALLOW_COPY_AND_ASSIGN(ResourceDispatcher); |
259 }; | 256 }; |
260 | 257 |
261 } // namespace content | 258 } // namespace content |
262 | 259 |
263 #endif // CONTENT_CHILD_RESOURCE_DISPATCHER_H_ | 260 #endif // CONTENT_CHILD_RESOURCE_DISPATCHER_H_ |
OLD | NEW |