Sha256: 6f40a55f81c1808e2d3261b9926593376b9f5d0a24e9dca5c1f8179317e91417

Contents?: true

Size: 601 Bytes

Versions: 14

Compression:

Stored size: 601 Bytes

Contents

class LodgingClass < ActiveRecord::Base
  extend Earth::Base

  set_primary_key :name
  
  has_many :lodgings

  def self.schema_definition
    lambda do
      string 'name'
      float  'natural_gas_intensity'
      string 'natural_gas_intensity_units'
      float  'fuel_oil_intensity'
      string 'fuel_oil_intensity_units'
      float  'electricity_intensity'
      string 'electricity_intensity_units'
      float  'district_heat_intensity'
      string 'district_heat_intensity_units'
    end
  end
  
  data_miner do
    tap "Brighter Planet's lodging class data", Earth.taps_server
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
earth-0.3.3 lib/earth/hospitality/lodging_class.rb
earth-0.3.2 lib/earth/hospitality/lodging_class.rb
earth-0.3.1 lib/earth/hospitality/lodging_class.rb
earth-0.3.0 lib/earth/hospitality/lodging_class.rb
earth-0.2.14 lib/earth/hospitality/lodging_class.rb
earth-0.2.13 lib/earth/hospitality/lodging_class.rb
earth-0.2.12 lib/earth/hospitality/lodging_class.rb
earth-0.2.11 lib/earth/hospitality/lodging_class.rb
earth-0.2.9 lib/earth/hospitality/lodging_class.rb
earth-0.2.8 lib/earth/hospitality/lodging_class.rb
earth-0.2.7 lib/earth/hospitality/lodging_class.rb
earth-0.2.6 lib/earth/hospitality/lodging_class.rb
earth-0.2.5 lib/earth/hospitality/lodging_class.rb
earth-0.2.4 lib/earth/hospitality/lodging_class.rb