Class: Ehbrs::Tools::Runner::Videos::Opensubtitles

Inherits:
Object
  • Object
show all
Defined in:
lib/ehbrs/tools/runner/videos/opensubtitles.rb

Instance Method Summary collapse

Instance Method Details

#output_contentObject



27
28
29
# File 'lib/ehbrs/tools/runner/videos/opensubtitles.rb', line 27

def output_content
  subtitles.map { |v| "#{format_url(v.source_uri)}\n" }.join
end

#runObject



19
20
21
# File 'lib/ehbrs/tools/runner/videos/opensubtitles.rb', line 19

def run
  parsed.download? ? run_download : run_output
end

#run_downloadObject



23
24
25
# File 'lib/ehbrs/tools/runner/videos/opensubtitles.rb', line 23

def run_download
  subtitles.map { |sub| download_sub(sub) }
end