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

Method __len__

Lib/mailbox.py:1152–1154  ·  view source on GitHub ↗

Return a count of messages in the mailbox.

(self)

Source from the content-addressed store, hash-verified

1150 return os.path.exists(os.path.join(self._path, str(key)))
1151
1152 def __len__(self):
1153 """Return a count of messages in the mailbox."""
1154 return len(list(self.iterkeys()))
1155
1156 def _open_mh_sequences_file(self, text):
1157 mode = '' if text else 'b'

Callers

nothing calls this directly

Calls 2

iterkeysMethod · 0.95
listClass · 0.85

Tested by

no test coverage detected