[−][src]Struct new_tokio_smtp::ReversePath
represents a reverse path, most times this is just a mail address
Note that this type is not supposed to contain the surrounding '<'
and '>'
.
They will be added automatically.
Note that this can be an empty string, representing a empty reverse path
(donated in smtp with <>
).
Note that currently no parser is implemented and that the
allowed grammar of the forward path changes depending on
the EsmtKeywords
in EHLO and on the parameters of the
the MAIL
command it's used in. This and the fact that
part of the grammar of reverse paths are discouraged to
be used makes it a bit of a wast of time to implement the
grammar here. Through send_mail
actually does know about
SMTPUTF8
and keeps track of it.
Implementations
impl ReversePath
[src]
pub fn as_str(&self) -> &str
[src]
return the inner representation as &str
pub fn from_unchecked<I>(data: I) -> Self where
I: Into<String>,
[src]
I: Into<String>,
create a new instance from a string without validating the input
impl ReversePath
[src]
pub fn empty() -> Self
[src]
creates an empty reverse path
In a mail command this will lead to "MAIL FROM:<>"
.
Note that the '<'
,'>'
are not part of the content
so the content is an empty string.
use new_tokio_smtp::ReversePath; let rpath = ReversePath::empty(); assert_eq!(rpath.as_str(), "");
Trait Implementations
impl AsRef<str> for ReversePath
[src]
impl Clone for ReversePath
[src]
fn clone(&self) -> ReversePath
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for ReversePath
[src]
impl Eq for ReversePath
[src]
impl From<MailAddress> for ReversePath
[src]
fn from(addr: MailAddress) -> ReversePath
[src]
impl Hash for ReversePath
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl Into<String> for ReversePath
[src]
impl<'a> PartialEq<&'a str> for ReversePath
[src]
impl PartialEq<ReversePath> for ReversePath
[src]
fn eq(&self, other: &ReversePath) -> bool
[src]
fn ne(&self, other: &ReversePath) -> bool
[src]
impl PartialEq<String> for ReversePath
[src]
impl PartialEq<str> for ReversePath
[src]
impl StructuralEq for ReversePath
[src]
impl StructuralPartialEq for ReversePath
[src]
Auto Trait Implementations
impl RefUnwindSafe for ReversePath
impl Send for ReversePath
impl Sync for ReversePath
impl Unpin for ReversePath
impl UnwindSafe for ReversePath
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> From<T> for T
[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>,