pub trait Session {
// Required methods
fn reset(&mut self);
fn logout(&mut self) -> Result<()>;
fn mail<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
from: &'life1 str,
opts: &'life2 MailOptions,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn rcpt<'life0, 'life1, 'async_trait>(
&'life0 mut self,
to: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn data<'life0, 'async_trait, R>(
&'life0 mut self,
r: R,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where R: 'async_trait + AsyncRead + Send + Unpin,
Self: 'async_trait,
'life0: 'async_trait;
// Provided method
fn auth_plain(&mut self, username: &str, password: &str) -> Result<()> { ... }
}
Required Methods§
fn reset(&mut self)
fn logout(&mut self) -> Result<()>
fn mail<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
from: &'life1 str,
opts: &'life2 MailOptions,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn rcpt<'life0, 'life1, 'async_trait>(
&'life0 mut self,
to: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn data<'life0, 'async_trait, R>( &'life0 mut self, r: R, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.