diff options
author | Patrick Totzke <patricktotzke@gmail.com> | 2012-03-11 18:55:25 +0000 |
---|---|---|
committer | Patrick Totzke <patricktotzke@gmail.com> | 2012-03-11 18:55:25 +0000 |
commit | 858150d88011af09bac9b0c7cb2c45190aa8574f (patch) | |
tree | ff463b4635233b295334c272a3f9c42ba6b659ab /alot/db | |
parent | c5d5fc97d47921b6a004349f09007727a3a629cd (diff) |
docs: for db.utils
Diffstat (limited to 'alot/db')
-rw-r--r-- | alot/db/utils.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/alot/db/utils.py b/alot/db/utils.py index 0b034da0..4e8ab904 100644 --- a/alot/db/utils.py +++ b/alot/db/utils.py @@ -16,6 +16,16 @@ from alot.helper import string_decode def extract_headers(mail, headers=None): + """ + returns subset of this messages headers as human-readable format: + all header values are decoded, the resulting string has + one line "KEY: VALUE" for each requested header present in the mail. + + :param mail: the mail to use + :type mail: :class:`email.Message` + :param headers: headers to extract + :type headers: list of str + """ headertext = u'' if headers == None: headers = mail.keys() |