diff options
author | Barry Warsaw <barry@python.org> | 2002-09-30 23:07:35 (GMT) |
---|---|---|
committer | Barry Warsaw <barry@python.org> | 2002-09-30 23:07:35 (GMT) |
commit | 48330687f36bb452e17480e78bf3ca17f9728e87 (patch) | |
tree | 4d88e808655c21175c6669d83e30a1b6df84c225 /Lib/email/Header.py | |
parent | 0031982c21af37d8d208f07c19352d32af944222 (diff) | |
download | cpython-48330687f36bb452e17480e78bf3ca17f9728e87.zip cpython-48330687f36bb452e17480e78bf3ca17f9728e87.tar.gz cpython-48330687f36bb452e17480e78bf3ca17f9728e87.tar.bz2 |
Docstring consistency with the updated .tex files.
Diffstat (limited to 'Lib/email/Header.py')
-rw-r--r-- | Lib/email/Header.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Lib/email/Header.py b/Lib/email/Header.py index 0f2eb32..a40226d 100644 --- a/Lib/email/Header.py +++ b/Lib/email/Header.py @@ -205,11 +205,12 @@ class Header: s may be a byte string or a Unicode string. If it is a byte string (i.e. isinstance(s, StringType) is true), then charset is the encoding of that byte string, and a UnicodeError will be raised if the string - cannot be decoded with that charset. If `s' is a Unicode string, then + cannot be decoded with that charset. If s is a Unicode string, then charset is a hint specifying the character set of the characters in the string. In this case, when producing an RFC 2822 compliant header using RFC 2047 rules, the Unicode string will be encoded using the - following charsets in order: us-ascii, the charset hint, utf-8. + following charsets in order: us-ascii, the charset hint, utf-8. The + first character set not to provoke a UnicodeError is used. """ if charset is None: charset = self._charset @@ -376,7 +377,7 @@ class Header: return joiner.join(chunks) def encode(self): - """Encode a message header, possibly converting charset and encoding. + """Encode a message header into an RFC-compliant format. There are many issues involved in converting a given string for use in an email header. Only certain character sets are readable in most |