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

Method __reduce__

scapy/packet.py:246–256  ·  view source on GitHub ↗

Used by pickling methods

(self)

Source from the content-addressed store, hash-verified

244 self.comments = None
245
246 def __reduce__(self):
247 # type: () -> Tuple[Type[Packet], Tuple[bytes], Packet._PickleType]
248 """Used by pickling methods"""
249 return (self.__class__, (self.build(),), (
250 self.time,
251 self.sent_time,
252 self.direction,
253 self.sniffed_on,
254 self.wirelen,
255 self.comment
256 ))
257
258 def __setstate__(self, state):
259 # type: (Packet._PickleType) -> Packet

Callers

nothing calls this directly

Calls 1

buildMethod · 0.95

Tested by

no test coverage detected