Class: Parse::Query::WithinCondition
- Inherits:
-
Object
- Object
- Parse::Query::WithinCondition
- Defined in:
- lib/parse/query.rb
Instance Method Summary collapse
-
#initialize(southwest_geo_point, northeast_geo_point) ⇒ WithinCondition
constructor
A new instance of WithinCondition.
- #to_s ⇒ Object
Constructor Details
#initialize(southwest_geo_point, northeast_geo_point) ⇒ WithinCondition
Returns a new instance of WithinCondition.
341 342 343 344 |
# File 'lib/parse/query.rb', line 341 def initialize southwest_geo_point, northeast_geo_point @southwest_geo_point = southwest_geo_point @northeast_geo_point = northeast_geo_point end |
Instance Method Details
#to_s ⇒ Object
346 347 348 |
# File 'lib/parse/query.rb', line 346 def to_s %Q|{"$within":{"$box":[#{@southwest_geo_point.to_json},#{@northeast_geo_point.to_json}]}}| end |