Class: Imagga::Image

Inherits:
Object
  • Object
show all
Includes:
Exceptions
Defined in:
lib/imagga/image.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Exceptions

#raise_if_request_failed!, #raise_missing

Constructor Details

#initialize(opts) ⇒ Image

Returns a new instance of Image.



8
9
10
11
# File 'lib/imagga/image.rb', line 8

def initialize(opts)
  @url             = opts[:url] || raise_missing(:url)
  @id              = opts[:id]  || 0
end

Instance Attribute Details

#idObject

Returns the value of attribute id.



6
7
8
# File 'lib/imagga/image.rb', line 6

def id
  @id
end

#urlObject

Returns the value of attribute url.



6
7
8
# File 'lib/imagga/image.rb', line 6

def url
  @url
end