Module: Mongoid::Geo::Near
- Defined in:
- lib/mongoid/geo/geo_near.rb
Instance Method Summary collapse
Instance Method Details
#geoNear(center, location_attribute, options = {}) ⇒ Object
64 65 66 67 68 |
# File 'lib/mongoid/geo/geo_near.rb', line 64 def geoNear(center, location_attribute, = {}) center = center.respond_to?(:collection) ? center.send(location_attribute) : center query = create_query(self, center, ) create_result(query_result(self, query, center, location_attribute, )).extend(Mongoid::Geo::Models) end |