From 5be6333b8d8d2e99e825693bf009fef156a64ca6 Mon Sep 17 00:00:00 2001 From: Alex Reisner <alex@alexreisner.com> Date: Thu, 1 Oct 2009 01:00:22 -0400 Subject: [PATCH] Clarify documentation. --- README.rdoc | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/README.rdoc b/README.rdoc index 6c93dbf7..c911e79a 100644 --- a/README.rdoc +++ b/README.rdoc @@ -41,14 +41,13 @@ Assuming +Venue+ is a geocoded model: Assuming +obj+ has a valid string for its +location+: - obj.fetch_coordinates # returns coordinates [lat, lon] - obj.fetch_and_assign_coordinates # writes values to object - obj.nearbys(30) # gets other objects within given radius + obj.fetch_coordinates # returns coordinates [lat, lon] + obj.fetch_and_assign_coordinates # writes values to object -Find distance between object and a point: +Assuming +obj+ is geocoded (has latitude and longitude): - obj.distance_to(40.71432, -100.23487) # in miles - obj.distance_to(40.71432, -100.23487, :km) # in kilometers + obj.nearbys(30) # other objects within radius + obj.distance_to(40.714, -100.234) # distance to arbitrary point Some utility methods are also available: @@ -59,7 +58,7 @@ Some utility methods are also available: Geocoder.fetch_coordinates("25 Main St, Cooperstown, NY") -Please see the code for more methods and detailed information about arguments. +Please see the code for more methods and detailed information about arguments (eg, working with kilometers). Copyright (c) 2009 Alex Reisner, released under the MIT license -- GitLab