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

Method get_string

Lib/mailbox.py:83–88  ·  view source on GitHub ↗

Return a string representation or raise a KeyError. Uses email.message.Message to create a 7bit clean string representation of the message.

(self, key)

Source from the content-addressed store, hash-verified

81 raise NotImplementedError('Method must be implemented by subclass')
82
83 def get_string(self, key):
84 """Return a string representation or raise a KeyError.
85
86 Uses email.message.Message to create a 7bit clean string
87 representation of the message."""
88 return email.message_from_bytes(self.get_bytes(key)).as_string()
89
90 def get_bytes(self, key):
91 """Return a byte string representation or raise a KeyError."""

Callers 14

test_notimplementedMethod · 0.95
test_addMethod · 0.45
test_get_stringMethod · 0.45
test_set_itemMethod · 0.45
test_clearMethod · 0.45
test_updateMethod · 0.45
_test_flush_or_closeMethod · 0.45
test_get_folderMethod · 0.45
test_get_string_fromMethod · 0.45

Calls 2

get_bytesMethod · 0.95
as_stringMethod · 0.45

Tested by 14

test_notimplementedMethod · 0.76
test_addMethod · 0.36
test_get_stringMethod · 0.36
test_set_itemMethod · 0.36
test_clearMethod · 0.36
test_updateMethod · 0.36
_test_flush_or_closeMethod · 0.36
test_get_folderMethod · 0.36
test_get_string_fromMethod · 0.36