Method: OmfEc::ExperimentProperty.each

Defined in:
lib/omf_ec/experiment_property.rb

.each(sort_names = false, &block) ⇒ Object

Iterate over all Experiment Properties. The block will be called with the respective property as single argument

  • sort_names = if ‘true’ sort the properties (default: true)

  • &block = the block of commands to call



76
77
78
79
80
# File 'lib/omf_ec/experiment_property.rb', line 76

def self.each(sort_names = false, &block)
  names = @@properties.keys
  names = names.sort_by {|sym| sym.to_s} if (sort_names)
  names.each { |n| block.call(@@properties[n]) }
end