本文整理匯總了Python中ACEStream.Core.DownloadConfig.DownloadConfigInterface.set_live_buffer_time方法的典型用法代碼示例。如果您正苦於以下問題:Python DownloadConfigInterface.set_live_buffer_time方法的具體用法?Python DownloadConfigInterface.set_live_buffer_time怎麽用?Python DownloadConfigInterface.set_live_buffer_time使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類ACEStream.Core.DownloadConfig.DownloadConfigInterface
的用法示例。
在下文中一共展示了DownloadConfigInterface.set_live_buffer_time方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: set_live_buffer_time
# 需要導入模塊: from ACEStream.Core.DownloadConfig import DownloadConfigInterface [as 別名]
# 或者: from ACEStream.Core.DownloadConfig.DownloadConfigInterface import set_live_buffer_time [as 別名]
def set_live_buffer_time(self, value):
if DEBUG:
log('DownloadRuntimeConfig::set_live_buffer_time', binascii.hexlify(self.get_hash()), value)
self.dllock.acquire()
try:
if self.sd is not None:
set_live_buffer_time_lambda = lambda : self.sd is not None and self.sd.set_live_buffer_time(value)
self.session.lm.rawserver.add_task(set_live_buffer_time_lambda, 0)
if self.dd is not None:
set_live_buffer_time_lambda = lambda : self.dd is not None and self.dd.set_live_buffer_time(value)
self.session.lm.rawserver.add_task(set_live_buffer_time_lambda, 0)
DownloadConfigInterface.set_live_buffer_time(self, value)
finally:
self.dllock.release()