Class: ThinkingSphinx::Middlewares::Geographer::Inner::GeolocationAttributes
- Inherits:
-
Object
- Object
- ThinkingSphinx::Middlewares::Geographer::Inner::GeolocationAttributes
- Defined in:
- lib/thinking_sphinx/middlewares/geographer.rb
Instance Attribute Summary collapse
-
#latitude ⇒ Object
Returns the value of attribute latitude.
-
#longitude ⇒ Object
Returns the value of attribute longitude.
Instance Method Summary collapse
- #geo ⇒ Object
-
#initialize(context) ⇒ GeolocationAttributes
constructor
A new instance of GeolocationAttributes.
Constructor Details
#initialize(context) ⇒ GeolocationAttributes
Returns a new instance of GeolocationAttributes.
43 44 45 46 47 |
# File 'lib/thinking_sphinx/middlewares/geographer.rb', line 43 def initialize(context) self.context = context self.latitude = latitude_attr if latitude_attr self.longitude = longitude_attr if longitude_attr end |
Instance Attribute Details
#latitude ⇒ Object
Returns the value of attribute latitude.
52 53 54 |
# File 'lib/thinking_sphinx/middlewares/geographer.rb', line 52 def latitude @latitude end |
#longitude ⇒ Object
Returns the value of attribute longitude.
52 53 54 |
# File 'lib/thinking_sphinx/middlewares/geographer.rb', line 52 def longitude @longitude end |
Instance Method Details
#geo ⇒ Object
49 50 51 |
# File 'lib/thinking_sphinx/middlewares/geographer.rb', line 49 def geo [:geo] end |