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

Function lhex

scapy/utils.py:292–303  ·  view source on GitHub ↗
(x)

Source from the content-addressed store, hash-verified

290
291
292def lhex(x):
293 # type: (Any) -> str
294 from scapy.volatile import VolatileValue
295 if isinstance(x, VolatileValue):
296 return repr(x)
297 if isinstance(x, int):
298 return hex(x)
299 if isinstance(x, tuple):
300 return "(%s)" % ", ".join(lhex(v) for v in x)
301 if isinstance(x, list):
302 return "[%s]" % ", ".join(lhex(v) for v in x)
303 return str(x)
304
305
306@conf.commands.register

Callers 11

i2reprMethod · 0.90
i2reprMethod · 0.90
i2reprMethod · 0.90
i2reprMethod · 0.90
i2reprMethod · 0.90
i2reprMethod · 0.90
i2repr_oneMethod · 0.90
_i2reprMethod · 0.90
_i2reprMethod · 0.90
_i2reprMethod · 0.90
i2reprMethod · 0.90

Calls 1

joinMethod · 0.80

Tested by

no test coverage detected