MCPcopy Index your code
hub / github.com/secdev/scapy / BitEnumField

Class BitEnumField

scapy/fields.py:2673–2696  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2671
2672
2673class BitEnumField(_BitField[Union[List[int], int]], _EnumField[int]):
2674 __slots__ = EnumField.__slots__
2675
2676 def __init__(self,
2677 name, # type: str
2678 default, # type: Optional[int]
2679 size, # type: int
2680 enum, # type: _EnumType[int]
2681 **kwargs # type: Any
2682 ):
2683 # type: (...) -> None
2684 _EnumField.__init__(self, name, default, enum)
2685 _BitField.__init__(self, name, default, size, **kwargs)
2686
2687 def any2i(self, pkt, x):
2688 # type: (Optional[Packet], Any) -> Union[List[int], int]
2689 return _EnumField.any2i(self, pkt, x)
2690
2691 def i2repr(self,
2692 pkt, # type: Optional[Packet]
2693 x, # type: Union[List[int], int]
2694 ):
2695 # type: (...) -> Any
2696 return _EnumField.i2repr(self, pkt, x)
2697
2698
2699class BitLenEnumField(BitLenField, _EnumField[int]):

Callers 15

CoAPClass · 0.90
mqttsn.pyFile · 0.90
NSHClass · 0.90
EIRP_DwellTimeClass · 0.90
MHDRClass · 0.90
DAGMCObjClass · 0.90
OpcDaHeaderMessageClass · 0.90
ErrorEstimateClass · 0.90
BFDClass · 0.90
LcEMIClass · 0.90
BGPORFEntryClass · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected