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



29
30
31
# File 'lib/ehbrs/tools/runner/videos/opensubtitles.rb', line 29

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

#runObject



21
22
23
# File 'lib/ehbrs/tools/runner/videos/opensubtitles.rb', line 21

def run
  parsed.download? ? run_download : run_output
end

#run_downloadObject



25
26
27
# File 'lib/ehbrs/tools/runner/videos/opensubtitles.rb', line 25

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