| Index: net/http/http_cache.h
|
| diff --git a/net/http/http_cache.h b/net/http/http_cache.h
|
| index 1c1338b0d75d8019b82a5964609008b58d85ae0d..fee61d81d0a0839f2a7d66ff627dfe24f659fac8 100644
|
| --- a/net/http/http_cache.h
|
| +++ b/net/http/http_cache.h
|
| @@ -37,6 +37,7 @@
|
| class GURL;
|
|
|
| namespace base {
|
| +class Clock;
|
| class SingleThreadTaskRunner;
|
| } // namespace base
|
|
|
| @@ -52,6 +53,7 @@ class ChannelIDService;
|
| class DiskBasedCertCache;
|
| class HostResolver;
|
| class HttpAuthHandlerFactory;
|
| +class HttpCachePrefetchValidationTest;
|
| class HttpNetworkSession;
|
| class HttpResponseInfo;
|
| class HttpServerProperties;
|
| @@ -247,6 +249,7 @@ class NET_EXPORT HttpCache : public HttpTransactionFactory,
|
| class WorkItem;
|
| friend class Transaction;
|
| friend class ViewCacheHelper;
|
| + friend class HttpCachePrefetchValidationTest;
|
| struct PendingOp; // Info for an entry under construction.
|
| class AsyncValidation; // Encapsulates a single async revalidation.
|
|
|
| @@ -271,6 +274,10 @@ class NET_EXPORT HttpCache : public HttpTransactionFactory,
|
| typedef std::set<ActiveEntry*> ActiveEntriesSet;
|
| typedef base::hash_map<std::string, int> PlaybackCacheMap;
|
|
|
| + // The number of minutes after a resource is prefetched that it can be used
|
| + // again without validation.
|
| + static const int kPrefetchReuseMins = 5;
|
| +
|
| // Methods ------------------------------------------------------------------
|
|
|
| // Creates the |backend| object and notifies the |callback| when the operation
|
| @@ -455,6 +462,9 @@ class NET_EXPORT HttpCache : public HttpTransactionFactory,
|
| // The async validations currently in progress, keyed by URL.
|
| AsyncValidationMap async_validations_;
|
|
|
| + // A clock that can be swapped out for testing.
|
| + scoped_ptr<base::Clock> clock_;
|
| +
|
| base::WeakPtrFactory<HttpCache> weak_factory_;
|
|
|
| DISALLOW_COPY_AND_ASSIGN(HttpCache);
|
|
|