Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(246)

Side by Side Diff: net/http/http_cache.h

Issue 3533013: net: plumb DnsRRResolver from IOThread to HttpNetworkSession. (Closed)
Patch Set: Created 10 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 23 matching lines...) Expand all
34 34
35 class GURL; 35 class GURL;
36 36
37 namespace disk_cache { 37 namespace disk_cache {
38 class Backend; 38 class Backend;
39 class Entry; 39 class Entry;
40 } 40 }
41 41
42 namespace net { 42 namespace net {
43 43
44 class DnsRRResolver;
44 class HostResolver; 45 class HostResolver;
45 class HttpAuthHandlerFactory; 46 class HttpAuthHandlerFactory;
46 class HttpNetworkDelegate; 47 class HttpNetworkDelegate;
47 class HttpNetworkSession; 48 class HttpNetworkSession;
48 struct HttpRequestInfo; 49 struct HttpRequestInfo;
49 class HttpResponseInfo; 50 class HttpResponseInfo;
50 class IOBuffer; 51 class IOBuffer;
51 class NetLog; 52 class NetLog;
52 class ProxyService; 53 class ProxyService;
53 class SSLConfigService; 54 class SSLConfigService;
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 private: 111 private:
111 CacheType type_; 112 CacheType type_;
112 const FilePath path_; 113 const FilePath path_;
113 int max_bytes_; 114 int max_bytes_;
114 scoped_refptr<base::MessageLoopProxy> thread_; 115 scoped_refptr<base::MessageLoopProxy> thread_;
115 }; 116 };
116 117
117 // The disk cache is initialized lazily (by CreateTransaction) in this case. 118 // The disk cache is initialized lazily (by CreateTransaction) in this case.
118 // The HttpCache takes ownership of the |backend_factory|. 119 // The HttpCache takes ownership of the |backend_factory|.
119 HttpCache(HostResolver* host_resolver, 120 HttpCache(HostResolver* host_resolver,
121 DnsRRResolver* dnsrr_resolver,
120 ProxyService* proxy_service, 122 ProxyService* proxy_service,
121 SSLConfigService* ssl_config_service, 123 SSLConfigService* ssl_config_service,
122 HttpAuthHandlerFactory* http_auth_handler_factory, 124 HttpAuthHandlerFactory* http_auth_handler_factory,
123 HttpNetworkDelegate* network_delegate, 125 HttpNetworkDelegate* network_delegate,
124 NetLog* net_log, 126 NetLog* net_log,
125 BackendFactory* backend_factory); 127 BackendFactory* backend_factory);
126 128
127 // The disk cache is initialized lazily (by CreateTransaction) in this case. 129 // The disk cache is initialized lazily (by CreateTransaction) in this case.
128 // Provide an existing HttpNetworkSession, the cache can construct a 130 // Provide an existing HttpNetworkSession, the cache can construct a
129 // network layer with a shared HttpNetworkSession in order for multiple 131 // network layer with a shared HttpNetworkSession in order for multiple
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 371
370 typedef base::hash_map<std::string, int> PlaybackCacheMap; 372 typedef base::hash_map<std::string, int> PlaybackCacheMap;
371 scoped_ptr<PlaybackCacheMap> playback_cache_map_; 373 scoped_ptr<PlaybackCacheMap> playback_cache_map_;
372 374
373 DISALLOW_COPY_AND_ASSIGN(HttpCache); 375 DISALLOW_COPY_AND_ASSIGN(HttpCache);
374 }; 376 };
375 377
376 } // namespace net 378 } // namespace net
377 379
378 #endif // NET_HTTP_HTTP_CACHE_H_ 380 #endif // NET_HTTP_HTTP_CACHE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698