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

Side by Side Diff: net/http/http_request_info.h

Issue 1604011: Use HttpRequestHeaders for extra_headers. (Closed)
Patch Set: Address eroman comments. Created 10 years, 8 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
« no previous file with comments | « net/http/http_request_headers_unittest.cc ('k') | net/http/http_stream.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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 NET_HTTP_HTTP_REQUEST_INFO_H__ 5 #ifndef NET_HTTP_HTTP_REQUEST_INFO_H__
6 #define NET_HTTP_HTTP_REQUEST_INFO_H__ 6 #define NET_HTTP_HTTP_REQUEST_INFO_H__
7 7
8 #include <string> 8 #include <string>
9 #include "base/ref_counted.h" 9 #include "base/ref_counted.h"
10 #include "googleurl/src/gurl.h" 10 #include "googleurl/src/gurl.h"
11 #include "net/base/request_priority.h" 11 #include "net/base/request_priority.h"
12 #include "net/base/upload_data.h" 12 #include "net/base/upload_data.h"
13 #include "net/http/http_request_headers.h"
13 14
14 namespace net { 15 namespace net {
15 16
16 class HttpRequestInfo { 17 struct HttpRequestInfo {
17 public: 18 public:
18 HttpRequestInfo() : load_flags(0), priority(LOWEST) { 19 HttpRequestInfo() : load_flags(0), priority(LOWEST) {
19 } 20 }
20 21
21 // The requested URL. 22 // The requested URL.
22 GURL url; 23 GURL url;
23 24
24 // The referring URL (if any). 25 // The referring URL (if any).
25 GURL referrer; 26 GURL referrer;
26 27
27 // The method to use (GET, POST, etc.). 28 // The method to use (GET, POST, etc.).
28 std::string method; 29 std::string method;
29 30
30 // The user agent string to use. TODO(darin): we should just add this to 31 // Any extra request headers (including User-Agent).
31 // extra_headers 32 HttpRequestHeaders extra_headers;
32 std::string user_agent;
33
34 // Any extra request headers (\r\n-delimited).
35 std::string extra_headers;
36 33
37 // Any upload data. 34 // Any upload data.
38 scoped_refptr<UploadData> upload_data; 35 scoped_refptr<UploadData> upload_data;
39 36
40 // Any load flags (see load_flags.h). 37 // Any load flags (see load_flags.h).
41 int load_flags; 38 int load_flags;
42 39
43 // The priority level for this request. 40 // The priority level for this request.
44 RequestPriority priority; 41 RequestPriority priority;
45 }; 42 };
46 43
47 } // namespace net 44 } // namespace net
48 45
49 #endif // NET_HTTP_HTTP_REQUEST_INFO_H__ 46 #endif // NET_HTTP_HTTP_REQUEST_INFO_H__
OLDNEW
« no previous file with comments | « net/http/http_request_headers_unittest.cc ('k') | net/http/http_stream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698