Method: OmfEc::ExperimentProperty.method_missing

Defined in:
lib/omf_ec/experiment_property.rb

.method_missing(name, args = nil) ⇒ Object

Handles missing method, allows to access an existing Experiment Property with the syntax ‘propcontext.propname’



56
57
58
59
60
61
62
63
64
65
66
67
# File 'lib/omf_ec/experiment_property.rb', line 56

def self.method_missing(name, args = nil)
  name = name.to_s
  if setter = (name[-1] == ?=)
    name.chop!
  end
  p = ExperimentProperty[name.to_sym]
  if setter
    p.set(args)
  else
    return p
  end
end