本文整理汇总了Python中translator.base.simpletype.SimpleType.__init__方法的典型用法代码示例。如果您正苦于以下问题:Python SimpleType.__init__方法的具体用法?Python SimpleType.__init__怎么用?Python SimpleType.__init__使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类translator.base.simpletype.SimpleType
的用法示例。
在下文中一共展示了SimpleType.__init__方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
# 需要导入模块: from translator.base.simpletype import SimpleType [as 别名]
# 或者: from translator.base.simpletype.SimpleType import __init__ [as 别名]
def __init__(self, ifc_key='ScanningThreatRate', asa_key = ScanningThreatDetection.THREAT_DETECTION_SCANNING_RATE):
'''Constructor'''
self.extra_cli = None
SimpleType.__init__(self, ifc_key = ifc_key, asa_key = asa_key,
asa_gen_template = ScanningThreatDetection.THREAT_DETECTION_SCANNING_RATE + ' rate-interval %(rate_interval)s average-rate %(average_rate)s burst-rate %(burst_rate)s',
response_parser = ScanningThreatDetection.ignore_msg_response_parser)
示例2: __init__
# 需要导入模块: from translator.base.simpletype import SimpleType [as 别名]
# 或者: from translator.base.simpletype.SimpleType import __init__ [as 别名]
def __init__(self, name, asa_key = "flow-export destination"):
'''Constructor'''
self.interface = None
SimpleType.__init__(self, name, asa_key,
asa_gen_template = 'flow-export destination %(interface)s %(host)s %(port)s',
response_parser = TemplateAndCollectors.ignore_msg_response_parser)
示例3: __init__
# 需要导入模块: from translator.base.simpletype import SimpleType [as 别名]
# 或者: from translator.base.simpletype.SimpleType import __init__ [as 别名]
def __init__(self, name):
SimpleType.__init__(
self,
name,
asa_gen_template="failover link %(interface_name)s %(interface)s",
response_parser=failover_response_parser,
)
示例4: __init__
# 需要导入模块: from translator.base.simpletype import SimpleType [as 别名]
# 或者: from translator.base.simpletype.SimpleType import __init__ [as 别名]
def __init__(self):
'''
Constructor
'''
SimpleType.__init__(self, ifc_key = 'IPSSettings', asa_key = 'ips',
asa_gen_template='ips %(operate_mode)s %(fail_mode)s',
response_parser = cli_interaction.ignore_warning_response_parser)
示例5: __init__
# 需要导入模块: from translator.base.simpletype import SimpleType [as 别名]
# 或者: from translator.base.simpletype.SimpleType import __init__ [as 别名]
def __init__(self, ifc_key='BasicThreatDetectionRateAclDrop', asa_key='threat-detection rate acl-drop'):
'''Constructor '''
self.rate_type = None
self.extra_cli = None
SimpleType.__init__(self, ifc_key, asa_key,
asa_gen_template = 'threat-detection rate %(rate)s rate-interval %(rate_interval)s average-rate %(average_rate)s burst-rate %(burst_rate)s',
response_parser = cli_interaction.ignore_warning_response_parser)
示例6: __init__
# 需要导入模块: from translator.base.simpletype import SimpleType [as 别名]
# 或者: from translator.base.simpletype.SimpleType import __init__ [as 别名]
def __init__(self, name):
'''@todo: use Route.__init__ instead of SimpleType.__init__
Route.__init__(self, name, defaults=None, asa_gen_template = 'ipv6 route %(interface)s %(prefix)s %(gateway)s')
'''
SimpleType.__init__(self, name,
asa_gen_template = 'ipv6 route %(interface)s %(prefix)s %(gateway)s %(hop_count)s %(tunneled)s',
defaults = {'hop_count': '', 'tunneled': ''},
response_parser = static_route_response_parser)
示例7: __init__
# 需要导入模块: from translator.base.simpletype import SimpleType [as 别名]
# 或者: from translator.base.simpletype.SimpleType import __init__ [as 别名]
def __init__(self):
SimpleType.__init__(self, ifc_key = 'health_check',
asa_key = 'health-check',
asa_mode_template = 'cluster group %(group_name)s',
asa_gen_template = 'health-check holdtime %(health_check)s')
示例8: __init__
# 需要导入模块: from translator.base.simpletype import SimpleType [as 别名]
# 或者: from translator.base.simpletype.SimpleType import __init__ [as 别名]
def __init__(self):
SimpleType.__init__(
self,
ifc_key=AccessGroupGlobal.__name__,
asa_key='access-group',
asa_gen_template='access-group %(access_list_name)s global')
示例9: __init__
# 需要导入模块: from translator.base.simpletype import SimpleType [as 别名]
# 或者: from translator.base.simpletype.SimpleType import __init__ [as 别名]
def __init__(self):
'''
Constructor
'''
SimpleType.__init__(self, 'timeout_idle', 'set connection timeout idle', asa_gen_template='set connection timeout idle %(idle_time)s', defaults={'idle_time': IDLE_TIME_DEFAULT})
示例10: __init__
# 需要导入模块: from translator.base.simpletype import SimpleType [as 别名]
# 或者: from translator.base.simpletype.SimpleType import __init__ [as 别名]
def __init__(self, name, asa_key):
'''Constructor'''
self.stat_type = name[len('AdvancedThreatDetection'):].lower()
self.folder_name = name
SimpleType.__init__(self, name, asa_key,
response_parser = cli_interaction.ignore_warning_response_parser)