Class: LaunchDarkly::Impl::Model::Preprocessor

Inherits:
Object
  • Object
show all
Defined in:
lib/ldclient-rb/impl/model/preprocessed_data.rb

Overview

Since:

  • 5.5.0

Class Method Summary collapse

Class Method Details

.precompute_multi_variation_results(flag, regular_reason, in_experiment_reason) ⇒ EvalResultFactoryMultiVariations

Parameters:

Returns:

Since:

  • 5.5.0



53
54
55
56
57
58
59
60
# File 'lib/ldclient-rb/impl/model/preprocessed_data.rb', line 53

def self.precompute_multi_variation_results(flag, regular_reason, in_experiment_reason)
  factories = []
  vars = flag[:variations] || []
  vars.each_index do |index|
    factories << EvalResultsForSingleVariation.new(vars[index], index, regular_reason, in_experiment_reason)
  end
  EvalResultFactoryMultiVariations.new(factories)
end