class DVR::Recorder
Public Instance Methods
files()
click to toggle source
# File lib/dvr/recorder.rb, line 13 def files Dir.glob("#{DVR.configuration.episode_location}/**/*.json").select {|f| !f.include?('index.json') } end
get_episodes()
click to toggle source
# File lib/dvr/recorder.rb, line 4 def get_episodes puts "Recording episodes..." Episode.batch_record(parsed_files) end
get_season()
click to toggle source
# File lib/dvr/recorder.rb, line 9 def get_season Season.new(get_episodes) end
parse_file(file_loc)
click to toggle source
# File lib/dvr/recorder.rb, line 21 def parse_file file_loc JSON.parse(File.open(file_loc).read) end
parsed_files()
click to toggle source
# File lib/dvr/recorder.rb, line 17 def parsed_files files.map {|f| parse_file(f)} end