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 // This file declares a HttpTransactionFactory implementation that can be | 5 // This file declares a HttpTransactionFactory implementation that can be |
6 // layered on top of another HttpTransactionFactory to add HTTP caching. The | 6 // layered on top of another HttpTransactionFactory to add HTTP caching. The |
7 // caching logic follows RFC 2616 (any exceptions are called out in the code). | 7 // caching logic follows RFC 2616 (any exceptions are called out in the code). |
8 // | 8 // |
9 // The HttpCache takes a disk_cache::Backend as a parameter, and uses that for | 9 // The HttpCache takes a disk_cache::Backend as a parameter, and uses that for |
10 // the cache storage. | 10 // the cache storage. |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 namespace net { | 44 namespace net { |
45 | 45 |
46 class CertVerifier; | 46 class CertVerifier; |
47 class DnsCertProvenanceChecker; | 47 class DnsCertProvenanceChecker; |
48 class DnsRRResolver; | 48 class DnsRRResolver; |
49 class HostResolver; | 49 class HostResolver; |
50 class HttpAuthHandlerFactory; | 50 class HttpAuthHandlerFactory; |
51 class HttpNetworkSession; | 51 class HttpNetworkSession; |
52 struct HttpRequestInfo; | 52 struct HttpRequestInfo; |
53 class HttpResponseInfo; | 53 class HttpResponseInfo; |
| 54 class HttpServerProperties; |
54 class IOBuffer; | 55 class IOBuffer; |
55 class NetLog; | 56 class NetLog; |
56 class NetworkDelegate; | 57 class NetworkDelegate; |
57 class OriginBoundCertService; | 58 class OriginBoundCertService; |
58 class ProxyService; | 59 class ProxyService; |
59 class SSLConfigService; | 60 class SSLConfigService; |
60 class ViewCacheHelper; | 61 class ViewCacheHelper; |
61 | 62 |
62 class NET_EXPORT HttpCache : public HttpTransactionFactory, | 63 class NET_EXPORT HttpCache : public HttpTransactionFactory, |
63 public base::SupportsWeakPtr<HttpCache>, | 64 public base::SupportsWeakPtr<HttpCache>, |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
122 // The HttpCache takes ownership of the |backend_factory|. | 123 // The HttpCache takes ownership of the |backend_factory|. |
123 HttpCache(HostResolver* host_resolver, | 124 HttpCache(HostResolver* host_resolver, |
124 CertVerifier* cert_verifier, | 125 CertVerifier* cert_verifier, |
125 OriginBoundCertService* origin_bound_cert_service, | 126 OriginBoundCertService* origin_bound_cert_service, |
126 DnsRRResolver* dnsrr_resolver, | 127 DnsRRResolver* dnsrr_resolver, |
127 DnsCertProvenanceChecker* dns_cert_checker, | 128 DnsCertProvenanceChecker* dns_cert_checker, |
128 ProxyService* proxy_service, | 129 ProxyService* proxy_service, |
129 SSLConfigService* ssl_config_service, | 130 SSLConfigService* ssl_config_service, |
130 HttpAuthHandlerFactory* http_auth_handler_factory, | 131 HttpAuthHandlerFactory* http_auth_handler_factory, |
131 NetworkDelegate* network_delegate, | 132 NetworkDelegate* network_delegate, |
| 133 HttpServerProperties* http_server_properties, |
132 NetLog* net_log, | 134 NetLog* net_log, |
133 BackendFactory* backend_factory); | 135 BackendFactory* backend_factory); |
134 | 136 |
135 // The disk cache is initialized lazily (by CreateTransaction) in this case. | 137 // The disk cache is initialized lazily (by CreateTransaction) in this case. |
136 // Provide an existing HttpNetworkSession, the cache can construct a | 138 // Provide an existing HttpNetworkSession, the cache can construct a |
137 // network layer with a shared HttpNetworkSession in order for multiple | 139 // network layer with a shared HttpNetworkSession in order for multiple |
138 // network layers to share information (e.g. authentication data). The | 140 // network layers to share information (e.g. authentication data). The |
139 // HttpCache takes ownership of the |backend_factory|. | 141 // HttpCache takes ownership of the |backend_factory|. |
140 HttpCache(HttpNetworkSession* session, BackendFactory* backend_factory); | 142 HttpCache(HttpNetworkSession* session, BackendFactory* backend_factory); |
141 | 143 |
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
382 ScopedRunnableMethodFactory<HttpCache> task_factory_; | 384 ScopedRunnableMethodFactory<HttpCache> task_factory_; |
383 | 385 |
384 scoped_ptr<PlaybackCacheMap> playback_cache_map_; | 386 scoped_ptr<PlaybackCacheMap> playback_cache_map_; |
385 | 387 |
386 DISALLOW_COPY_AND_ASSIGN(HttpCache); | 388 DISALLOW_COPY_AND_ASSIGN(HttpCache); |
387 }; | 389 }; |
388 | 390 |
389 } // namespace net | 391 } // namespace net |
390 | 392 |
391 #endif // NET_HTTP_HTTP_CACHE_H_ | 393 #endif // NET_HTTP_HTTP_CACHE_H_ |
OLD | NEW |