Class: Spaceship::Tunes::AppReview
- Defined in:
- spaceship/lib/spaceship/tunes/app_review.rb
Instance Attribute Summary collapse
-
#app_version ⇒ Object
readonly
Returns the value of attribute app_version.
-
#application ⇒ Object
Returns the value of attribute application.
-
#developer_response ⇒ Object
Returns the value of attribute developer_response.
-
#edited ⇒ Object
readonly
Returns the value of attribute edited.
-
#helpful_views ⇒ Object
readonly
Returns the value of attribute helpful_views.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#last_modified ⇒ Object
readonly
Returns the value of attribute last_modified.
-
#nickname ⇒ Object
readonly
Returns the value of attribute nickname.
-
#rating ⇒ Object
readonly
Returns the value of attribute rating.
-
#raw_developer_response ⇒ Object
readonly
Returns the value of attribute raw_developer_response.
-
#review ⇒ Object
readonly
Returns the value of attribute review.
-
#store_front ⇒ Object
readonly
Returns the value of attribute store_front.
-
#title ⇒ Object
readonly
Returns the value of attribute title.
-
#total_views ⇒ Object
readonly
Returns the value of attribute total_views.
Attributes inherited from Base
Class Method Summary collapse
-
.factory(attrs) ⇒ Object
Create a new object based on a hash.
Instance Method Summary collapse
Methods inherited from TunesBase
Methods inherited from Base
attr_accessor, attr_mapping, #attributes, attributes, #initialize, #inspect, mapping_module, method_missing, set_client, #setup, #to_s
Constructor Details
This class inherits a constructor from Spaceship::Base
Instance Attribute Details
#app_version ⇒ Object (readonly)
Returns the value of attribute app_version.
13 14 15 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 13 def app_version @app_version end |
#application ⇒ Object
Returns the value of attribute application.
6 7 8 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 6 def application @application end |
#developer_response ⇒ Object
Returns the value of attribute developer_response.
19 20 21 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 19 def developer_response @developer_response end |
#edited ⇒ Object (readonly)
Returns the value of attribute edited.
17 18 19 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 17 def edited @edited end |
#helpful_views ⇒ Object (readonly)
Returns the value of attribute helpful_views.
15 16 17 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 15 def helpful_views @helpful_views end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
8 9 10 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 8 def id @id end |
#last_modified ⇒ Object (readonly)
Returns the value of attribute last_modified.
14 15 16 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 14 def last_modified @last_modified end |
#nickname ⇒ Object (readonly)
Returns the value of attribute nickname.
11 12 13 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 11 def nickname @nickname end |
#rating ⇒ Object (readonly)
Returns the value of attribute rating.
7 8 9 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 7 def @rating end |
#raw_developer_response ⇒ Object (readonly)
Returns the value of attribute raw_developer_response.
18 19 20 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 18 def raw_developer_response @raw_developer_response end |
#review ⇒ Object (readonly)
Returns the value of attribute review.
10 11 12 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 10 def review @review end |
#store_front ⇒ Object (readonly)
Returns the value of attribute store_front.
12 13 14 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 12 def store_front @store_front end |
#title ⇒ Object (readonly)
Returns the value of attribute title.
9 10 11 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 9 def title @title end |
#total_views ⇒ Object (readonly)
Returns the value of attribute total_views.
16 17 18 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 16 def total_views @total_views end |
Class Method Details
.factory(attrs) ⇒ Object
Create a new object based on a hash. This is used to create a new object based on the server response.
38 39 40 41 42 43 44 45 46 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 38 def factory(attrs) obj = self.new(attrs) response_attrs = {} response_attrs = obj.raw_developer_response if obj.raw_developer_response response_attrs[:application] = obj.application response_attrs[:review_id] = obj.id obj.developer_response = DeveloperResponse.factory(response_attrs) return obj end |
Instance Method Details
#responded? ⇒ Boolean
49 50 51 52 |
# File 'spaceship/lib/spaceship/tunes/app_review.rb', line 49 def responded? return true if raw_developer_response false end |