3 from .common import InfoExtractor
4 from .internetvideoarchive import InternetVideoArchiveIE
10 class VideoDetectiveIE(InfoExtractor):
11 _VALID_URL = r'https?://www\.videodetective\.com/[^/]+/[^/]+/(?P<id>\d+)'
14 u'url': u'http://www.videodetective.com/movies/kick-ass-2/194487',
15 u'file': u'194487.mp4',
17 u'title': u'KICK-ASS 2',
18 u'description': u'md5:65ba37ad619165afac7d432eaded6013',
23 def _real_extract(self, url):
24 mobj = re.match(self._VALID_URL, url)
25 video_id = mobj.group('id')
26 webpage = self._download_webpage(url, video_id)
27 og_video = self._og_search_video_url(webpage)
28 query = compat_urlparse.urlparse(og_video).query
29 return self.url_result(InternetVideoArchiveIE._build_url(query),
30 ie=InternetVideoArchiveIE.ie_key())