Module: Mongoid::Spacial::Document::ClassMethods
- Defined in:
- lib/mongoid_spacial/spacial/document.rb
Overview
:nodoc:
Instance Method Summary collapse
-
#spacial_index(name, *options) ⇒ Object
create spacial index for given field.
Instance Method Details
#spacial_index(name, *options) ⇒ Object
create spacial index for given field
17 18 19 20 |
# File 'lib/mongoid_spacial/spacial/document.rb', line 17 def spacial_index name, * self.spacial_fields_indexed << name index [[ name, Mongo::GEO2D ]], * end |