OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_JOB_H_ | 5 #ifndef NET_URL_REQUEST_URL_REQUEST_JOB_H_ |
6 #define NET_URL_REQUEST_URL_REQUEST_JOB_H_ | 6 #define NET_URL_REQUEST_URL_REQUEST_JOB_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 12 matching lines...) Expand all Loading... |
23 | 23 |
24 namespace net { | 24 namespace net { |
25 | 25 |
26 class AuthChallengeInfo; | 26 class AuthChallengeInfo; |
27 class CookieList; | 27 class CookieList; |
28 class CookieOptions; | 28 class CookieOptions; |
29 class HttpRequestHeaders; | 29 class HttpRequestHeaders; |
30 class HttpResponseInfo; | 30 class HttpResponseInfo; |
31 class IOBuffer; | 31 class IOBuffer; |
32 class SSLCertRequestInfo; | 32 class SSLCertRequestInfo; |
| 33 class SSLInfo; |
33 class URLRequest; | 34 class URLRequest; |
34 class UploadData; | 35 class UploadData; |
35 class URLRequestStatus; | 36 class URLRequestStatus; |
36 class X509Certificate; | 37 class X509Certificate; |
37 | 38 |
38 class NET_EXPORT URLRequestJob : public base::RefCounted<URLRequestJob>, | 39 class NET_EXPORT URLRequestJob : public base::RefCounted<URLRequestJob>, |
39 public base::SystemMonitor::PowerObserver { | 40 public base::SystemMonitor::PowerObserver { |
40 public: | 41 public: |
41 explicit URLRequestJob(URLRequest* request); | 42 explicit URLRequestJob(URLRequest* request); |
42 | 43 |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 virtual void OnSuspend(); | 191 virtual void OnSuspend(); |
191 | 192 |
192 protected: | 193 protected: |
193 friend class base::RefCounted<URLRequestJob>; | 194 friend class base::RefCounted<URLRequestJob>; |
194 virtual ~URLRequestJob(); | 195 virtual ~URLRequestJob(); |
195 | 196 |
196 // Notifies the job that a certificate is requested. | 197 // Notifies the job that a certificate is requested. |
197 void NotifyCertificateRequested(SSLCertRequestInfo* cert_request_info); | 198 void NotifyCertificateRequested(SSLCertRequestInfo* cert_request_info); |
198 | 199 |
199 // Notifies the job about an SSL certificate error. | 200 // Notifies the job about an SSL certificate error. |
200 void NotifySSLCertificateError(int cert_error, X509Certificate* cert); | 201 void NotifySSLCertificateError(const SSLInfo& ssl_info, |
| 202 bool is_hsts_host); |
201 | 203 |
202 // Delegates to URLRequest::Delegate. | 204 // Delegates to URLRequest::Delegate. |
203 bool CanGetCookies(const CookieList& cookie_list) const; | 205 bool CanGetCookies(const CookieList& cookie_list) const; |
204 | 206 |
205 // Delegates to URLRequest::Delegate. | 207 // Delegates to URLRequest::Delegate. |
206 bool CanSetCookie(const std::string& cookie_line, | 208 bool CanSetCookie(const std::string& cookie_line, |
207 CookieOptions* options) const; | 209 CookieOptions* options) const; |
208 | 210 |
209 // Notifies the job that headers have been received. | 211 // Notifies the job that headers have been received. |
210 void NotifyHeadersComplete(); | 212 void NotifyHeadersComplete(); |
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
367 int deferred_redirect_status_code_; | 369 int deferred_redirect_status_code_; |
368 | 370 |
369 ScopedRunnableMethodFactory<URLRequestJob> method_factory_; | 371 ScopedRunnableMethodFactory<URLRequestJob> method_factory_; |
370 | 372 |
371 DISALLOW_COPY_AND_ASSIGN(URLRequestJob); | 373 DISALLOW_COPY_AND_ASSIGN(URLRequestJob); |
372 }; | 374 }; |
373 | 375 |
374 } // namespace net | 376 } // namespace net |
375 | 377 |
376 #endif // NET_URL_REQUEST_URL_REQUEST_JOB_H_ | 378 #endif // NET_URL_REQUEST_URL_REQUEST_JOB_H_ |
OLD | NEW |