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

Side by Side Diff: content/browser/loader/resource_request_info_impl.h

Issue 2038813003: Making ResourceRequestBody part of //content's public API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebasing... Created 4 years, 6 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
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 #ifndef CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_ 5 #ifndef CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_
6 #define CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_ 6 #define CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 10
11 #include "base/gtest_prod_util.h" 11 #include "base/gtest_prod_util.h"
12 #include "base/macros.h" 12 #include "base/macros.h"
13 #include "base/memory/ref_counted.h" 13 #include "base/memory/ref_counted.h"
14 #include "base/memory/weak_ptr.h" 14 #include "base/memory/weak_ptr.h"
15 #include "base/supports_user_data.h" 15 #include "base/supports_user_data.h"
16 #include "content/common/resource_request_body.h" 16 #include "content/common/resource_request_body_impl.h"
17 #include "content/public/browser/resource_request_info.h" 17 #include "content/public/browser/resource_request_info.h"
18 #include "content/public/common/referrer.h" 18 #include "content/public/common/referrer.h"
19 #include "content/public/common/resource_type.h" 19 #include "content/public/common/resource_type.h"
20 #include "net/base/load_states.h" 20 #include "net/base/load_states.h"
21 21
22 namespace content { 22 namespace content {
23 class CrossSiteResourceHandler; 23 class CrossSiteResourceHandler;
24 class DetachableResourceHandler; 24 class DetachableResourceHandler;
25 class ResourceContext; 25 class ResourceContext;
26 class ResourceMessageFilter; 26 class ResourceMessageFilter;
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 bool enable_upload_progress, 61 bool enable_upload_progress,
62 bool do_not_prompt_for_login, 62 bool do_not_prompt_for_login,
63 blink::WebReferrerPolicy referrer_policy, 63 blink::WebReferrerPolicy referrer_policy,
64 blink::WebPageVisibilityState visibility_state, 64 blink::WebPageVisibilityState visibility_state,
65 ResourceContext* context, 65 ResourceContext* context,
66 base::WeakPtr<ResourceMessageFilter> filter, 66 base::WeakPtr<ResourceMessageFilter> filter,
67 bool report_raw_headers, 67 bool report_raw_headers,
68 bool is_async, 68 bool is_async,
69 bool is_using_lofi, 69 bool is_using_lofi,
70 const std::string& original_headers, 70 const std::string& original_headers,
71 const scoped_refptr<ResourceRequestBody> body); 71 const scoped_refptr<ResourceRequestBodyImpl> body);
72 ~ResourceRequestInfoImpl() override; 72 ~ResourceRequestInfoImpl() override;
73 73
74 // ResourceRequestInfo implementation: 74 // ResourceRequestInfo implementation:
75 WebContentsGetter GetWebContentsGetterForRequest() const override; 75 WebContentsGetter GetWebContentsGetterForRequest() const override;
76 ResourceContext* GetContext() const override; 76 ResourceContext* GetContext() const override;
77 int GetChildID() const override; 77 int GetChildID() const override;
78 int GetRouteID() const override; 78 int GetRouteID() const override;
79 int GetOriginPID() const override; 79 int GetOriginPID() const override;
80 int GetRenderFrameID() const override; 80 int GetRenderFrameID() const override;
81 bool IsMainFrame() const override; 81 bool IsMainFrame() const override;
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 bool is_load_timing_enabled() const { return enable_load_timing_; } 179 bool is_load_timing_enabled() const { return enable_load_timing_; }
180 180
181 bool is_upload_progress_enabled() const { return enable_upload_progress_; } 181 bool is_upload_progress_enabled() const { return enable_upload_progress_; }
182 182
183 bool do_not_prompt_for_login() const { return do_not_prompt_for_login_; } 183 bool do_not_prompt_for_login() const { return do_not_prompt_for_login_; }
184 void set_do_not_prompt_for_login(bool do_not_prompt) { 184 void set_do_not_prompt_for_login(bool do_not_prompt) {
185 do_not_prompt_for_login_ = do_not_prompt; 185 do_not_prompt_for_login_ = do_not_prompt;
186 } 186 }
187 const std::string& original_headers() const { return original_headers_; } 187 const std::string& original_headers() const { return original_headers_; }
188 188
189 const scoped_refptr<ResourceRequestBody>& body() const { return body_; } 189 const scoped_refptr<ResourceRequestBodyImpl>& body() const { return body_; }
190 void ResetBody(); 190 void ResetBody();
191 191
192 private: 192 private:
193 FRIEND_TEST_ALL_PREFIXES(ResourceDispatcherHostTest, 193 FRIEND_TEST_ALL_PREFIXES(ResourceDispatcherHostTest,
194 DeletedFilterDetached); 194 DeletedFilterDetached);
195 FRIEND_TEST_ALL_PREFIXES(ResourceDispatcherHostTest, 195 FRIEND_TEST_ALL_PREFIXES(ResourceDispatcherHostTest,
196 DeletedFilterDetachedRedirect); 196 DeletedFilterDetachedRedirect);
197 // Non-owning, may be NULL. 197 // Non-owning, may be NULL.
198 CrossSiteResourceHandler* cross_site_handler_; 198 CrossSiteResourceHandler* cross_site_handler_;
199 DetachableResourceHandler* detachable_handler_; 199 DetachableResourceHandler* detachable_handler_;
(...skipping 23 matching lines...) Expand all
223 blink::WebReferrerPolicy referrer_policy_; 223 blink::WebReferrerPolicy referrer_policy_;
224 blink::WebPageVisibilityState visibility_state_; 224 blink::WebPageVisibilityState visibility_state_;
225 ResourceContext* context_; 225 ResourceContext* context_;
226 // The filter might be deleted without deleting this object if the process 226 // The filter might be deleted without deleting this object if the process
227 // exits during a transfer. 227 // exits during a transfer.
228 base::WeakPtr<ResourceMessageFilter> filter_; 228 base::WeakPtr<ResourceMessageFilter> filter_;
229 bool report_raw_headers_; 229 bool report_raw_headers_;
230 bool is_async_; 230 bool is_async_;
231 bool is_using_lofi_; 231 bool is_using_lofi_;
232 const std::string original_headers_; 232 const std::string original_headers_;
233 scoped_refptr<ResourceRequestBody> body_; 233 scoped_refptr<ResourceRequestBodyImpl> body_;
234 234
235 DISALLOW_COPY_AND_ASSIGN(ResourceRequestInfoImpl); 235 DISALLOW_COPY_AND_ASSIGN(ResourceRequestInfoImpl);
236 }; 236 };
237 237
238 } // namespace content 238 } // namespace content
239 239
240 #endif // CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_ 240 #endif // CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_
OLDNEW
« no previous file with comments | « content/browser/loader/resource_dispatcher_host_impl.cc ('k') | content/browser/loader/resource_request_info_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698