Class: Imagga::ExtractOptions

Inherits:
BaseOptions show all
Defined in:
lib/imagga/options.rb

Instance Attribute Summary

Attributes inherited from BaseOptions

#api_key, #api_secret, #version

Instance Method Summary collapse

Methods inherited from BaseOptions

#base_options, #initialize, #sign

Methods included from Parametizer

#build_boolean_options, #build_comma_separated_string

Constructor Details

This class inherits a constructor from Imagga::BaseOptions

Instance Method Details

#boolean_fieldsObject



39
40
41
# File 'lib/imagga/options.rb', line 39

def boolean_fields
  [:extract_overall_colors, :extract_object_colors]
end

#methodObject



35
36
37
# File 'lib/imagga/options.rb', line 35

def method
  'imagga.colorsearch.extract'
end

#options(opts = {}) ⇒ Object



29
30
31
32
33
# File 'lib/imagga/options.rb', line 29

def options(opts={})
  opts.merge!(base_options).merge!(method: method)
  opts.merge!(build_boolean_options(opts, boolean_fields))
  opts.merge!(sig: sign(opts))
end