pub enum HandshakeError {
InvalidMethod {
method: String,
},
InvalidVersion {
version: String,
},
MissingHeader {
header: String,
},
InvalidHeaderValue {
header: String,
value: String,
},
UnsupportedSubprotocol {
protocol: String,
},
UnsupportedExtension {
extension: String,
},
InvalidOrigin {
origin: String,
},
KeyMismatch,
AuthenticationFailed {
reason: String,
},
}Expand description
Handshake errors
Variants§
InvalidMethod
Invalid request method
InvalidVersion
Invalid WebSocket version
MissingHeader
Missing required header
InvalidHeaderValue
Invalid header value
UnsupportedSubprotocol
Unsupported subprotocol
UnsupportedExtension
Unsupported extension
InvalidOrigin
Invalid origin
KeyMismatch
Key mismatch
AuthenticationFailed
Authentication failed
Trait Implementations§
Source§impl Debug for HandshakeError
impl Debug for HandshakeError
Source§impl Display for HandshakeError
impl Display for HandshakeError
Source§impl Error for HandshakeError
impl Error for HandshakeError
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<HandshakeError> for ServerError
impl From<HandshakeError> for ServerError
Source§fn from(source: HandshakeError) -> Self
fn from(source: HandshakeError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for HandshakeError
impl RefUnwindSafe for HandshakeError
impl Send for HandshakeError
impl Sync for HandshakeError
impl Unpin for HandshakeError
impl UnwindSafe for HandshakeError
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