pub enum EmailError {
Http(Error),
Api {
status: u16,
message: String,
},
}Variants§
Http(Error)
The HTTP layer failed before we got a response — network down, DNS failure, TLS handshake, that sort of thing.
Api
The API replied with a non-2xx status. message is whatever the server
put in the response body (typically { "message": "..." }), or the HTTP
reason phrase if the body wasn’t readable.
Trait Implementations§
Source§impl Debug for EmailError
impl Debug for EmailError
Source§impl Display for EmailError
impl Display for EmailError
Source§impl Error for EmailError
impl Error for EmailError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for EmailError
impl !UnwindSafe for EmailError
impl Freeze for EmailError
impl Send for EmailError
impl Sync for EmailError
impl Unpin for EmailError
impl UnsafeUnpin for EmailError
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