Class: Croppable::Param
- Inherits:
-
Object
- Object
- Croppable::Param
- Defined in:
- lib/croppable/param.rb
Instance Attribute Summary collapse
-
#data ⇒ Object
Returns the value of attribute data.
-
#delete ⇒ Object
Returns the value of attribute delete.
-
#image ⇒ Object
Returns the value of attribute image.
Instance Method Summary collapse
-
#initialize(image, data, delete: false) ⇒ Param
constructor
A new instance of Param.
Constructor Details
#initialize(image, data, delete: false) ⇒ Param
Returns a new instance of Param.
5 6 7 8 9 10 11 12 13 14 |
# File 'lib/croppable/param.rb', line 5 def initialize(image, data, delete: false) @image = image @delete = delete @data = { x: data[:x], y: data[:y], scale: data[:scale], background_color: data[:background_color] } end |
Instance Attribute Details
#data ⇒ Object
Returns the value of attribute data.
3 4 5 |
# File 'lib/croppable/param.rb', line 3 def data @data end |
#delete ⇒ Object
Returns the value of attribute delete.
3 4 5 |
# File 'lib/croppable/param.rb', line 3 def delete @delete end |
#image ⇒ Object
Returns the value of attribute image.
3 4 5 |
# File 'lib/croppable/param.rb', line 3 def image @image end |