From: Jaime Marquínez Ferrándiz Date: Mon, 4 Mar 2013 21:16:42 +0000 (+0100) Subject: Add a method for extracting info from a list of urls X-Git-Url: http://git.bitcoin.ninja/?a=commitdiff_plain;h=631f73978c0ee851950ac697dfd73f9092abd3c3;p=youtube-dl Add a method for extracting info from a list of urls --- diff --git a/youtube_dl/FileDownloader.py b/youtube_dl/FileDownloader.py index b26c34729..f668b362b 100644 --- a/youtube_dl/FileDownloader.py +++ b/youtube_dl/FileDownloader.py @@ -415,6 +415,14 @@ class FileDownloader(object): raise if not suitable_found: self.trouble(u'ERROR: no suitable InfoExtractor: %s' % url) + def extract_info_iterable(self, urls): + ''' + Return the videos founded for the urls + ''' + results = [] + for url in urls: + results.extend(self.extract_info(url)) + return results def process_info(self, info_dict): """Process a single dictionary returned by an InfoExtractor."""