Class: Ebisu::ExImage
- Inherits:
-
Object
- Object
- Ebisu::ExImage
- Defined in:
- lib/ebisu/models/ex_image.rb
Instance Attribute Summary collapse
-
#height ⇒ Object
Returns the value of attribute height.
-
#url ⇒ Object
Returns the value of attribute url.
-
#width ⇒ Object
Returns the value of attribute width.
Instance Method Summary collapse
-
#initialize(image) ⇒ ExImage
constructor
A new instance of ExImage.
Constructor Details
#initialize(image) ⇒ ExImage
Returns a new instance of ExImage.
17 18 19 20 21 22 23 |
# File 'lib/ebisu/models/ex_image.rb', line 17 def initialize(image) return unless image @url = image.dig('url') @width = image.dig('width') @height = image.dig('height') end |
Instance Attribute Details
#height ⇒ Object
Returns the value of attribute height.
15 16 17 |
# File 'lib/ebisu/models/ex_image.rb', line 15 def height @height end |
#url ⇒ Object
Returns the value of attribute url.
7 8 9 |
# File 'lib/ebisu/models/ex_image.rb', line 7 def url @url end |
#width ⇒ Object
Returns the value of attribute width.
11 12 13 |
# File 'lib/ebisu/models/ex_image.rb', line 11 def width @width end |