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 #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 <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 CONTENT_EXPORT ResourceRequestInfoImpl( | 42 CONTENT_EXPORT ResourceRequestInfoImpl( |
43 int process_type, | 43 int process_type, |
44 int child_id, | 44 int child_id, |
45 int route_id, | 45 int route_id, |
46 int frame_tree_node_id, | 46 int frame_tree_node_id, |
47 int origin_pid, | 47 int origin_pid, |
48 int request_id, | 48 int request_id, |
49 int render_frame_id, | 49 int render_frame_id, |
50 bool is_main_frame, | 50 bool is_main_frame, |
51 bool parent_is_main_frame, | 51 bool parent_is_main_frame, |
52 int parent_render_frame_id, | |
53 ResourceType resource_type, | 52 ResourceType resource_type, |
54 ui::PageTransition transition_type, | 53 ui::PageTransition transition_type, |
55 bool should_replace_current_entry, | 54 bool should_replace_current_entry, |
56 bool is_download, | 55 bool is_download, |
57 bool is_stream, | 56 bool is_stream, |
58 bool allow_download, | 57 bool allow_download, |
59 bool has_user_gesture, | 58 bool has_user_gesture, |
60 bool enable_load_timing, | 59 bool enable_load_timing, |
61 bool enable_upload_progress, | 60 bool enable_upload_progress, |
62 bool do_not_prompt_for_login, | 61 bool do_not_prompt_for_login, |
63 blink::WebReferrerPolicy referrer_policy, | 62 blink::WebReferrerPolicy referrer_policy, |
64 blink::WebPageVisibilityState visibility_state, | 63 blink::WebPageVisibilityState visibility_state, |
65 ResourceContext* context, | 64 ResourceContext* context, |
66 base::WeakPtr<ResourceMessageFilter> filter, | 65 base::WeakPtr<ResourceMessageFilter> filter, |
67 bool report_raw_headers, | 66 bool report_raw_headers, |
68 bool is_async, | 67 bool is_async, |
69 bool is_using_lofi); | 68 bool is_using_lofi); |
70 ~ResourceRequestInfoImpl() override; | 69 ~ResourceRequestInfoImpl() override; |
71 | 70 |
72 // ResourceRequestInfo implementation: | 71 // ResourceRequestInfo implementation: |
73 WebContentsGetter GetWebContentsGetterForRequest() const override; | 72 WebContentsGetter GetWebContentsGetterForRequest() const override; |
74 ResourceContext* GetContext() const override; | 73 ResourceContext* GetContext() const override; |
75 int GetChildID() const override; | 74 int GetChildID() const override; |
76 int GetRouteID() const override; | 75 int GetRouteID() const override; |
77 int GetOriginPID() const override; | 76 int GetOriginPID() const override; |
78 int GetRenderFrameID() const override; | 77 int GetRenderFrameID() const override; |
79 bool IsMainFrame() const override; | 78 bool IsMainFrame() const override; |
80 bool ParentIsMainFrame() const override; | 79 bool ParentIsMainFrame() const override; |
81 int GetParentRenderFrameID() const override; | |
82 ResourceType GetResourceType() const override; | 80 ResourceType GetResourceType() const override; |
83 int GetProcessType() const override; | 81 int GetProcessType() const override; |
84 blink::WebReferrerPolicy GetReferrerPolicy() const override; | 82 blink::WebReferrerPolicy GetReferrerPolicy() const override; |
85 blink::WebPageVisibilityState GetVisibilityState() const override; | 83 blink::WebPageVisibilityState GetVisibilityState() const override; |
86 ui::PageTransition GetPageTransition() const override; | 84 ui::PageTransition GetPageTransition() const override; |
87 bool HasUserGesture() const override; | 85 bool HasUserGesture() const override; |
88 bool WasIgnoredByHandler() const override; | 86 bool WasIgnoredByHandler() const override; |
89 bool GetAssociatedRenderFrame(int* render_process_id, | 87 bool GetAssociatedRenderFrame(int* render_process_id, |
90 int* render_frame_id) const override; | 88 int* render_frame_id) const override; |
91 bool IsAsync() const override; | 89 bool IsAsync() const override; |
(...skipping 18 matching lines...) Expand all Loading... |
110 } | 108 } |
111 | 109 |
112 // Updates the data associated with this request after it is is transferred | 110 // Updates the data associated with this request after it is is transferred |
113 // to a new renderer process. Not all data will change during a transfer. | 111 // to a new renderer process. Not all data will change during a transfer. |
114 // We do not expect the ResourceContext to change during navigation, so that | 112 // We do not expect the ResourceContext to change during navigation, so that |
115 // does not need to be updated. | 113 // does not need to be updated. |
116 void UpdateForTransfer(int child_id, | 114 void UpdateForTransfer(int child_id, |
117 int route_id, | 115 int route_id, |
118 int origin_pid, | 116 int origin_pid, |
119 int request_id, | 117 int request_id, |
120 int parent_render_frame_id, | |
121 base::WeakPtr<ResourceMessageFilter> filter); | 118 base::WeakPtr<ResourceMessageFilter> filter); |
122 | 119 |
123 // CrossSiteResourceHandler for this request. May be null. | 120 // CrossSiteResourceHandler for this request. May be null. |
124 CrossSiteResourceHandler* cross_site_handler() { | 121 CrossSiteResourceHandler* cross_site_handler() { |
125 return cross_site_handler_; | 122 return cross_site_handler_; |
126 } | 123 } |
127 void set_cross_site_handler(CrossSiteResourceHandler* h) { | 124 void set_cross_site_handler(CrossSiteResourceHandler* h) { |
128 cross_site_handler_ = h; | 125 cross_site_handler_ = h; |
129 } | 126 } |
130 | 127 |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
195 | 192 |
196 int process_type_; | 193 int process_type_; |
197 int child_id_; | 194 int child_id_; |
198 int route_id_; | 195 int route_id_; |
199 const int frame_tree_node_id_; | 196 const int frame_tree_node_id_; |
200 int origin_pid_; | 197 int origin_pid_; |
201 int request_id_; | 198 int request_id_; |
202 int render_frame_id_; | 199 int render_frame_id_; |
203 bool is_main_frame_; | 200 bool is_main_frame_; |
204 bool parent_is_main_frame_; | 201 bool parent_is_main_frame_; |
205 int parent_render_frame_id_; | |
206 bool should_replace_current_entry_; | 202 bool should_replace_current_entry_; |
207 bool is_download_; | 203 bool is_download_; |
208 bool is_stream_; | 204 bool is_stream_; |
209 bool allow_download_; | 205 bool allow_download_; |
210 bool has_user_gesture_; | 206 bool has_user_gesture_; |
211 bool enable_load_timing_; | 207 bool enable_load_timing_; |
212 bool enable_upload_progress_; | 208 bool enable_upload_progress_; |
213 bool do_not_prompt_for_login_; | 209 bool do_not_prompt_for_login_; |
214 bool was_ignored_by_handler_; | 210 bool was_ignored_by_handler_; |
215 bool counted_as_in_flight_request_; | 211 bool counted_as_in_flight_request_; |
216 ResourceType resource_type_; | 212 ResourceType resource_type_; |
217 ui::PageTransition transition_type_; | 213 ui::PageTransition transition_type_; |
218 int memory_cost_; | 214 int memory_cost_; |
219 blink::WebReferrerPolicy referrer_policy_; | 215 blink::WebReferrerPolicy referrer_policy_; |
220 blink::WebPageVisibilityState visibility_state_; | 216 blink::WebPageVisibilityState visibility_state_; |
221 ResourceContext* context_; | 217 ResourceContext* context_; |
222 // The filter might be deleted without deleting this object if the process | 218 // The filter might be deleted without deleting this object if the process |
223 // exits during a transfer. | 219 // exits during a transfer. |
224 base::WeakPtr<ResourceMessageFilter> filter_; | 220 base::WeakPtr<ResourceMessageFilter> filter_; |
225 bool report_raw_headers_; | 221 bool report_raw_headers_; |
226 bool is_async_; | 222 bool is_async_; |
227 bool is_using_lofi_; | 223 bool is_using_lofi_; |
228 | 224 |
229 DISALLOW_COPY_AND_ASSIGN(ResourceRequestInfoImpl); | 225 DISALLOW_COPY_AND_ASSIGN(ResourceRequestInfoImpl); |
230 }; | 226 }; |
231 | 227 |
232 } // namespace content | 228 } // namespace content |
233 | 229 |
234 #endif // CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_ | 230 #endif // CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_ |
OLD | NEW |