pub struct Response { /* private fields */ }
Expand description
Contains an SMTP reply, with separated code and message
The text message is optional, only the code is mandatory
Implementations§
Source§impl Response
impl Response
Sourcepub fn is_positive(&self) -> bool
pub fn is_positive(&self) -> bool
Tells if the response is positive
Sourcepub fn first_word(&self) -> Option<&str>
pub fn first_word(&self) -> Option<&str>
Returns only the first word of the message if possible
Sourcepub fn first_line(&self) -> Option<&str>
pub fn first_line(&self) -> Option<&str>
Returns only the line of the message if possible
Trait Implementations§
impl Eq for Response
impl StructuralPartialEq for Response
Auto Trait Implementations§
impl Freeze for Response
impl RefUnwindSafe for Response
impl Send for Response
impl Sync for Response
impl Unpin for Response
impl UnwindSafe for Response
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