public class RandomizedTrial extends Object
Modifier and Type | Method and Description |
---|---|
static <T extends Enum<T> & WithProbability> |
getGroup(String name,
String buildId,
Class<T> enumClass)
Returns a group for trial with given name.
|
static <T extends Enum<T>> |
getGroup(String name,
String buildId,
Map<T,Double> enumValuesWithProbabilities)
Returns a group for trial with given name.
|
static <T extends Enum<T> & WithProbability> |
getGroupStable(String name,
Class<T> enumClass)
Returns a group for trial with given name.
|
static <T extends Enum<T>> |
getGroupStable(String name,
Map<T,Double> enumValuesWithProbabilities)
Returns a group for trial with given name.
|
public static <T extends Enum<T> & WithProbability> T getGroupStable(String name, Class<T> enumClass)
This choice is stable for each test/user/hostname.
name
- name of trial.enumClass
- Class of an enum which conforms to WithProbability
interface.public static <T extends Enum<T>> T getGroupStable(String name, Map<T,Double> enumValuesWithProbabilities)
This choice is stable for each test/user/hostname.
name
- name of trial.enumValuesWithProbabilities
- Map of enum values to probabilities.public static <T extends Enum<T>> T getGroup(String name, String buildId, Map<T,Double> enumValuesWithProbabilities)
This choice is stable for a particular buildId/test/user/hostname.
name
- name of trial.enumValuesWithProbabilities
- Map of enum values to probabilities.public static <T extends Enum<T> & WithProbability> T getGroup(String name, String buildId, Class<T> enumClass)
This choice is stable for a particular buildId/test/user/hostname.
name
- name of trial.enumClass
- Class of an enum which conforms to WithProbability
interface.