pub enum Error {
Show 14 variants
InvalidInformationElementIdentifier(u8),
InvalidProtocolRevisionNumber(u8),
InvalidTimeOfSession,
Io(Error),
OverallMessageLength(usize),
NegativeTimestamp(i64),
NoHeader,
NotADirectory(PathBuf),
NoPayload,
PayloadTooLong(usize),
TwoHeaders(Header, Header),
TwoPayloads(Vec<u8>, Vec<u8>),
UnknownSessionStatus(u8),
Walkdir(Error),
}
Expand description
Crate-specific error enum.
Variants§
InvalidInformationElementIdentifier(u8)
The identifier is invalid.
InvalidProtocolRevisionNumber(u8)
The message has an invalid protocol revision number.
InvalidTimeOfSession
Invalid time of session.
Io(Error)
IO error.
OverallMessageLength(usize)
The overall message length is too big.
NegativeTimestamp(i64)
The timestamp is negative.
NoHeader
There is no header in the message.
NotADirectory(PathBuf)
The path is not a directory.
NoPayload
There is no payload in the message.
PayloadTooLong(usize)
The payload is too long.
TwoHeaders(Header, Header)
There are two headers in the message.
TwoPayloads(Vec<u8>, Vec<u8>)
There are two payloads in the message.
UnknownSessionStatus(u8)
Unknown session status code.
Walkdir(Error)
Walkdir error.
Trait Implementations§
source§impl Error for Error
impl Error for Error
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()
Auto Trait Implementations§
impl !RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl !UnwindSafe for Error
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