Sha256: 68ee8880546072885b4a09e7a23c42eeef0d75b13398ed16362c97be11859608

Contents?: true

Size: 441 Bytes

Versions: 65

Compression:

Stored size: 441 Bytes

Contents

class ResidenceAppliance < ActiveRecord::Base
  set_primary_key :name

  class << self
    def annual_energy_from_electricity_for(appliance_plural)
      appliance_name = appliance_plural.to_s.singularize
      if appliance = find_by_name(appliance_name)
        appliance.annual_energy_from_electricity
      end
    end
  end

  data_miner do
    tap "Brighter Planet's residence appliance energy information", Earth.taps_server
  end
end

Version data entries

65 entries across 65 versions & 2 rubygems

Version Path
earth-0.5.0 lib/earth/residence/residence_appliance.rb
earth-0.4.12 lib/earth/residence/residence_appliance.rb
earth-0.4.11 lib/earth/residence/residence_appliance.rb
earth-0.4.10 lib/earth/residence/residence_appliance.rb
earth-0.4.9 lib/earth/residence/residence_appliance.rb
earth-0.4.8 lib/earth/residence/residence_appliance.rb
earth-0.4.7 lib/earth/residence/residence_appliance.rb
earth-0.4.6 lib/earth/residence/residence_appliance.rb
earth-0.4.5 lib/earth/residence/residence_appliance.rb
earth-0.4.4 lib/earth/residence/residence_appliance.rb
earth-0.4.3 lib/earth/residence/residence_appliance.rb
earth-0.4.2 lib/earth/residence/residence_appliance.rb
earth-0.4.1 lib/earth/residence/residence_appliance.rb
earth-0.4.0 lib/earth/residence/residence_appliance.rb
earth-0.3.15 lib/earth/residence/residence_appliance.rb
earth-0.3.14 lib/earth/residence/residence_appliance.rb
earth-0.3.13 lib/earth/residence/residence_appliance.rb
earth-0.3.11 lib/earth/residence/residence_appliance.rb
earth-0.3.10 lib/earth/residence/residence_appliance.rb
earth-0.3.9 lib/earth/residence/residence_appliance.rb