Sha256: ed41a748246fedc3c46c21d31640d2ef7350cdcc112a29d8fc005874d3f0ae25

Contents?: true

Size: 761 Bytes

Versions: 27

Compression:

Stored size: 761 Bytes

Contents

FlightDistanceClass.class_eval do
  data_miner do
    import "distance classes from the WRI business travel tool and UK DEFRA/DECC GHG Conversion Factors for Company Reporting",
           :url => 'https://spreadsheets.google.com/pub?key=0AoQJbWqPrREqdFBKM0xWaUhKVkxDRmdBVkE3VklxY2c&hl=en&gid=0&output=csv' do
      key   'name'
      store 'distance',     :units_field_name => 'distance_units'
      store 'min_distance', :units_field_name => 'min_distance_units', :nullify => true
      store 'max_distance', :units_field_name => 'max_distance_units', :nullify => true
    end
    
    # FIXME TODO verify that min_distance >= 0
    # FIXME TODO verify that max_distance > 0
    # FIXME TODO verify that distance class distance bounds don't overlap
  end
end

Version data entries

27 entries across 27 versions & 1 rubygems

Version Path
earth-1.0.0 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.12.4 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.12.3 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.12.2 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.12.1 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.12.0 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.20 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.19 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.18 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.17 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.16 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.15 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.14 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.13 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.12 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.11 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.10 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.9 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.8 lib/earth/air/flight_distance_class/data_miner.rb
earth-0.11.7 lib/earth/air/flight_distance_class/data_miner.rb