public class FrequencyGenerationMode extends AbstractGenerationMode
AbstractGenerationMode
subclass that selects next candidate
configuration accordingly to a given frequency.
Each configuration frequency is given through its Frequency configuration value. If it is not set then 1 is assumed.
The frequency of each configuration indicates the number of times it is chosen. The higher it is the more frequent that configuration is chosen.
For example, if there is two configurations the first with a frequency set to 1 and the second with a frequency set to 3, then the second configuration is chosen 3 times more than the first configuration.
More formally, if there is configuration candidates so that, for each
,
the frequency of each candidates is
and the number of times the configuration is selected is
then:
Constructor and Description |
---|
FrequencyGenerationMode(Config config,
String context) |
Modifier and Type | Method and Description |
---|---|
FrequencyGenerationMode |
clone() |
Config |
next() |
getConfig, getConfigurations
public FrequencyGenerationMode clone()
clone
in interface GenerationMode
clone
in class AbstractGenerationMode
public Config next()