module ImageInteraction

Public Instance Methods

place_image_content(file_name, content, extension =".png") click to toggle source
# File lib/html_compilation/modules/image_interaction.rb, line 7
def place_image_content(file_name, content, extension =".png")
  File.write(file_name + extension, content, mode: "wb:ASCII-8BIT")
end
retrieve_image_content(file_location) click to toggle source

wonkavision

# File lib/html_compilation/modules/image_interaction.rb, line 3
def retrieve_image_content(file_location)
  File.read(file_location, mode: "rb")
end
return_all_files(current_location, file_type = '*', filter = '*') click to toggle source
# File lib/html_compilation/modules/image_interaction.rb, line 11
def return_all_files(current_location, file_type = '*', filter = '*')
  Dir.glob("#{current_location}/#{filter}.#{file_type}")
end