Class: Yahoo::LocalSearch::Result
- Inherits:
-
Struct
- Object
- Struct
- Yahoo::LocalSearch::Result
- Defined in:
- lib/yahoo/local_search.rb,
lib/yahoo/local_search.rb
Overview
A Result contains the following fields:
id
-
The id of this result.
title
-
The name of the result
address
-
Street address of the result
city
-
City in which the result is located
state
-
State in which the result is located
phone
-
Phone number, if known
latitude
-
Latitude of the location
longitude
-
Longitude of the location
average_rating
-
Average score of end-user ratings for the business or service
total_ratings
-
Total number of ratings submitted for the business or service
total_reviews
-
Total number of ratings submitted for the business or service
last_review_date
-
Time of the last review submitted for the business or service
last_review_intro
-
The first few words of the last review submitted for the business or service
distance
-
Distance from the search location to this business or service
url
-
URL to the detailed page for a business
click_url
-
URL for linking to the detailed page for a business
map_url
-
URL for a map of the address
business_url
-
URL of the businesses website, if known
business_click_url
-
URL for linking to the businesses website, if known
categories
-
Hash of category names and category ids for this result
Instance Attribute Summary collapse
-
#address ⇒ Object
Returns the value of attribute address.
-
#average_rating ⇒ Object
Returns the value of attribute average_rating.
-
#business_click_url ⇒ Object
Returns the value of attribute business_click_url.
-
#business_url ⇒ Object
Returns the value of attribute business_url.
-
#categories ⇒ Object
Returns the value of attribute categories.
-
#city ⇒ Object
Returns the value of attribute city.
-
#click_url ⇒ Object
Returns the value of attribute click_url.
-
#distance ⇒ Object
Returns the value of attribute distance.
-
#id ⇒ Object
Returns the value of attribute id.
-
#last_review_date ⇒ Object
Returns the value of attribute last_review_date.
-
#last_review_intro ⇒ Object
Returns the value of attribute last_review_intro.
-
#latitude ⇒ Object
Returns the value of attribute latitude.
-
#longitude ⇒ Object
Returns the value of attribute longitude.
-
#map_url ⇒ Object
Returns the value of attribute map_url.
-
#phone ⇒ Object
Returns the value of attribute phone.
-
#state ⇒ Object
Returns the value of attribute state.
-
#title ⇒ Object
Returns the value of attribute title.
-
#total_ratings ⇒ Object
Returns the value of attribute total_ratings.
-
#total_reviews ⇒ Object
Returns the value of attribute total_reviews.
-
#url ⇒ Object
Returns the value of attribute url.
Instance Method Summary collapse
-
#coordinates ⇒ Object
Returns an Array with latitude and longitude.
Instance Attribute Details
#address ⇒ Object
Returns the value of attribute address
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def address @address end |
#average_rating ⇒ Object
Returns the value of attribute average_rating
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def @average_rating end |
#business_click_url ⇒ Object
Returns the value of attribute business_click_url
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def business_click_url @business_click_url end |
#business_url ⇒ Object
Returns the value of attribute business_url
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def business_url @business_url end |
#categories ⇒ Object
Returns the value of attribute categories
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def categories @categories end |
#city ⇒ Object
Returns the value of attribute city
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def city @city end |
#click_url ⇒ Object
Returns the value of attribute click_url
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def click_url @click_url end |
#distance ⇒ Object
Returns the value of attribute distance
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def distance @distance end |
#id ⇒ Object
Returns the value of attribute id
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def id @id end |
#last_review_date ⇒ Object
Returns the value of attribute last_review_date
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def last_review_date @last_review_date end |
#last_review_intro ⇒ Object
Returns the value of attribute last_review_intro
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def last_review_intro @last_review_intro end |
#latitude ⇒ Object
Returns the value of attribute latitude
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def latitude @latitude end |
#longitude ⇒ Object
Returns the value of attribute longitude
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def longitude @longitude end |
#map_url ⇒ Object
Returns the value of attribute map_url
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def map_url @map_url end |
#phone ⇒ Object
Returns the value of attribute phone
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def phone @phone end |
#state ⇒ Object
Returns the value of attribute state
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def state @state end |
#title ⇒ Object
Returns the value of attribute title
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def title @title end |
#total_ratings ⇒ Object
Returns the value of attribute total_ratings
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def @total_ratings end |
#total_reviews ⇒ Object
Returns the value of attribute total_reviews
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def total_reviews @total_reviews end |
#url ⇒ Object
Returns the value of attribute url
13 14 15 |
# File 'lib/yahoo/local_search.rb', line 13 def url @url end |
Instance Method Details
#coordinates ⇒ Object
Returns an Array with latitude and longitude.
140 141 142 |
# File 'lib/yahoo/local_search.rb', line 140 def coordinates return [latitude, longitude] end |