#[non_exhaustive]pub enum ConnectionError {
Local {
error: LocalError,
},
Remote(ConnectionErrorIncoming),
Timeout,
}
Expand description
This enum represents the closure of a connection because of an a closed quic connection This can be either from this endpoint because of a violation of the protocol or from the remote endpoint
When the code Code::H3_NO_ERROR
is used bei this peer or the remote peer, the connection is closed without an error
according to the h3 spec
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Local
The error occurred on the local side of the connection
Fields
This variant is marked as non-exhaustive
Non-exhaustive enum variants could have additional fields added in future. Therefore, non-exhaustive enum variants cannot be constructed in external crates and cannot be matched against.
§
error: LocalError
The error
Remote(ConnectionErrorIncoming)
Error returned by the quic layer I might be an quic error or the remote h3 connection closed the connection with an error
Timeout
Timeout occurred
Implementations§
Source§impl ConnectionError
impl ConnectionError
Sourcepub fn is_h3_no_error(&self) -> bool
pub fn is_h3_no_error(&self) -> bool
Returns if the error is H3_NO_ERROR local or remote
Trait Implementations§
Source§impl Clone for ConnectionError
impl Clone for ConnectionError
Source§fn clone(&self) -> ConnectionError
fn clone(&self) -> ConnectionError
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ConnectionError
impl Debug for ConnectionError
Source§impl Display for ConnectionError
impl Display for ConnectionError
Source§impl Error for ConnectionError
impl Error for ConnectionError
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()
Auto Trait Implementations§
impl Freeze for ConnectionError
impl !RefUnwindSafe for ConnectionError
impl Send for ConnectionError
impl Sync for ConnectionError
impl Unpin for ConnectionError
impl !UnwindSafe for ConnectionError
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