pub enum Error {
Show 14 variants
OpenFile(Error, PathBuf),
CreateFile(Error, PathBuf),
ReadFileMetadata(Error, PathBuf),
GetFileModified(Error, PathBuf),
DeserializeLine(Error, String),
ReadLine(Error, usize, String),
SeekOffset(Error, usize, String),
IntoOffset(u64, usize, String),
Seek(Error, PathBuf),
ReadLineOffset(Error, u64, PathBuf),
Csv(Error),
DecodeDetails {
source: Error,
file: PathBuf,
offset: u64,
line: String,
},
ReadCache(Error, PathBuf),
WriteCache(Error, PathBuf),
}
Expand description
Represents an error that can occur in this crate.
Variants§
OpenFile(Error, PathBuf)
An I/O error occurred when opening a file.
CreateFile(Error, PathBuf)
An I/O error occurred when creating a file.
ReadFileMetadata(Error, PathBuf)
An I/O error occurred when reading file metadata.
GetFileModified(Error, PathBuf)
An I/O error occurred when getting the file modification time.
DeserializeLine(Error, String)
A deserialization error occurred for a line.
ReadLine(Error, usize, String)
An I/O error occurred when reading a line.
SeekOffset(Error, usize, String)
An I/O error occurred when seeking for an offset of a line.
IntoOffset(u64, usize, String)
An offset conversion error occurred.
Seek(Error, PathBuf)
An I/O error occurred when seeking in a file.
ReadLineOffset(Error, u64, PathBuf)
An I/O error occurred when reading a line as an offset.
Csv(Error)
A CSV error occurred.
DecodeDetails
A CSV decoding error occurred with details.
Fields
ReadCache(Error, PathBuf)
An error occurred when reading from the cache.
WriteCache(Error, PathBuf)
An error occurred when writing to the cache.
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)>
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()
Auto Trait Implementations§
impl Freeze for Error
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