本文整理汇总了Python中models.Job.qsize方法的典型用法代码示例。如果您正苦于以下问题:Python Job.qsize方法的具体用法?Python Job.qsize怎么用?Python Job.qsize使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类models.Job
的用法示例。
在下文中一共展示了Job.qsize方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: get
# 需要导入模块: from models import Job [as 别名]
# 或者: from models.Job import qsize [as 别名]
def get(self, *args, **kwargs):
''' Renders the cracking queue '''
dispatch = Dispatch.Instance()
dispatch.refresh()
self.render("cracking/jobs/queued.html",
all_users=User.all_users(),
queue_size=Job.qsize()
)
示例2: __next__
# 需要导入模块: from models import Job [as 别名]
# 或者: from models.Job import qsize [as 别名]
def __next__(self):
''' Called when a weapon system completes a job '''
if 0 < Job.qsize():
self.check_queue()
示例3: __next__
# 需要导入模块: from models import Job [as 别名]
# 或者: from models.Job import qsize [as 别名]
def __next__(self, *args, **kwargs):
''' Called when a weapon system completes a job '''
if 0 < Job.qsize():
self.__queue__()
示例4: get
# 需要导入模块: from models import Job [as 别名]
# 或者: from models.Job import qsize [as 别名]
def get(self, *args, **kwargs):
''' Renders the cracking queue '''
self.render("job/queuedjobs.html", all_users=User.
get_all(), queue_size=Job.qsize())