class EventSplittr::Photo
Attributes
path[R]
Public Class Methods
new(path)
click to toggle source
# File lib/event_splittr/photo.rb, line 7 def initialize(path) @photo = EXIFR::JPEG.new(path) @path = path end
Public Instance Methods
destination_path(destination_dir)
click to toggle source
# File lib/event_splittr/photo.rb, line 12 def destination_path(destination_dir) "#{destination_dir}/#{project_name}/#{Pathname.new(path).basename}" end
project_name()
click to toggle source
# File lib/event_splittr/photo.rb, line 16 def project_name time_taken.strftime("%Y-%m-%d") end
Private Instance Methods
time_taken()
click to toggle source
# File lib/event_splittr/photo.rb, line 22 def time_taken @photo.date_time end