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 NET_URL_REQUEST_URL_REQUEST_HTTP_JOB_H_ | 5 #ifndef NET_URL_REQUEST_URL_REQUEST_HTTP_JOB_H_ |
6 #define NET_URL_REQUEST_URL_REQUEST_HTTP_JOB_H_ | 6 #define NET_URL_REQUEST_URL_REQUEST_HTTP_JOB_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <string> | 10 #include <string> |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
72 typedef base::RefCountedData<bool> SharedBoolean; | 72 typedef base::RefCountedData<bool> SharedBoolean; |
73 | 73 |
74 class HttpFilterContext; | 74 class HttpFilterContext; |
75 | 75 |
76 // Shadows URLRequestJob's version of this method. | 76 // Shadows URLRequestJob's version of this method. |
77 void NotifyBeforeNetworkStart(bool* defer); | 77 void NotifyBeforeNetworkStart(bool* defer); |
78 | 78 |
79 // Shadows URLRequestJob's version of this method so we can grab cookies. | 79 // Shadows URLRequestJob's version of this method so we can grab cookies. |
80 void NotifyHeadersComplete(); | 80 void NotifyHeadersComplete(); |
81 | 81 |
82 // Shadows URLRequestJob's method so we can record histograms. | |
83 void NotifyDone(const URLRequestStatus& status); | |
84 | |
85 void DestroyTransaction(); | 82 void DestroyTransaction(); |
86 | 83 |
87 void AddExtraHeaders(); | 84 void AddExtraHeaders(); |
88 void AddCookieHeaderAndStart(); | 85 void AddCookieHeaderAndStart(); |
89 void SaveCookiesAndNotifyHeadersComplete(int result); | 86 void SaveCookiesAndNotifyHeadersComplete(int result); |
90 void SaveNextCookie(); | 87 void SaveNextCookie(); |
91 void FetchResponseCookies(std::vector<std::string>* cookies); | 88 void FetchResponseCookies(std::vector<std::string>* cookies); |
92 | 89 |
93 // Processes a Backoff header, if one exists. | 90 // Processes a Backoff header, if one exists. |
94 void ProcessBackoffHeader(); | 91 void ProcessBackoffHeader(); |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
126 bool CopyFragmentOnRedirect(const GURL& location) const override; | 123 bool CopyFragmentOnRedirect(const GURL& location) const override; |
127 bool IsSafeRedirect(const GURL& location) override; | 124 bool IsSafeRedirect(const GURL& location) override; |
128 bool NeedsAuth() override; | 125 bool NeedsAuth() override; |
129 void GetAuthChallengeInfo(scoped_refptr<AuthChallengeInfo>*) override; | 126 void GetAuthChallengeInfo(scoped_refptr<AuthChallengeInfo>*) override; |
130 void SetAuth(const AuthCredentials& credentials) override; | 127 void SetAuth(const AuthCredentials& credentials) override; |
131 void CancelAuth() override; | 128 void CancelAuth() override; |
132 void ContinueWithCertificate(X509Certificate* client_cert, | 129 void ContinueWithCertificate(X509Certificate* client_cert, |
133 SSLPrivateKey* client_private_key) override; | 130 SSLPrivateKey* client_private_key) override; |
134 void ContinueDespiteLastError() override; | 131 void ContinueDespiteLastError() override; |
135 void ResumeNetworkStart() override; | 132 void ResumeNetworkStart() override; |
136 bool ReadRawData(IOBuffer* buf, int buf_size, int* bytes_read) override; | 133 int ReadRawData(IOBuffer* buf, int buf_size) override; |
137 void StopCaching() override; | 134 void StopCaching() override; |
138 bool GetFullRequestHeaders(HttpRequestHeaders* headers) const override; | 135 bool GetFullRequestHeaders(HttpRequestHeaders* headers) const override; |
139 int64 GetTotalReceivedBytes() const override; | 136 int64 GetTotalReceivedBytes() const override; |
140 int64_t GetTotalSentBytes() const override; | 137 int64_t GetTotalSentBytes() const override; |
141 void DoneReading() override; | 138 void DoneReading() override; |
142 void DoneReadingRedirectResponse() override; | 139 void DoneReadingRedirectResponse() override; |
143 | 140 |
144 HostPortPair GetSocketAddress() const override; | 141 HostPortPair GetSocketAddress() const override; |
145 void NotifyURLRequestDestroyed() override; | 142 void NotifyURLRequestDestroyed() override; |
146 | 143 |
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
288 int64_t total_sent_bytes_from_previous_transactions_; | 285 int64_t total_sent_bytes_from_previous_transactions_; |
289 | 286 |
290 base::WeakPtrFactory<URLRequestHttpJob> weak_factory_; | 287 base::WeakPtrFactory<URLRequestHttpJob> weak_factory_; |
291 | 288 |
292 DISALLOW_COPY_AND_ASSIGN(URLRequestHttpJob); | 289 DISALLOW_COPY_AND_ASSIGN(URLRequestHttpJob); |
293 }; | 290 }; |
294 | 291 |
295 } // namespace net | 292 } // namespace net |
296 | 293 |
297 #endif // NET_URL_REQUEST_URL_REQUEST_HTTP_JOB_H_ | 294 #endif // NET_URL_REQUEST_URL_REQUEST_HTTP_JOB_H_ |
OLD | NEW |