Class: Services::Builders::Image

Inherits:
Object
  • Object
show all
Defined in:
lib/services/builders/image.rb

Instance Method Summary collapse

Constructor Details

#initialize(image_path) ⇒ Image



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

def initialize(image_path)
  @image_path = image_path
end

Instance Method Details

#callObject



10
11
12
# File 'lib/services/builders/image.rb', line 10

def call
  Google::Apis::VisionV1::Image.new(content: open(@image_path).to_a.join)
end