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

Side by Side Diff: components/variations/proto/study.proto

Issue 2488173005: Adding support for exclude locales to variations. (Closed)
Patch Set: fix typo in comment Created 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | components/variations/study_filtering.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 syntax = "proto2"; 5 syntax = "proto2";
6 6
7 option optimize_for = LITE_RUNTIME; 7 option optimize_for = LITE_RUNTIME;
8 8
9 package variations; 9 package variations;
10 10
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
191 // Possible form factors Chrome is running on. 191 // Possible form factors Chrome is running on.
192 enum FormFactor { 192 enum FormFactor {
193 DESKTOP = 0; 193 DESKTOP = 0;
194 PHONE = 1; 194 PHONE = 1;
195 TABLET = 2; 195 TABLET = 2;
196 } 196 }
197 197
198 // Filtering criteria specifying whether this study is applicable to a given 198 // Filtering criteria specifying whether this study is applicable to a given
199 // Chrome instance. 199 // Chrome instance.
200 // 200 //
201 // Next tag: 12 201 // Next tag: 13
202 message Filter { 202 message Filter {
203 // The start date of the study in Unix time format. (Seconds since midnight 203 // The start date of the study in Unix time format. (Seconds since midnight
204 // January 1, 1970 UTC). See: http://en.wikipedia.org/wiki/Unix_time 204 // January 1, 1970 UTC). See: http://en.wikipedia.org/wiki/Unix_time
205 // Ex: 1330893974 (corresponds to 2012-03-04 20:46:14Z) 205 // Ex: 1330893974 (corresponds to 2012-03-04 20:46:14Z)
206 optional int64 start_date = 1; 206 optional int64 start_date = 1;
207 207
208 // The minimum Chrome version for this study, allowing a trailing '*' 208 // The minimum Chrome version for this study, allowing a trailing '*'
209 // character for pattern matching. Inclusive. (To check for a match, iterate 209 // character for pattern matching. Inclusive. (To check for a match, iterate
210 // over each component checking >= until a * or end of string is reached.) 210 // over each component checking >= until a * or end of string is reached.)
211 // Optional - if not specified, there is no minimum version. 211 // Optional - if not specified, there is no minimum version.
(...skipping 11 matching lines...) Expand all
223 // applies to all channels. 223 // applies to all channels.
224 // Ex: [BETA, STABLE] 224 // Ex: [BETA, STABLE]
225 repeated Channel channel = 4; 225 repeated Channel channel = 4;
226 226
227 // List of platforms that will receive this study. If omitted, the study 227 // List of platforms that will receive this study. If omitted, the study
228 // applies to all platforms. 228 // applies to all platforms.
229 // Ex: [PLATFORM_WINDOWS, PLATFORM_MAC] 229 // Ex: [PLATFORM_WINDOWS, PLATFORM_MAC]
230 repeated Platform platform = 5; 230 repeated Platform platform = 5;
231 231
232 // List of locales that will receive this study. If omitted, the study 232 // List of locales that will receive this study. If omitted, the study
233 // applies to all locales. 233 // applies to all locales, unless |exclude_locale| is specified. Mutually
234 // exclusive with |exclude_locale|.
234 // Ex: ["en-US", "en-CA"] 235 // Ex: ["en-US", "en-CA"]
235 repeated string locale = 6; 236 repeated string locale = 6;
236 237
238 // List of locales that will be excluded from this study. If omitted, the
239 // study applies to all locales unless |locale| is specified. Mutually
240 // exclusive with |locale|.
241 // Ex: ["en-US", "en-CA"]
242 repeated string exclude_locale = 12;
243
237 // List of form factors that will receive this study. If omitted, the study 244 // List of form factors that will receive this study. If omitted, the study
238 // applies to all form factors. 245 // applies to all form factors.
239 // Ex: [PHONE, TABLET] 246 // Ex: [PHONE, TABLET]
240 repeated FormFactor form_factor = 7; 247 repeated FormFactor form_factor = 7;
241 248
242 // List of ChromeOS hardware classes that will receive this study. Each 249 // List of ChromeOS hardware classes that will receive this study. Each
243 // entry is treated as a substring of the actual device hardware_class, 250 // entry is treated as a substring of the actual device hardware_class,
244 // so "FOO" will match the client's hardware class "Device FOOBAR". If 251 // so "FOO" will match the client's hardware class "Device FOOBAR". If
245 // omitted, the study applies to all hardware classes unless 252 // omitted, the study applies to all hardware classes unless
246 // |exclude_hardware_class| is specified. Mutually exclusive with 253 // |exclude_hardware_class| is specified. Mutually exclusive with
(...skipping 11 matching lines...) Expand all
258 repeated string exclude_hardware_class = 9; 265 repeated string exclude_hardware_class = 9;
259 266
260 // List of lowercase ISO 3166-1 alpha-2 country codes that will receive this 267 // List of lowercase ISO 3166-1 alpha-2 country codes that will receive this
261 // study. If omitted, the study applies to all countries unless 268 // study. If omitted, the study applies to all countries unless
262 // |exclude_country| is specified. Mutually exclusive with 269 // |exclude_country| is specified. Mutually exclusive with
263 // |exclude_country|. 270 // |exclude_country|.
264 // Ex: ["in", "us"] 271 // Ex: ["in", "us"]
265 repeated string country = 10; 272 repeated string country = 10;
266 273
267 // List of lowercase ISO 3166-1 alpha-2 country codes that will be excluded 274 // List of lowercase ISO 3166-1 alpha-2 country codes that will be excluded
268 // in this study. If omitted, the study applies to all countries unless 275 // from this study. If omitted, the study applies to all countries unless
269 // |country| is specified. Mutually exclusive with |country|. 276 // |country| is specified. Mutually exclusive with |country|.
270 // Ex: ["in", "us"] 277 // Ex: ["in", "us"]
271 repeated string exclude_country = 11; 278 repeated string exclude_country = 11;
272 } 279 }
273 280
274 // Filtering criteria for this study. A study that is filtered out for a given 281 // Filtering criteria for this study. A study that is filtered out for a given
275 // client is equivalent to that study not being sent at all. 282 // client is equivalent to that study not being sent at all.
276 optional Filter filter = 10; 283 optional Filter filter = 10;
277 284
278 // Randomization seed to be used when |consistency| is set to PERMANENT. If 285 // Randomization seed to be used when |consistency| is set to PERMANENT. If
279 // not specified, randomization will be done using the trial name. 286 // not specified, randomization will be done using the trial name.
280 optional uint32 randomization_seed = 11; 287 optional uint32 randomization_seed = 11;
281 288
282 // Specifies whether the study starts as active initially, or whether it 289 // Specifies whether the study starts as active initially, or whether it
283 // requires the client to query its state before it is marked as active. 290 // requires the client to query its state before it is marked as active.
284 enum ActivationType { 291 enum ActivationType {
285 // The study will be activated when its state is queried by the client. 292 // The study will be activated when its state is queried by the client.
286 // This is recommended for most studies that include client code. 293 // This is recommended for most studies that include client code.
287 ACTIVATION_EXPLICIT = 0; 294 ACTIVATION_EXPLICIT = 0;
288 // The study will be automatically activated when it is created. This 295 // The study will be automatically activated when it is created. This
289 // is recommended for studies that do not have any client logic. 296 // is recommended for studies that do not have any client logic.
290 ACTIVATION_AUTO = 1; 297 ACTIVATION_AUTO = 1;
291 } 298 }
292 299
293 // Activation type for this study. Defaults to ACTIVATION_EXPLICIT if omitted. 300 // Activation type for this study. Defaults to ACTIVATION_EXPLICIT if omitted.
294 optional ActivationType activation_type = 12; 301 optional ActivationType activation_type = 12;
295 } 302 }
OLDNEW
« no previous file with comments | « no previous file | components/variations/study_filtering.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698