Module: Symbiont::DataSetter

Defined in:
lib/symbiont/data_setter.rb

Instance Method Summary collapse

Instance Method Details

#use_data_with(key, value) ⇒ Object



15
16
17
18
19
# File 'lib/symbiont/data_setter.rb', line 15

def use_data_with(key, value)
  element = send("#{key}")
  set_and_select(element, value)
  check_and_uncheck(element, value)
end

#using(data) ⇒ Object Also known as: using_data, use_data, using_values, use_values

Parameters:

  • data (Hash)

    the data to use



4
5
6
7
8
# File 'lib/symbiont/data_setter.rb', line 4

def using(data)
  data.each do |key, value|
    use_data_with(key, value) if object_enabled_for(key)
  end
end