[−][src]Struct mail_smtp::MailRequest
This type contains a mail and potentially some envelop data.
It is needed as in some edge cases the smtp envelop data (i.e. smtp from and smtp recipient) can not be correctly derived from the mail.
The default usage is to directly turn a Mail
into a MailRequest
by either using MailRequest::new
, MailRequest::from
or Mail::into
.
Implementations
impl MailRequest
[src]
pub fn new(mail: Mail) -> Self
[src]
creates a new MailRequest
from a Mail
instance
pub fn new_with_envelop(mail: Mail, envelop: EnvelopData) -> Self
[src]
create a new MailRequest
and use custom smtp EnvelopData
Note that envelop data comes from new-tokio-smtp::send_mail
and
is not re-exported so if you happen to run into one of the view
cases where you need to set it manually just import it from
new-tokio-smtp
.
pub fn override_envelop(&mut self, envelop: EnvelopData) -> Option<EnvelopData>
[src]
replace the smtp EnvelopData
pub fn _into_mail_with_envelop(self) -> Result<(Mail, EnvelopData), MailError>
[src]
Trait Implementations
impl Clone for MailRequest
[src]
fn clone(&self) -> MailRequest
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for MailRequest
[src]
impl From<Mail> for MailRequest
[src]
Auto Trait Implementations
impl !RefUnwindSafe for MailRequest
impl Send for MailRequest
impl Sync for MailRequest
impl Unpin for MailRequest
impl !UnwindSafe for MailRequest
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Erased for T
impl<T> From<T> for T
[src]
impl<T> HeaderTryFrom<T> for T
[src]
fn try_from(val: T) -> Result<T, ComponentCreationError>
[src]
impl<F, T> HeaderTryInto<T> for F where
T: HeaderTryFrom<F>,
[src]
T: HeaderTryFrom<F>,
fn try_into(self) -> Result<T, ComponentCreationError>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,