12 lines
243 B
Ruby
12 lines
243 B
Ruby
class VideoMetadataExtractor
|
|
def initialize(file_path)
|
|
@file_path = file_path
|
|
@transcoder = VideoTranscoder.new
|
|
end
|
|
|
|
def extract
|
|
return {} unless File.exist?(@file_path)
|
|
|
|
@transcoder.extract_metadata(@file_path)
|
|
end
|
|
end |