MCPcopy Index your code
hub / github.com/RustPython/RustPython / __init__

Method __init__

Lib/mailbox.py:1715–1722  ·  view source on GitHub ↗

Initialize an mboxMMDFMessage instance.

(self, message=None)

Source from the content-addressed store, hash-verified

1713 _type_specific_attributes = ['_from']
1714
1715 def __init__(self, message=None):
1716 """Initialize an mboxMMDFMessage instance."""
1717 self.set_from('MAILER-DAEMON', True)
1718 if isinstance(message, email.message.Message):
1719 unixfrom = message.get_unixfrom()
1720 if unixfrom is not None and unixfrom.startswith('From '):
1721 self.set_from(unixfrom[5:])
1722 Message.__init__(self, message)
1723
1724 def get_from(self):
1725 """Return contents of "From " line."""

Callers

nothing calls this directly

Calls 5

set_fromMethod · 0.95
isinstanceFunction · 0.85
get_unixfromMethod · 0.80
startswithMethod · 0.45
__init__Method · 0.45

Tested by

no test coverage detected