Class: Yelp::Review::Request::GeoPoint

Inherits:
Base show all
Defined in:
lib/yelp/review/request/geo_point.rb

Overview

Describes a request to search for business reviews for businesses near a specific geo-point and radius around that point.

Instance Attribute Summary collapse

Attributes inherited from Base

#business_count, #category, #term

Attributes inherited from Yelp::Request

#compress_response, #response_format, #yws_id

Instance Method Summary collapse

Methods inherited from Base

#base_url

Methods inherited from Yelp::Request

#initialize

Methods inherited from Yelp::Record

#initialize

Constructor Details

This class inherits a constructor from Yelp::Request

Instance Attribute Details

#latitudeObject (readonly)

latitude of geo-point to search near



11
12
13
# File 'lib/yelp/review/request/geo_point.rb', line 11

def latitude
  @latitude
end

#longitudeObject (readonly)

longitude of geo-point to search near



14
15
16
# File 'lib/yelp/review/request/geo_point.rb', line 14

def longitude
  @longitude
end

#radiusObject (readonly)

radius to use while searching around specified geo-point. default value is 1, maximum value is 25.



18
19
20
# File 'lib/yelp/review/request/geo_point.rb', line 18

def radius
  @radius
end

Instance Method Details

#to_yelp_paramsObject



20
21
22
23
24
# File 'lib/yelp/review/request/geo_point.rb', line 20

def to_yelp_params
  super.merge(:lat => latitude,
              :long => longitude,
              :radius => radius)
end