pub enum ServerError {
TcpBind(String),
Tls(String),
MissingTlsForHttp3,
Unknown(String),
HttpRead(String),
InvalidHttpRequest(Request),
Other(String),
}Expand description
Represents errors that can occur at the server level.
Variants§
TcpBind(String)
An error occurred while trying to bind to a TCP socket.
Tls(String)
An error occurred while loading or configuring TLS material.
MissingTlsForHttp3
HTTP/3 was selected without TLS, which the protocol requires.
Unknown(String)
An unknown or unexpected error occurred.
HttpRead(String)
An error occurred while reading an HTTP request.
InvalidHttpRequest(Request)
The received HTTP request was invalid or malformed.
Other(String)
Other error.
Trait Implementations§
Source§impl Clone for ServerError
impl Clone for ServerError
Source§impl<'de> Deserialize<'de> for ServerError
impl<'de> Deserialize<'de> for ServerError
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 Display for ServerError
impl Display for ServerError
impl Eq for ServerError
Source§impl Error for ServerError
Implements the standard error trait for ServerError.
impl Error for ServerError
Implements the standard error trait for ServerError.
1.30.0 · 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()
Source§impl From<Error> for ServerError
Implementation of From trait for converting external errors into ServerError.
impl From<Error> for ServerError
Implementation of From trait for converting external errors into ServerError.
This allows using the ? operator to automatically convert IoError
into ServerError::TcpBind when binding to a TCP socket.
Source§impl PartialEq for ServerError
impl PartialEq for ServerError
Source§impl Serialize for ServerError
impl Serialize for ServerError
impl StructuralPartialEq for ServerError
Auto Trait Implementations§
impl Forget for ServerError
impl Freeze for ServerError
impl Move for ServerError
impl RefUnwindSafe for ServerError
impl Send for ServerError
impl Sync for ServerError
impl Unpin for ServerError
impl UnsafeUnpin for ServerError
impl UnwindSafe for ServerError
Blanket Implementations§
impl<T> AnySend for T
impl<T> AnySendClone for T
impl<T> AnySendSync for T
impl<T> AnySendSyncClone for T
impl<T> AnySync for T
impl<T> AnySyncClone for T
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.