Chromium Code Reviews| Index: chrome/browser/net/predictor.h |
| diff --git a/chrome/browser/net/predictor.h b/chrome/browser/net/predictor.h |
| index b56a62bdf913840cb937999a953b3be0569b9036..0b083801337075e8eb5c0c299b041ccb0c3e7f13 100644 |
| --- a/chrome/browser/net/predictor.h |
| +++ b/chrome/browser/net/predictor.h |
| @@ -233,12 +233,21 @@ class Predictor { |
| void PreconnectUrl(const GURL& url, const GURL& first_party_for_cookies, |
| UrlInfo::ResolutionMotivation motivation, int count); |
| + // May be called from either the IO or UI thread and will PostTask |
|
cbentzel
2013/06/24 10:48:39
Is this comment correct? The name of it seems to i
kouhei (in TOK)
2013/06/25 03:33:50
Sorry I put this by mistake. Thank you for pointin
|
| + // to the IO thread if necessary. |
| void PreconnectUrlOnIOThread(const GURL& url, |
| const GURL& first_party_for_cookies, |
| UrlInfo::ResolutionMotivation motivation, |
| int count); |
| - void RecordPreconnectNavigationStats(const GURL& url); |
| + // May be called from either the IO or UI thread and will PostTask |
| + // to the IO thread if necessary. |
| + void RecordPreconnectTrigger(const GURL& url); |
| + |
| + // May be called from either the IO or UI thread and will PostTask |
| + // to the IO thread if necessary. |
| + void RecordPreconnectNavigationStat(const GURL& url, |
| + const GURL& original_url); |
| // ------------- End IO thread methods. |
| @@ -453,6 +462,11 @@ class Predictor { |
| // continue with them shortly (i.e., it yeilds and continues). |
| void IncrementalTrimReferrers(bool trim_all_now); |
| + void RecordPreconnectTriggerOnIOThread(const GURL& url); |
| + |
| + void RecordPreconnectNavigationStatOnIOThread(const GURL& url, |
| + const GURL& original_url); |
| + |
| // ------------- End IO thread methods. |
| scoped_ptr<InitialObserver> initial_observer_; |
| @@ -509,7 +523,8 @@ class Predictor { |
| // The time when the last preconnection was requested to a search service. |
| base::TimeTicks last_omnibox_preconnect_; |
| - TimedCache recent_preconnects_; |
| + class PreconnectUsage; |
| + scoped_ptr<PreconnectUsage> preconnect_usage_; |
| // For each URL that we might navigate to (that we've "learned about") |
| // we have a Referrer list. Each Referrer list has all hostnames we might |