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

Unified Diff: chrome/browser/metrics/variations_service.h

Issue 10375043: Variations Service now creates field trials from variations seed. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Alexei's comments Created 8 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/metrics/variations_service.h
diff --git a/chrome/browser/metrics/variations_service.h b/chrome/browser/metrics/variations_service.h
index a15045e002f1b9b917965d643c7b965b17b44c03..608e29b69d793efcec64168e2b74c012ff7857a9 100644
--- a/chrome/browser/metrics/variations_service.h
+++ b/chrome/browser/metrics/variations_service.h
@@ -27,9 +27,10 @@ class VariationsService : public content::URLFetcherDelegate {
// Returns the singleton instance;
static VariationsService* GetInstance();
- // Loads the Variations seed data from the given local prefs. If there is a
- // problem with loading, the pref value is cleared.
- void LoadVariationsSeed(PrefService* local_prefs);
+ // Creates field trials based on Variations Seed loaded from local prefs. If
+ // there is a problem loading the seed data, all trials specified by the seed
+ // may not be created.
+ bool CreateTrialsFromSeed(PrefService* local_prefs);
// Starts the fetching process, where |OnURLFetchComplete| is called with the
// response.
@@ -74,6 +75,15 @@ class VariationsService : public content::URLFetcherDelegate {
static bool CheckStudyDate(const chrome_variations::Study& study,
const base::Time& date_time);
+ // Loads the Variations seed data from the given local prefs into |seed|. If
+ // there is a problem with loading, the pref value is cleared and false is
+ // returned. If successful, |seed| will contain the loaded data and true is
+ // returned.
+ bool LoadVariationsSeed(PrefService* local_prefs,
Alexei Svitkine (slow) 2012/05/08 03:41:34 Also, see my previous comment: rename this to Load
jwd 2012/05/08 03:53:37 Done.
+ chrome_variations::TrialsSeed* seed);
+
+ void CreateTrialFromStudy(const chrome_variations::Study& study);
+
// Contains the current seed request. Will only have a value while a request
// is pending, and will be reset by |OnURLFetchComplete|.
scoped_ptr<content::URLFetcher> pending_seed_request_;

Powered by Google App Engine
This is Rietveld 408576698