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

Unified Diff: components/variations/processed_study.h

Issue 59103009: Refactor VariationsSeedProcessor to add ProcessedStudy struct. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 7 years, 1 month 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 | « components/variations.gypi ('k') | 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
===================================================================
--- components/variations/processed_study.h (revision 0)
+++ components/variations/processed_study.h (working copy)
@@ -0,0 +1,34 @@
+// Copyright 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef COMPONENTS_VARIATIONS_PROCESSED_STUDY_H_
+#define COMPONENTS_VARIATIONS_PROCESSED_STUDY_H_
+
+#include "base/metrics/field_trial.h"
+
+namespace chrome_variations {
+
+class Study;
+
+// Wrapper over Study with extra information computed during pre-processing,
+// such as whether the study is expired and its total probability.
+struct ProcessedStudy {
+ ProcessedStudy(const Study* study,
+ base::FieldTrial::Probability total_probability,
+ bool is_expired);
+ ~ProcessedStudy();
+
+ // Corresponding Study object. Weak reference.
+ const Study* study;
+
+ // Computed total group probability for the study.
+ base::FieldTrial::Probability total_probability;
+
+ // Whether the study is expired.
+ bool is_expired;
+};
+
+} // namespace chrome_variations
+
+#endif // COMPONENTS_VARIATIONS_PROCESSED_STUDY_H_
« no previous file with comments | « components/variations.gypi ('k') | components/variations/processed_study.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698