本文整理汇总了Python中hackathon.RequiredFeature.get_basic_property方法的典型用法代码示例。如果您正苦于以下问题:Python RequiredFeature.get_basic_property方法的具体用法?Python RequiredFeature.get_basic_property怎么用?Python RequiredFeature.get_basic_property使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类hackathon.RequiredFeature
的用法示例。
在下文中一共展示了RequiredFeature.get_basic_property方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: is_pre_allocate_enabled
# 需要导入模块: from hackathon import RequiredFeature [as 别名]
# 或者: from hackathon.RequiredFeature import get_basic_property [as 别名]
def is_pre_allocate_enabled(hackathon):
if hackathon.status != HACK_STATUS.ONLINE:
return False
hack_manager = RequiredFeature("hackathon_manager")
value = hack_manager.get_basic_property(hackathon, HACKATHON_BASIC_INFO.PRE_ALLOCATE_ENABLED, "1")
return util.str2bool(value)
示例2: get_basic_property
# 需要导入模块: from hackathon import RequiredFeature [as 别名]
# 或者: from hackathon.RequiredFeature import get_basic_property [as 别名]
def get_basic_property(hackathon, property_name, default_value=None):
hack_manager = RequiredFeature("hackathon_manager")
return hack_manager.get_basic_property(hackathon, property_name, default_value)
示例3: is_auto_approve
# 需要导入模块: from hackathon import RequiredFeature [as 别名]
# 或者: from hackathon.RequiredFeature import get_basic_property [as 别名]
def is_auto_approve(hackathon):
hack_manager = RequiredFeature("hackathon_manager")
value = hack_manager.get_basic_property(hackathon, HACKATHON_CONFIG.AUTO_APPROVE, "1")
return util.str2bool(value)
示例4: get_pre_allocate_number
# 需要导入模块: from hackathon import RequiredFeature [as 别名]
# 或者: from hackathon.RequiredFeature import get_basic_property [as 别名]
def get_pre_allocate_number(hackathon):
hack_manager = RequiredFeature("hackathon_manager")
value = hack_manager.get_basic_property(hackathon, HACKATHON_CONFIG.PRE_ALLOCATE_NUMBER, 1)
return int(value)
示例5: is_alauda_enabled
# 需要导入模块: from hackathon import RequiredFeature [as 别名]
# 或者: from hackathon.RequiredFeature import get_basic_property [as 别名]
def is_alauda_enabled(hackathon):
hack_manager = RequiredFeature("hackathon_manager")
value = hack_manager.get_basic_property(hackathon, HACKATHON_BASIC_INFO.ALAUDA_ENABLED, "0")
return util.str2bool(value)
示例6: is_alauda_enabled
# 需要导入模块: from hackathon import RequiredFeature [as 别名]
# 或者: from hackathon.RequiredFeature import get_basic_property [as 别名]
def is_alauda_enabled(hackathon):
hack_manager = RequiredFeature("hackathon_manager")
return hack_manager.get_basic_property(hackathon, HACKATHON_BASIC_INFO.ALAUDA_ENABLED, False)