Enum websockets::WebSocketError [−][src]
pub enum WebSocketError {}Show 21 variants
TcpConnectionError(IoError), TlsConnectionError(NativeTlsError), TlsBuilderError(NativeTlsError), TlsConfigurationError(NativeTlsError), WebSocketClosedError, ShutdownError(IoError), InvalidHandshakeError, HandshakeFailedError { status_code: String, headers: Vec<(String, String)>, body: Option<String>, }, ControlFrameTooLargeError, PayloadTooLargeError, InvalidFrameError, ReceivedMaskedFrameError, ParseError(ParseError), SchemeError, HostError, PortError, SocketAddrError(IoError), ResolutionError, ReadError(IoError), WriteError(IoError), ChannelError,
Expand description
The possible error types from the WebSocket connection.
Variants
TcpConnectionError(IoError)
Error connecting using TCP
TlsConnectionError(NativeTlsError)
Error connecting using TLS
TlsBuilderError(NativeTlsError)
Error building WebSocket with given TLS configuration
TlsConfigurationError(NativeTlsError)
Error creating a TLS configuration (such as in method calls on
TlsCertificate
or
TlsIdentity
)
Attempted to use the WebSocket when it is already closed
ShutdownError(IoError)
Error shutting down the internal stream
Invalid handshake response from the server
The server rejected the handshake request
Fields of HandshakeFailedError
Attempted to use a control frame whose payload is more than 125 bytes
Attempted to use a frame whose payload is too large
Received an invalid frame
Received a masked frame from the server
ParseError(ParseError)
URL could not be parsed
URL has invalid WebSocket scheme (use “ws” or “wss”)
URL host is invalid or missing
URL port is invalid
SocketAddrError(IoError)
Could not parse URL into SocketAddrs
Could not resolve the URL’s domain
ReadError(IoError)
Error reading from WebSocket
WriteError(IoError)
Error writing to WebSocket
Issue with mpsc channel