Enum async_proto::ReadError
source · pub enum ReadError {
Show 14 variants
BufSize(TryFromIntError),
Custom(String),
EndOfStream,
FloatNotFinite,
ReadNever,
UnknownVariant8(u8),
UnknownVariant16(u16),
UnknownVariant32(u32),
UnknownVariant64(u64),
UnknownVariant128(u128),
Io(Error),
Tungstenite(Error),
Utf8(FromUtf8Error),
Warp(Error),
}
Variants§
BufSize(TryFromIntError)
Received a buffer with more than usize::MAX
elements
Custom(String)
An error variant you can use when manually implementing Protocol
EndOfStream
The end of the stream was encountered before a complete value was read.
Note that this error condition may also be represented as a ReadError::Io
with kind
UnexpectedEof
.
FloatNotFinite
ReadNever
Attempted to read an empty type
UnknownVariant8(u8)
UnknownVariant16(u16)
UnknownVariant32(u32)
UnknownVariant64(u64)
UnknownVariant128(u128)
Io(Error)
Tungstenite(Error)
Available on crate feature
tokio-tungstenite
only.Utf8(FromUtf8Error)
Warp(Error)
Available on crate feature
warp
only.Trait Implementations§
source§impl Error for ReadError
impl Error for ReadError
source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
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<FromUtf8Error> for ReadError
impl From<FromUtf8Error> for ReadError
source§fn from(source: FromUtf8Error) -> Self
fn from(source: FromUtf8Error) -> Self
Converts to this type from the input type.
source§impl From<Infallible> for ReadError
impl From<Infallible> for ReadError
source§fn from(never: Infallible) -> Self
fn from(never: Infallible) -> Self
Converts to this type from the input type.
source§impl From<TryFromIntError> for ReadError
impl From<TryFromIntError> for ReadError
source§fn from(source: TryFromIntError) -> Self
fn from(source: TryFromIntError) -> Self
Converts to this type from the input type.