MCPcopy Index your code
hub / github.com/python/cpython / add

Method add

Lib/mailbox.py:1333–1338  ·  view source on GitHub ↗

Add message and return assigned key.

(self, message)

Source from the content-addressed store, hash-verified

1331 self._labels = {}
1332
1333 def add(self, message):
1334 """Add message and return assigned key."""
1335 key = _singlefileMailbox.add(self, message)
1336 if isinstance(message, BabylMessage):
1337 self._labels[key] = message.get_labels()
1338 return key
1339
1340 def remove(self, key):
1341 """Remove the keyed message; raise KeyError if it doesn't exist."""

Callers

nothing calls this directly

Calls 2

addMethod · 0.45
get_labelsMethod · 0.45

Tested by

no test coverage detected