pub trait MailDispatch: Debug {
    fn open_mail_body<'a, 's, 'f>(
        &'a self,
        session: &'s mut SmtpSession
    ) -> S1Fut<'f, DispatchResult>
    where
        'a: 'f,
        's: 'f
; }
Expand description

A mail dispatch allows us to dispatch an e-mail. For a given mail transacton it puts a Write sink for receiving mail data into the Transaction. Once the sink is closed successfully, the mail is dispatched.

Required methods

Add a mail data sink to mail transaction.

This call may fail for various reasons, resulting in permanent or temporary refusal to send the mail after the DATA command.

Finishing the mail transaction is marked by sucessfully closing the mail data sink.

Implementors