Class: Flico::SaveCollage

Inherits:
Object
  • Object
show all
Defined in:
lib/flico/saver.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#output_file_nameObject

Returns the value of attribute output_file_name.



26
27
28
# File 'lib/flico/saver.rb', line 26

def output_file_name
  @output_file_name
end

Instance Method Details

#call(file_path) ⇒ Object



28
29
30
31
32
# File 'lib/flico/saver.rb', line 28

def call(file_path)
    file_name = output_file_name || validate_file_name
    FileUtils.mv file_path, file_name
    puts "Flicollage saved at #{file_name}"
end