Class: Tvdb2::TvdbStruct
- Inherits:
-
OpenStruct
- Object
- OpenStruct
- Tvdb2::TvdbStruct
- Defined in:
- lib/tvdb2/tvdb_struct.rb
Overview
OpenStruct that define ‘_url` methods to get url from images relative paths returned from api.
Instance Method Summary collapse
-
#fileName_url ⇒ Object
(also: #url)
‘fileName` field.
-
#image_url ⇒ String
The url string of relative image path stored in ‘image` field.
-
#initialize(tvdb = nil, hash = {}) ⇒ TvdbStruct
constructor
A new instance of TvdbStruct.
-
#thumbnail_url ⇒ Object
‘thumbnail` field.
Constructor Details
#initialize(tvdb = nil, hash = {}) ⇒ TvdbStruct
Note:
You should never need to create this object manually.
Returns a new instance of TvdbStruct.
19 20 21 |
# File 'lib/tvdb2/tvdb_struct.rb', line 19 def initialize(tvdb = nil, hash = {}) super(hash) end |
Instance Method Details
#fileName_url ⇒ Object Also known as: url
‘fileName` field. `nil` if `fileName` field is `nil`.
6 |
# File 'lib/tvdb2/tvdb_struct.rb', line 6 def fileName_url; end |
#image_url ⇒ String
Returns the url string of relative image path stored in ‘image` field. `nil` if `image` field is `nil`.
3 |
# File 'lib/tvdb2/tvdb_struct.rb', line 3 def image_url; end |
#thumbnail_url ⇒ Object
‘thumbnail` field. `nil` if `thumbnail` field is `nil`.
9 |
# File 'lib/tvdb2/tvdb_struct.rb', line 9 def thumbnail_url; end |