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 #ifndef CHROME_BROWSER_PRERENDER_PRERENDER_FIELD_TRIAL_H_ | 5 #ifndef CHROME_BROWSER_PRERENDER_PRERENDER_FIELD_TRIAL_H_ |
6 #define CHROME_BROWSER_PRERENDER_PRERENDER_FIELD_TRIAL_H_ | 6 #define CHROME_BROWSER_PRERENDER_PRERENDER_FIELD_TRIAL_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 class Profile; | 10 class Profile; |
(...skipping 30 matching lines...) Expand all Loading... |
41 bool IsSideEffectFreeWhitelistEnabled(); | 41 bool IsSideEffectFreeWhitelistEnabled(); |
42 | 42 |
43 // Returns true if the local predictor should actually launch prerenders. | 43 // Returns true if the local predictor should actually launch prerenders. |
44 bool IsLocalPredictorPrerenderLaunchEnabled(); | 44 bool IsLocalPredictorPrerenderLaunchEnabled(); |
45 | 45 |
46 // Returns true if the local predictor should prerender, but only as control | 46 // Returns true if the local predictor should prerender, but only as control |
47 // group. If the local predictor never launches prerenders, then this setting | 47 // group. If the local predictor never launches prerenders, then this setting |
48 // is irrelevant. | 48 // is irrelevant. |
49 bool IsLocalPredictorPrerenderAlwaysControlEnabled(); | 49 bool IsLocalPredictorPrerenderAlwaysControlEnabled(); |
50 | 50 |
| 51 // Returns true if the local predictor should prefetch rather than prerender. |
| 52 bool IsLocalPredictorPrerenderPrefetchEnabled(); |
| 53 |
51 // Returns true if we should query the prerender service for the profile | 54 // Returns true if we should query the prerender service for the profile |
52 // provided. | 55 // provided. |
53 bool ShouldQueryPrerenderService(Profile* profile); | 56 bool ShouldQueryPrerenderService(Profile* profile); |
54 | 57 |
55 // Indicates whether we should query the prerender service for the current URL | 58 // Indicates whether we should query the prerender service for the current URL |
56 // and candidate URLs, respectively. | 59 // and candidate URLs, respectively. |
57 bool ShouldQueryPrerenderServiceForCurrentURL(); | 60 bool ShouldQueryPrerenderServiceForCurrentURL(); |
58 bool ShouldQueryPrerenderServiceForCandidateURLs(); | 61 bool ShouldQueryPrerenderServiceForCandidateURLs(); |
59 | 62 |
60 // Returns the URL prefix to be used for the prerender service. The only thing | 63 // Returns the URL prefix to be used for the prerender service. The only thing |
(...skipping 11 matching lines...) Expand all Loading... |
72 int GetLocalPredictorTTLSeconds(); | 75 int GetLocalPredictorTTLSeconds(); |
73 | 76 |
74 // Returns the half-life time to use to decay local predictor prerender | 77 // Returns the half-life time to use to decay local predictor prerender |
75 // priorities. | 78 // priorities. |
76 int GetLocalPredictorPrerenderPriorityHalfLifeTimeSeconds(); | 79 int GetLocalPredictorPrerenderPriorityHalfLifeTimeSeconds(); |
77 | 80 |
78 // Returns the maximum number of concurrent prerenders the local predictor | 81 // Returns the maximum number of concurrent prerenders the local predictor |
79 // may maintain. | 82 // may maintain. |
80 int GetLocalPredictorMaxConcurrentPrerenders(); | 83 int GetLocalPredictorMaxConcurrentPrerenders(); |
81 | 84 |
| 85 // Returns the maximum number of concurrent prerenders the local predictor |
| 86 // may launch concurrently. |
| 87 int GetLocalPredictorMaxLaunchPrerenders(); |
| 88 |
82 // The following functions return whether certain LocalPredictor checks should | 89 // The following functions return whether certain LocalPredictor checks should |
83 // be skipped, as indicated by the name. | 90 // be skipped, as indicated by the name. |
84 bool SkipLocalPredictorFragment(); | 91 bool SkipLocalPredictorFragment(); |
85 bool SkipLocalPredictorHTTPS(); | 92 bool SkipLocalPredictorHTTPS(); |
86 bool SkipLocalPredictorWhitelist(); | 93 bool SkipLocalPredictorWhitelist(); |
87 bool SkipLocalPredictorServiceWhitelist(); | 94 bool SkipLocalPredictorServiceWhitelist(); |
88 bool SkipLocalPredictorLoggedIn(); | 95 bool SkipLocalPredictorLoggedIn(); |
89 bool SkipLocalPredictorDefaultNoPrerender(); | 96 bool SkipLocalPredictorDefaultNoPrerender(); |
90 bool SkipLocalPredictorLocalCandidates(); | 97 bool SkipLocalPredictorLocalCandidates(); |
91 bool SkipLocalPredictorServiceCandidates(); | 98 bool SkipLocalPredictorServiceCandidates(); |
92 | 99 |
93 // Indicates whether no prerender cookie stores should be used for prerendering. | 100 // Indicates whether no prerender cookie stores should be used for prerendering. |
94 bool IsPrerenderCookieStoreEnabled(); | 101 bool IsPrerenderCookieStoreEnabled(); |
95 | 102 |
96 } // namespace prerender | 103 } // namespace prerender |
97 | 104 |
98 #endif // CHROME_BROWSER_PRERENDER_PRERENDER_FIELD_TRIAL_H_ | 105 #endif // CHROME_BROWSER_PRERENDER_PRERENDER_FIELD_TRIAL_H_ |
OLD | NEW |