| 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 // This class represents contextual information (cookies, cache, etc.) | 5 // This class represents contextual information (cookies, cache, etc.) |
| 6 // that's useful when processing resource requests. | 6 // that's useful when processing resource requests. |
| 7 // The class is reference-counted so that it can be cleaned up after any | 7 // The class is reference-counted so that it can be cleaned up after any |
| 8 // requests that are using it have been completed. | 8 // requests that are using it have been completed. |
| 9 | 9 |
| 10 #ifndef NET_URL_REQUEST_URL_REQUEST_CONTEXT_H_ | 10 #ifndef NET_URL_REQUEST_URL_REQUEST_CONTEXT_H_ |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 130 void set_http_transaction_factory(HttpTransactionFactory* factory) { | 130 void set_http_transaction_factory(HttpTransactionFactory* factory) { |
| 131 http_transaction_factory_ = factory; | 131 http_transaction_factory_ = factory; |
| 132 } | 132 } |
| 133 | 133 |
| 134 void set_network_delegate(NetworkDelegate* network_delegate) { | 134 void set_network_delegate(NetworkDelegate* network_delegate) { |
| 135 network_delegate_ = network_delegate; | 135 network_delegate_ = network_delegate; |
| 136 } | 136 } |
| 137 NetworkDelegate* network_delegate() const { return network_delegate_; } | 137 NetworkDelegate* network_delegate() const { return network_delegate_; } |
| 138 | 138 |
| 139 void set_http_server_properties( | 139 void set_http_server_properties( |
| 140 const base::WeakPtr<HttpServerProperties>& http_server_properties) { | 140 HttpServerProperties* http_server_properties) { |
| 141 http_server_properties_ = http_server_properties; | 141 http_server_properties_ = http_server_properties; |
| 142 } | 142 } |
| 143 base::WeakPtr<HttpServerProperties> http_server_properties() const { | 143 HttpServerProperties* http_server_properties() const { |
| 144 return http_server_properties_; | 144 return http_server_properties_; |
| 145 } | 145 } |
| 146 | 146 |
| 147 // Gets the cookie store for this context (may be null, in which case | 147 // Gets the cookie store for this context (may be null, in which case |
| 148 // cookies are not stored). | 148 // cookies are not stored). |
| 149 CookieStore* cookie_store() const { return cookie_store_; } | 149 CookieStore* cookie_store() const { return cookie_store_; } |
| 150 void set_cookie_store(CookieStore* cookie_store); | 150 void set_cookie_store(CookieStore* cookie_store); |
| 151 | 151 |
| 152 TransportSecurityState* transport_security_state() const { | 152 TransportSecurityState* transport_security_state() const { |
| 153 return transport_security_state_; | 153 return transport_security_state_; |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 248 // Ownership for these members are not defined here. Clients should either | 248 // Ownership for these members are not defined here. Clients should either |
| 249 // provide storage elsewhere or have a subclass take ownership. | 249 // provide storage elsewhere or have a subclass take ownership. |
| 250 NetLog* net_log_; | 250 NetLog* net_log_; |
| 251 HostResolver* host_resolver_; | 251 HostResolver* host_resolver_; |
| 252 CertVerifier* cert_verifier_; | 252 CertVerifier* cert_verifier_; |
| 253 ChannelIDService* channel_id_service_; | 253 ChannelIDService* channel_id_service_; |
| 254 HttpAuthHandlerFactory* http_auth_handler_factory_; | 254 HttpAuthHandlerFactory* http_auth_handler_factory_; |
| 255 ProxyService* proxy_service_; | 255 ProxyService* proxy_service_; |
| 256 scoped_refptr<SSLConfigService> ssl_config_service_; | 256 scoped_refptr<SSLConfigService> ssl_config_service_; |
| 257 NetworkDelegate* network_delegate_; | 257 NetworkDelegate* network_delegate_; |
| 258 base::WeakPtr<HttpServerProperties> http_server_properties_; | 258 HttpServerProperties* http_server_properties_; |
| 259 HttpUserAgentSettings* http_user_agent_settings_; | 259 HttpUserAgentSettings* http_user_agent_settings_; |
| 260 CookieStore* cookie_store_; | 260 CookieStore* cookie_store_; |
| 261 TransportSecurityState* transport_security_state_; | 261 TransportSecurityState* transport_security_state_; |
| 262 CTVerifier* cert_transparency_verifier_; | 262 CTVerifier* cert_transparency_verifier_; |
| 263 HttpTransactionFactory* http_transaction_factory_; | 263 HttpTransactionFactory* http_transaction_factory_; |
| 264 const URLRequestJobFactory* job_factory_; | 264 const URLRequestJobFactory* job_factory_; |
| 265 URLRequestThrottlerManager* throttler_manager_; | 265 URLRequestThrottlerManager* throttler_manager_; |
| 266 URLRequestBackoffManager* backoff_manager_; | 266 URLRequestBackoffManager* backoff_manager_; |
| 267 SdchManager* sdch_manager_; | 267 SdchManager* sdch_manager_; |
| 268 NetworkQualityEstimator* network_quality_estimator_; | 268 NetworkQualityEstimator* network_quality_estimator_; |
| 269 | 269 |
| 270 // --------------------------------------------------------------------------- | 270 // --------------------------------------------------------------------------- |
| 271 // Important: When adding any new members below, consider whether they need to | 271 // Important: When adding any new members below, consider whether they need to |
| 272 // be added to CopyFrom. | 272 // be added to CopyFrom. |
| 273 // --------------------------------------------------------------------------- | 273 // --------------------------------------------------------------------------- |
| 274 | 274 |
| 275 std::unique_ptr<std::set<const URLRequest*>> url_requests_; | 275 std::unique_ptr<std::set<const URLRequest*>> url_requests_; |
| 276 bool has_known_mismatched_cookie_store_; | 276 bool has_known_mismatched_cookie_store_; |
| 277 | 277 |
| 278 // Enables Brotli Content-Encoding support. | 278 // Enables Brotli Content-Encoding support. |
| 279 bool enable_brotli_; | 279 bool enable_brotli_; |
| 280 | 280 |
| 281 DISALLOW_COPY_AND_ASSIGN(URLRequestContext); | 281 DISALLOW_COPY_AND_ASSIGN(URLRequestContext); |
| 282 }; | 282 }; |
| 283 | 283 |
| 284 } // namespace net | 284 } // namespace net |
| 285 | 285 |
| 286 #endif // NET_URL_REQUEST_URL_REQUEST_CONTEXT_H_ | 286 #endif // NET_URL_REQUEST_URL_REQUEST_CONTEXT_H_ |
| OLD | NEW |