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

Method __init__

Lib/email/_policybase.py:50–62  ·  view source on GitHub ↗

Create new Policy, possibly overriding some defaults. See class docstring for a list of overridable attributes.

(self, **kw)

Source from the content-addressed store, hash-verified

48 """
49
50 def __init__(self, **kw):
51 """Create new Policy, possibly overriding some defaults.
52
53 See class docstring for a list of overridable attributes.
54
55 """
56 for name, value in kw.items():
57 if hasattr(self, name):
58 super(_PolicyBase,self).__setattr__(name, value)
59 else:
60 raise TypeError(
61 "{!r} is an invalid keyword argument for {}".format(
62 name, self.__class__.__name__))
63
64 def __repr__(self):
65 args = [ "{}={!r}".format(name, value)

Callers

nothing calls this directly

Calls 4

superClass · 0.85
itemsMethod · 0.45
__setattr__Method · 0.45
formatMethod · 0.45

Tested by

no test coverage detected