Methods

Summary

method

class parent

truncated documentation

__del__

BufferFilesWriting

destructor, check everything was flushed

__init__

MailBoxMock

__init__

MailBoxImap

__init__

BufferFilesWriting

constructor

__init__

EmailMessageListRenderer

__init__

EmailMessageRenderer

Defines a template based on Jinja2.

__init__

Renderer

constructor, defines a template based on Jinja2

__len__

BufferFilesWriting

return the number of buffered files

__lt__

EmailMessage

usual

__sortkey__

EmailMessage

usual

as_bytes

EmailMessage

converts the mail into a binary string

as_string

EmailMessage

Converts the mail into a string.

decode_header

EmailMessage

decode a string encoded in the header

default_filename

EmailMessage

define a default filename (no extension)

dump

EmailMessage

Dumps a message using a call such as EmailMessageRenderer.

dump_attachments

EmailMessage

Dumps the mail into a folder using HTML format. If the destination files already exists, it skips it. If …

enumerate_attachments

EmailMessage

enumerate the attachments as 4-uple (filename, content, message_id, content_id)

enumerate_mails_in_folder

MailBoxMock

enumerate all mails in a folder

enumerate_mails_in_folder

MailBoxImap

Enumerates all mails in folder folder.

enumerate_search_person

MailBoxMock

enumerates all mails in folder folder from a user or sent to a user

enumerate_search_person

MailBoxImap

Enumerates all mails in folder folder from a user or sent to a user.

enumerate_search_subject

MailBoxMock

enumerates all mails in folder folder with a subject verifying a regular expression

enumerate_search_subject

MailBoxImap

Enumerates all mails in folder folder with a subject verifying a regular expression.

exists

BufferFilesWriting

tells if a file was already written

flush

BufferFilesWriting

flush a file (actually write it) and make it disappear from the list of buffered files, if the folder does not exists, …

flush

Renderer

flushes all files

folders

MailBoxMock

returns the list of folder of the mail box

folders

MailBoxImap

Returns the list of folder of the mail box.

get_all_charsets

EmailMessage

returns all the charsets

get_date

EmailMessage

return a datetime object for the field Date

get_date_str

EmailMessage

return the date into a string

get_field

EmailMessage

get a field and cleans it

get_from

EmailMessage

returns a tuple (label, email address) or a list of groups from the regular expression

get_from_str

EmailMessage

return a string for the receivers

get_name

EmailMessage

return the sender name of an email (if available)

get_nb_attachements

EmailMessage

return the number of attachments

get_to

EmailMessage

return the receivers

get_to_str

EmailMessage

return a string for the receivers

listfiles

BufferFilesWriting

returns the list of flushed and opened files, does not preserved order

login

MailBoxMock

login (nothing to do here)

login

MailBoxImap

login

logout

MailBoxMock

logout (nothing to do here)

logout

MailBoxImap

logout

open

BufferFilesWriting

open a file and returns a buffer

process_body_html

EmailMessageRenderer

replaces link to images included in the mail body

produce_table_html

EmailMessageRenderer

produces a table with the values of some fields of the message

read_binary_content

BufferFilesWriting

return the content of file (binary format)

read_mail_from_file

MailBoxMock

extract a mail from a file

render

EmailMessageListRenderer

Renders a mail.

render

EmailMessageRenderer

Renders a mail.

render

Renderer

render a mail

to_dict

EmailMessage

Returns all fields for an emails as a dictionary

write

EmailMessageListRenderer

Writes a list of mails in a folder and writes a summary.

write

EmailMessageRenderer

Writes a mail, the function assumes the attachments were already dumped.

write

Renderer

writes a mail, the function assumes the attachments were already dumped