Class WeightedStrings

java.lang.Object
io.nosqlbench.virtdata.library.basics.shared.from_long.to_string.WeightedStrings
All Implemented Interfaces:
LongFunction<String>

public class WeightedStrings extends Object implements LongFunction<String>
Allows for weighted elements to be used, such as a:0.25;b:0.25;c:0.5 or a:1;b:1.0;c:2.0 The unit weights are normalized to the cumulative sum internally, so it is not necessary for them to add up to any particular value.
  • Constructor Details

    • WeightedStrings

      public WeightedStrings(String valuesAndWeights)
  • Method Details