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

Side by Side Diff: content/common/resource_messages.h

Issue 398903002: Plumb redirect info out of net, through content, and into child processes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: darin comments Created 6 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « content/child/web_url_loader_impl_unittest.cc ('k') | content/public/child/request_peer.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 // IPC messages for resource loading. 5 // IPC messages for resource loading.
6 // 6 //
7 // NOTE: All messages must send an |int request_id| as their first parameter. 7 // NOTE: All messages must send an |int request_id| as their first parameter.
8 8
9 // Multiply-included message file, hence no include guard. 9 // Multiply-included message file, hence no include guard.
10 #include "base/memory/shared_memory.h" 10 #include "base/memory/shared_memory.h"
11 #include "base/process/process.h" 11 #include "base/process/process.h"
12 #include "content/common/content_param_traits_macros.h" 12 #include "content/common/content_param_traits_macros.h"
13 #include "content/common/resource_request_body.h" 13 #include "content/common/resource_request_body.h"
14 #include "content/public/common/common_param_traits.h" 14 #include "content/public/common/common_param_traits.h"
15 #include "content/public/common/resource_response.h" 15 #include "content/public/common/resource_response.h"
16 #include "ipc/ipc_message_macros.h" 16 #include "ipc/ipc_message_macros.h"
17 #include "net/base/request_priority.h" 17 #include "net/base/request_priority.h"
18 #include "net/http/http_response_info.h" 18 #include "net/http/http_response_info.h"
19 #include "net/url_request/redirect_info.h"
19 20
20 #ifndef CONTENT_COMMON_RESOURCE_MESSAGES_H_ 21 #ifndef CONTENT_COMMON_RESOURCE_MESSAGES_H_
21 #define CONTENT_COMMON_RESOURCE_MESSAGES_H_ 22 #define CONTENT_COMMON_RESOURCE_MESSAGES_H_
22 23
23 namespace net { 24 namespace net {
24 struct LoadTimingInfo; 25 struct LoadTimingInfo;
25 } 26 }
26 27
27 namespace content { 28 namespace content {
28 struct ResourceDevToolsInfo; 29 struct ResourceDevToolsInfo;
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 IPC_STRUCT_TRAITS_MEMBER(was_npn_negotiated) 115 IPC_STRUCT_TRAITS_MEMBER(was_npn_negotiated)
115 IPC_STRUCT_TRAITS_MEMBER(was_alternate_protocol_available) 116 IPC_STRUCT_TRAITS_MEMBER(was_alternate_protocol_available)
116 IPC_STRUCT_TRAITS_MEMBER(connection_info) 117 IPC_STRUCT_TRAITS_MEMBER(connection_info)
117 IPC_STRUCT_TRAITS_MEMBER(was_fetched_via_proxy) 118 IPC_STRUCT_TRAITS_MEMBER(was_fetched_via_proxy)
118 IPC_STRUCT_TRAITS_MEMBER(npn_negotiated_protocol) 119 IPC_STRUCT_TRAITS_MEMBER(npn_negotiated_protocol)
119 IPC_STRUCT_TRAITS_MEMBER(socket_address) 120 IPC_STRUCT_TRAITS_MEMBER(socket_address)
120 IPC_STRUCT_TRAITS_MEMBER(was_fetched_via_service_worker) 121 IPC_STRUCT_TRAITS_MEMBER(was_fetched_via_service_worker)
121 IPC_STRUCT_TRAITS_MEMBER(original_url_via_service_worker) 122 IPC_STRUCT_TRAITS_MEMBER(original_url_via_service_worker)
122 IPC_STRUCT_TRAITS_END() 123 IPC_STRUCT_TRAITS_END()
123 124
125 IPC_STRUCT_TRAITS_BEGIN(net::RedirectInfo)
126 IPC_STRUCT_TRAITS_MEMBER(status_code)
127 IPC_STRUCT_TRAITS_MEMBER(new_method)
128 IPC_STRUCT_TRAITS_MEMBER(new_url)
129 IPC_STRUCT_TRAITS_MEMBER(new_first_party_for_cookies)
130 IPC_STRUCT_TRAITS_MEMBER(new_referrer)
131 IPC_STRUCT_TRAITS_END()
132
124 // Parameters for a resource request. 133 // Parameters for a resource request.
125 IPC_STRUCT_BEGIN(ResourceHostMsg_Request) 134 IPC_STRUCT_BEGIN(ResourceHostMsg_Request)
126 // The request method: GET, POST, etc. 135 // The request method: GET, POST, etc.
127 IPC_STRUCT_MEMBER(std::string, method) 136 IPC_STRUCT_MEMBER(std::string, method)
128 137
129 // The requested URL. 138 // The requested URL.
130 IPC_STRUCT_MEMBER(GURL, url) 139 IPC_STRUCT_MEMBER(GURL, url)
131 140
132 // Usually the URL of the document in the top-level window, which may be 141 // Usually the URL of the document in the top-level window, which may be
133 // checked by the third-party cookie blocking policy. Leaving it empty may 142 // checked by the third-party cookie blocking policy. Leaving it empty may
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
253 262
254 // Sent as upload progress is being made. 263 // Sent as upload progress is being made.
255 IPC_MESSAGE_CONTROL3(ResourceMsg_UploadProgress, 264 IPC_MESSAGE_CONTROL3(ResourceMsg_UploadProgress,
256 int /* request_id */, 265 int /* request_id */,
257 int64 /* position */, 266 int64 /* position */,
258 int64 /* size */) 267 int64 /* size */)
259 268
260 // Sent when the request has been redirected. The receiver is expected to 269 // Sent when the request has been redirected. The receiver is expected to
261 // respond with either a FollowRedirect message (if the redirect is to be 270 // respond with either a FollowRedirect message (if the redirect is to be
262 // followed) or a CancelRequest message (if it should not be followed). 271 // followed) or a CancelRequest message (if it should not be followed).
263 IPC_MESSAGE_CONTROL4(ResourceMsg_ReceivedRedirect, 272 IPC_MESSAGE_CONTROL3(ResourceMsg_ReceivedRedirect,
264 int /* request_id */, 273 int /* request_id */,
265 GURL /* new_url */, 274 net::RedirectInfo /* redirect_info */,
266 GURL /* new_first_party_for_cookies */,
267 content::ResourceResponseHead) 275 content::ResourceResponseHead)
268 276
269 // Sent to set the shared memory buffer to be used to transmit response data to 277 // Sent to set the shared memory buffer to be used to transmit response data to
270 // the renderer. Subsequent DataReceived messages refer to byte ranges in the 278 // the renderer. Subsequent DataReceived messages refer to byte ranges in the
271 // shared memory buffer. The shared memory buffer should be retained by the 279 // shared memory buffer. The shared memory buffer should be retained by the
272 // renderer until the resource request completes. 280 // renderer until the resource request completes.
273 // 281 //
274 // NOTE: The shared memory handle should already be mapped into the process 282 // NOTE: The shared memory handle should already be mapped into the process
275 // that receives this message. 283 // that receives this message.
276 // 284 //
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
344 352
345 // Sent when the renderer process deletes a resource loader. 353 // Sent when the renderer process deletes a resource loader.
346 IPC_MESSAGE_CONTROL1(ResourceHostMsg_ReleaseDownloadedFile, 354 IPC_MESSAGE_CONTROL1(ResourceHostMsg_ReleaseDownloadedFile,
347 int /* request_id */) 355 int /* request_id */)
348 356
349 // Sent by the renderer when a resource request changes priority. 357 // Sent by the renderer when a resource request changes priority.
350 IPC_MESSAGE_CONTROL3(ResourceHostMsg_DidChangePriority, 358 IPC_MESSAGE_CONTROL3(ResourceHostMsg_DidChangePriority,
351 int /* request_id */, 359 int /* request_id */,
352 net::RequestPriority, 360 net::RequestPriority,
353 int /* intra_priority_value */) 361 int /* intra_priority_value */)
OLDNEW
« no previous file with comments | « content/child/web_url_loader_impl_unittest.cc ('k') | content/public/child/request_peer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698