pub trait Mailable: Send + Sync {
// Required methods
fn envelope(&self) -> Envelope;
fn content(&self) -> Content;
// Provided method
fn build(&self, email: Email) -> Email { ... }
}Expand description
Laravel-style mailable: describe envelope + content, send via Email::send_mail.
Required Methods§
Provided Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".