当前位置: 首页>>代码示例>>Python>>正文


Python ListItem.get_moving_data()['videoStreamUrl']方法代码示例

本文整理汇总了Python中common.DataObjects.ListItem.get_moving_data()['videoStreamUrl']方法的典型用法代码示例。如果您正苦于以下问题:Python ListItem.get_moving_data()['videoStreamUrl']方法的具体用法?Python ListItem.get_moving_data()['videoStreamUrl']怎么用?Python ListItem.get_moving_data()['videoStreamUrl']使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在common.DataObjects.ListItem的用法示例。


在下文中一共展示了ListItem.get_moving_data()['videoStreamUrl']方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: playRawVideo

# 需要导入模块: from common.DataObjects import ListItem [as 别名]
# 或者: from common.DataObjects.ListItem import get_moving_data()['videoStreamUrl'] [as 别名]
def playRawVideo(request_obj, response_obj):
    video_url = request_obj.get_data()['videoLink']
    Container().ga_client.reportAction('video')
    item = ListItem()
    item.get_moving_data()['videoStreamUrl'] = video_url
    item.set_next_action_name('Play')
    xbmcListItem = xbmcgui.ListItem(label='Streaming Video')
    item.set_xbmc_list_item_obj(xbmcListItem)
    response_obj.addListItem(item)
    response_obj.addServiceResponseParam("status", "success")
    response_obj.addServiceResponseParam("message", "Enjoy the video!")
开发者ID:shauryaanand,项目名称:desimc,代码行数:13,代码来源:PlayIt_Moves.py

示例2: playZappyVideo

# 需要导入模块: from common.DataObjects import ListItem [as 别名]
# 或者: from common.DataObjects.ListItem import get_moving_data()['videoStreamUrl'] [as 别名]
def playZappyVideo(request_obj, response_obj):
    Logger.logDebug(request_obj.get_data());
    Container().ga_client.reportAction('zappyvideo')
    video_id = request_obj.get_data()['videoId']
    port = request_obj.get_data()['port']
    ipaddress = request_obj.get_data()['client_ip']
    video_url = "http://" + ipaddress + ":" + str(port) + "/?videoId=" + video_id
    item = ListItem()
    item.get_moving_data()['videoStreamUrl'] = video_url
    item.set_next_action_name('Play')
    xbmcListItem = xbmcgui.ListItem(label='Streaming Video')
    item.set_xbmc_list_item_obj(xbmcListItem)
    response_obj.addListItem(item)
    response_obj.addServiceResponseParam("status", "success")
    response_obj.addServiceResponseParam("message", "Enjoy the video!")
开发者ID:shauryaanand,项目名称:desimc,代码行数:17,代码来源:PlayIt_Moves.py

示例3: retieveMovieStreams

# 需要导入模块: from common.DataObjects import ListItem [as 别名]
# 或者: from common.DataObjects.ListItem import get_moving_data()['videoStreamUrl'] [as 别名]
def retieveMovieStreams(request_obj, response_obj):
    soup = None
    if request_obj.get_data().has_key('movieInfoUrl'):
        html = HttpUtils.HttpClient().getHtmlContent(url=(BASE_WSITE_URL + request_obj.get_data()['movieInfoUrl'][3:]))
        soup = BeautifulSoup.BeautifulSoup(html)
    elif request_obj.get_data().has_key('moviePageUrl'):
        contentDiv = BeautifulSoup.SoupStrainer('div', {'dir':'ltr'})
        soup = HttpUtils.HttpClient().getBeautifulSoup(url=request_obj.get_data()['moviePageUrl'], parseOnlyThese=contentDiv)
    if soup == None:
        return
    videoSourceLink = None
    scriptTags = []
    
    for row in soup('script', {'type':'text/javascript'}):
        if re.search('jwplayer', ''.join(row.contents)):
             jwplayer = ''.join(row.contents)
             m_obj = re.search(r'({.*})', jwplayer)
             if m_obj:
                jwplayerStr = m_obj.group(1).replace("'", "\"")
                matches = re.search('"file": "(.+?)"', jwplayerStr, re.IGNORECASE)
                if matches:
                    videoSourceLink = matches.group(1)
                    break
    
    
    XBMCInterfaceUtils.displayDialogMessage('Do you know?', 'The content of this add-on is from www.einthusan.com.', 'Please help Einthusan by visiting his website regularly.', 'The developer has no relation with www.einthusan.com. OK to proceed!', msgType='[B]INFO & REQUEST: [/B]')
    
    item = ListItem()
    item.set_next_action_name('Play')
    item.get_moving_data()['videoStreamUrl'] = videoSourceLink
    xbmcListItem = xbmcgui.ListItem(label=request_obj.get_data()['movieTitle'])
    if(request_obj.get_data().has_key('videoInfo')):
        meta = request_obj.get_data()['videoInfo']
        xbmcListItem.setIconImage(meta['thumb_url'])
        xbmcListItem.setThumbnailImage(meta['cover_url'])
        xbmcListItem.setInfo('video', meta)
    item.set_xbmc_list_item_obj(xbmcListItem)
    response_obj.addListItem(item)
    
开发者ID:jigarsavla,项目名称:apple-tv2-xbmc,代码行数:40,代码来源:Einthusan.py


注:本文中的common.DataObjects.ListItem.get_moving_data()['videoStreamUrl']方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。