#[non_exhaustive]pub enum NegotiationError {
NoSubprotocol,
UnsupportedSubprotocol,
NotOffered(Version),
}Expand description
Why subprotocol negotiation failed.
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.
NoSubprotocol
The server did not send Sec-WebSocket-Protocol. Part 4 §3.1.2 requires it; the
connection must be closed.
UnsupportedSubprotocol
The server selected a subprotocol that is not an OCPP one.
NotOffered(Version)
The server selected a version the client did not offer.
Trait Implementations§
Source§impl Clone for NegotiationError
impl Clone for NegotiationError
impl Copy for NegotiationError
Source§impl Debug for NegotiationError
impl Debug for NegotiationError
Source§impl Display for NegotiationError
impl Display for NegotiationError
impl Eq for NegotiationError
Source§impl Error for NegotiationError
Available on crate feature std only.
impl Error for NegotiationError
Available on crate feature
std only.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 PartialEq for NegotiationError
impl PartialEq for NegotiationError
impl StructuralPartialEq for NegotiationError
Auto Trait Implementations§
impl Forget for NegotiationError
impl Freeze for NegotiationError
impl RefUnwindSafe for NegotiationError
impl Send for NegotiationError
impl Sync for NegotiationError
impl Unpin for NegotiationError
impl UnsafeUnpin for NegotiationError
impl UnwindSafe for NegotiationError
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