Source code for pcapkit.const.mh.fb_indication_trigger
# -*- coding: utf-8 -*-# pylint: disable=line-too-long,consider-using-f-string"""Flow Binding Indication Triggers======================================.. module:: pcapkit.const.mh.fb_indication_triggerThis module contains the constant enumeration for **Flow Binding Indication Triggers**,which is automatically generated from :class:`pcapkit.vendor.mh.fb_indication_trigger.FlowBindingIndicationTrigger`."""fromaenumimportIntEnum,extend_enum__all__=['FlowBindingIndicationTrigger']
[docs]classFlowBindingIndicationTrigger(IntEnum):"""[FlowBindingIndicationTrigger] Flow Binding Indication Triggers"""#: Reserved [:rfc:`7109`]Reserved_0=0#: Unspecified [:rfc:`7109`]Unspecified=1#: Administrative Reason [:rfc:`7109`]Administrative_Reason=2#: Possible Out-of-Sync BCE State [:rfc:`7109`]Possible_Out_of_Sync_BCE_State=3@staticmethoddefget(key:'int | str',default:'int'=-1)->'FlowBindingIndicationTrigger':"""Backport support for original codes. Args: key: Key to get enum item. default: Default value if not found. :meta private: """ifisinstance(key,int):returnFlowBindingIndicationTrigger(key)ifkeynotinFlowBindingIndicationTrigger._member_map_:# pylint: disable=no-memberreturnextend_enum(FlowBindingIndicationTrigger,key,default)returnFlowBindingIndicationTrigger[key]# type: ignore[misc]
[docs]@classmethoddef_missing_(cls,value:'int')->'FlowBindingIndicationTrigger':"""Lookup function used when value is not found. Args: value: Value to get enum item. """ifnot(isinstance(value,int)and0<=value<=255):raiseValueError('%r is not a valid %s'%(value,cls.__name__))if4<=value<=249:#: Unassignedreturnextend_enum(cls,'Unassigned_%d'%value,value)if250<=value<=255:#: Reserved for Testing Purposes Only [:rfc:`7109`]returnextend_enum(cls,'Reserved_for_Testing_Purposes_Only_%d'%value,value)returnsuper()._missing_(value)