#NEWLINE# def _get_vod_streams( self , params ) : #NEWLINE# #INDENT# manifest_url = params . get ( 'autoURL' ) #NEWLINE# if ( not manifest_url ) : #NEWLINE# #INDENT# return #NEWLINE# #UNINDENT# res = http . get ( manifest_url ) #NEWLINE# if ( res . headers . get ( 'Content-Type' ) == 'application/f4m+xml' ) : #NEWLINE# #INDENT# streams = HDSStream . parse_manifest ( self . session , res . url ) #NEWLINE# for __ in streams . items ( ) : #NEWLINE# #INDENT# ( yield __ ) #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# if ( res . headers . get ( 'Content-Type' ) == 'application/vnd.apple.mpegurl' ) : #NEWLINE# #INDENT# streams = HLSStream . parse_variant_playlist ( self . session , res . url ) #NEWLINE# for __ in streams . items ( ) : #NEWLINE# #INDENT# ( yield __ ) #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# manifest = http . json ( res , schema = _vod_manifest_schema ) #NEWLINE# for params in streams [ 'alternates' ] : #NEWLINE# #INDENT# name = '{0}p' . format ( params [ 'height' ] ) #NEWLINE# stream = self . _create_flv_playlist ( params [ 'template' ] ) #NEWLINE# ( yield ( name , stream ) ) #NEWLINE# failovers = params . get ( 'failover' , [ ] ) #NEWLINE# for failover in failovers : #NEWLINE# #INDENT# stream = self . _create_flv_playlist ( failover ) #NEWLINE# ( yield ( name , stream ) )