pub struct FileTransport { /* private fields */ }Available on crate feature
file-transport only.Expand description
Writes the content and the envelope information to a file
Implementations§
Source§impl FileTransport
impl FileTransport
Sourcepub fn new<P: AsRef<Path>>(path: P) -> FileTransport
pub fn new<P: AsRef<Path>>(path: P) -> FileTransport
Creates a new transport to the given directory
Writes the email content in eml format.
Sourcepub fn with_envelope<P: AsRef<Path>>(path: P) -> FileTransport
Available on crate feature file-transport-envelope only.
pub fn with_envelope<P: AsRef<Path>>(path: P) -> FileTransport
file-transport-envelope only.Creates a new transport to the given directory
Writes the email content in eml format and the envelope in json format.
Trait Implementations§
Source§impl Clone for FileTransport
impl Clone for FileTransport
Source§fn clone(&self) -> FileTransport
fn clone(&self) -> FileTransport
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FileTransport
impl Debug for FileTransport
Source§impl<'de> Deserialize<'de> for FileTransport
impl<'de> Deserialize<'de> for FileTransport
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for FileTransport
impl Serialize for FileTransport
Source§impl Transport for FileTransport
impl Transport for FileTransport
fn send_raw( &self, envelope: &Envelope, email: &[u8], ) -> Result<Self::Ok, Self::Error>
Source§fn send(&self, message: &Message) -> Result<Self::Ok, Self::Error>
fn send(&self, message: &Message) -> Result<Self::Ok, Self::Error>
Available on crate feature
builder only.Sends the email
Source§fn shutdown(&self)
fn shutdown(&self)
Shuts down the transport. Future calls to
Self::send and
Self::send_raw might fail.Auto Trait Implementations§
impl Freeze for FileTransport
impl RefUnwindSafe for FileTransport
impl Send for FileTransport
impl Sync for FileTransport
impl Unpin for FileTransport
impl UnsafeUnpin for FileTransport
impl UnwindSafe for FileTransport
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more