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

Unified Diff: chrome/common/variations/uniformity_field_trials.cc

Issue 421663003: Move variations component code to variations namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Fix Created 6 years, 5 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
« no previous file with comments | « chrome/common/variations/experiment_labels_unittest.cc ('k') | components/rappor/rappor_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/variations/uniformity_field_trials.cc
===================================================================
--- chrome/common/variations/uniformity_field_trials.cc (revision 285608)
+++ chrome/common/variations/uniformity_field_trials.cc (working copy)
@@ -23,7 +23,7 @@
void SetupSingleUniformityFieldTrial(
base::FieldTrial::RandomizationType randomization_type,
const std::string& trial_name_string,
- const VariationID trial_base_id,
+ const variations::VariationID trial_base_id,
int num_trial_groups) {
// Probability per group remains constant for all uniformity trials, what
// changes is the probability divisor.
@@ -42,8 +42,9 @@
base::FieldTrialList::FactoryGetFieldTrial(
trial_name, divisor, kDefaultGroupName, 2015, 1, 1,
randomization_type, NULL));
- AssociateGoogleVariationID(GOOGLE_UPDATE_SERVICE, trial_name,
- kDefaultGroupName, trial_base_id);
+ variations::AssociateGoogleVariationID(variations::GOOGLE_UPDATE_SERVICE,
+ trial_name, kDefaultGroupName,
+ trial_base_id);
// Loop starts with group 1 because the field trial automatically creates a
// default group, which would be group 0.
@@ -52,9 +53,9 @@
base::StringPrintf("group_%02d", group_number);
DVLOG(1) << " Group name = " << group_name;
trial->AppendGroup(group_name, kProbabilityPerGroup);
- AssociateGoogleVariationID(
- GOOGLE_UPDATE_SERVICE, trial_name, group_name,
- static_cast<VariationID>(trial_base_id + group_number));
+ variations::AssociateGoogleVariationID(
+ variations::GOOGLE_UPDATE_SERVICE, trial_name, group_name,
+ static_cast<variations::VariationID>(trial_base_id + group_number));
}
// Now that all groups have been appended, call group() on the trial to
@@ -104,7 +105,7 @@
// Declare our variation ID bases along side this array so we can loop over it
// and assign the IDs appropriately. So for example, the 1 percent experiments
// should have a size of 100 (100/100 = 1).
- const VariationID trial_base_ids[] = {
+ const variations::VariationID trial_base_ids[] = {
UNIFORMITY_1_PERCENT_BASE,
UNIFORMITY_5_PERCENT_BASE,
UNIFORMITY_10_PERCENT_BASE,
« no previous file with comments | « chrome/common/variations/experiment_labels_unittest.cc ('k') | components/rappor/rappor_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698