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

Unified Diff: components/variations/processed_study.h

Issue 2612243003: Supporting study definitions without default groups and end_date filtering. (Closed)
Patch Set: removing static initializer Created 3 years, 11 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 | « no previous file | components/variations/processed_study.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/variations/processed_study.h
diff --git a/components/variations/processed_study.h b/components/variations/processed_study.h
index 0607d064a9f307907dac756c8e9e7067447cc40d..e7807f5cf77d67deb00fd743c69cbc0217274889 100644
--- a/components/variations/processed_study.h
+++ b/components/variations/processed_study.h
@@ -18,6 +18,10 @@ class Study;
// such as whether the study is expired and its total probability.
class ProcessedStudy {
public:
+ // The default group used when a study doesn't specify one. This is needed
+ // because the field trial api requires a default group name.
+ static const char kGenericDefaultExperimentName[];
+
ProcessedStudy();
~ProcessedStudy();
@@ -43,6 +47,10 @@ class ProcessedStudy {
// experiment is found.
int GetExperimentIndexByName(const std::string& name) const;
+ // Gets the default experiment name for the study, or a generic one if none is
+ // specified.
+ const char* GetDefaultExperimentName() const;
+
static bool ValidateAndAppendStudy(
const Study* study,
bool is_expired,
« no previous file with comments | « no previous file | components/variations/processed_study.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698