Chromium Code Reviews| Index: third_party/WebKit/Source/platform/network/ResourceRequest.h |
| diff --git a/third_party/WebKit/Source/platform/network/ResourceRequest.h b/third_party/WebKit/Source/platform/network/ResourceRequest.h |
| index a43f60754a60f58a79bbd1ccf70706b6f0bdfd83..027ec55de165d2c3645e65294d17cc9b01c356b8 100644 |
| --- a/third_party/WebKit/Source/platform/network/ResourceRequest.h |
| +++ b/third_party/WebKit/Source/platform/network/ResourceRequest.h |
| @@ -33,11 +33,13 @@ |
| #include "platform/network/HTTPHeaderMap.h" |
| #include "platform/network/HTTPParsers.h" |
| #include "platform/network/ResourceLoadPriority.h" |
| +#include "platform/network/ResourceResponse.h" |
| #include "platform/weborigin/KURL.h" |
| #include "platform/weborigin/Referrer.h" |
| #include "platform/weborigin/SecurityOrigin.h" |
| #include "public/platform/WebAddressSpace.h" |
| #include "public/platform/WebURLRequest.h" |
| +#include "public/platform/WebURLResponse.h" |
| #include "wtf/RefCounted.h" |
| #include <memory> |
| @@ -89,6 +91,8 @@ public: |
| const KURL& url() const; |
| void setURL(const KURL& url); |
| + const KURL& initialUrl() const; |
| + |
| void removeCredentials(); |
| WebCachePolicy getCachePolicy() const; |
| @@ -237,6 +241,14 @@ public: |
| void setRedirectStatus(RedirectStatus status) { m_redirectStatus = status; } |
| RedirectStatus redirectStatus() const { return m_redirectStatus; } |
| + // Inform the request of previous navigations in the redirect chain that |
| + // happened outside of blink. |
| + void appendPreviousResponse(const WebURLResponse&); |
| + const std::vector<WebURLResponse>& previousResponses() const { return m_responses; } |
|
Nate Chapin
2016/09/06 22:03:42
Conceptually, it seems like previousResponses() sh
arthursonzogni
2016/09/08 13:01:09
I like the idea. There was no reason except it was
|
| + |
| + void setPreviousNavigationStart(double); |
| + double previousNavigationStart() const { return m_navigationStart; } |
| + |
| private: |
| void initialize(const KURL&); |
| @@ -283,6 +295,9 @@ private: |
| static double s_defaultTimeoutInterval; |
| RedirectStatus m_redirectStatus; |
| + |
| + std::vector<WebURLResponse> m_responses; |
|
Nate Chapin
2016/09/06 22:03:42
Here and elsewhere in this file: why WebURLRespons
arthursonzogni
2016/09/08 13:01:09
I will take care of doing this properly.
|
| + double m_navigationStart = 0; |
| }; |
| struct CrossThreadResourceRequestData { |
| @@ -325,6 +340,8 @@ public: |
| bool m_isExternalRequest; |
| InputToLoadPerfMetricReportPolicy m_inputPerfMetricReportPolicy; |
| ResourceRequest::RedirectStatus m_redirectStatus; |
| + std::vector<std::unique_ptr<CrossThreadResourceResponseData>> m_responses; |
|
Nate Chapin
2016/09/06 22:03:42
m_responses should only ever be populated for a ma
arthursonzogni
2016/09/08 13:01:09
You are right.
I was not aware of the use of this
|
| + double m_navigationStart = 0; |
| }; |
| } // namespace blink |