Class: Spree::Amazon::Image

Inherits:
Base
  • Object
show all
Defined in:
app/models/spree/amazon/image.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Base

#attributes=, #to_param

Constructor Details

#initialize(url, _alt = nil) ⇒ Image



8
9
10
11
# File 'app/models/spree/amazon/image.rb', line 8

def initialize(url, _alt = nil)
  @attachment = Spree::Amazon::Asset.new(url)
  @alt = _alt.to_s
end

Instance Attribute Details

#altObject

Returns the value of attribute alt



5
6
7
# File 'app/models/spree/amazon/image.rb', line 5

def alt
  @alt
end

#attachmentObject

Returns the value of attribute attachment



5
6
7
# File 'app/models/spree/amazon/image.rb', line 5

def attachment
  @attachment
end