Home
last modified time | relevance | path

Searched refs:header_factory (Results 1 – 8 of 8) sorted by relevance

/third_party/python/Lib/test/test_email/
Dtest_policy.py36 'header_factory': email.policy.EmailPolicy.header_factory,
64 policies[new_policy]['header_factory'] = new_policy.header_factory
211 h = email.policy.default.header_factory('Test', 'test')
222 policy1.header_factory.map_to_type('foo', self.Foo)
223 h = policy1.header_factory('foo', 'test')
226 h = policy2.header_factory('foo', 'test')
233 policy1.header_factory.map_to_type('foo', self.Foo)
234 h = policy1.header_factory('foo', 'test')
236 h = policy2.header_factory('foo', 'test')
241 myfactory = mypolicy.header_factory
[all …]
Dtest_pickleable.py15 header_factory = HeaderRegistry() variable in TestPickleCopyHeader
17 unstructured = header_factory('subject', 'this is a test')
27 header = self.header_factory(name, value)
32 header = self.header_factory(name, value)
Dtest_contentmanager.py671 header_factory = self.policy.header_factory
673 header_factory("To", "foo@example.com"),
674 header_factory("From", "foo@example.com"),
675 header_factory("Subject", "I'm talking to myself.")))
712 header_factory = self.policy.header_factory
715 header_factory("Content-Type", " foo/bar"),)
730 header_factory = self.policy.header_factory
733 header_factory('To', 'a@fairly@@invalid@address'),)
/third_party/python/Lib/email/
Dpolicy.py90 header_factory = HeaderRegistry() variable in EmailPolicy
106 return self.header_factory[name].max_count
148 return (name, self.header_factory(name, value))
163 return self.header_factory(name, value)
214 return self.header_factory(name, ''.join(lines)).fold(policy=self)
220 del default.header_factory
Dcontentmanager.py100 headers = [mp.header_factory(*mp.header_source_parse([header]))
/third_party/python/Doc/library/
Demail.headerregistry.rst18 :attr:`~email.policy.EmailPolicy.header_factory` of the :mod:`~email.policy` in
20 ``header_factory`` implemented by the email package for handling :RFC:`5322`
45 :attr:`~email.policy.EmailPolicy.header_factory` call. The string value of
55 :attr:`~email.policy.EmailPolicy.header_factory` call for *name*; that
Demail.policy.rst417 .. attribute:: header_factory
422 default ``header_factory`` (see :mod:`~email.headerregistry`) is provided
467 ``header_factory``, and the resulting header object is returned as
476 removed, are passed to the ``header_factory``, and the resulting
489 to the ``header_factory``. Folding of a header object is done by
/third_party/python/Doc/whatsnew/
D3.3.rst1277 header_factory A callable that take a ``name`` and ``value`` and
1281 The ``header_factory`` is the key to the new features provided by the new
1283 a ``Message`` object is an object produced by the ``header_factory``, and any
1285 ``header_factory``. All such header objects have a ``name`` attribute equal