Class: MapQuest

Inherits:
Object
  • Object
show all
Includes:
HTTParty
Defined in:
lib/mapqdist.rb

Class Method Summary collapse

Class Method Details

.distance(from, to) ⇒ Object



15
16
17
18
# File 'lib/mapqdist.rb', line 15

def self.distance(from, to)
  options = {:query => {'from' => from, 'to' => to}}
  get('/routematrix',options)['distance'][1]
end