pub enum Error {
NotFound(String),
PermissionDenied(String),
Io(Error),
InvalidPath(String),
DiskNotConfigured(String),
NotImplemented(String),
Serialization(String),
}Expand description
Storage error types.
Variants§
NotFound(String)
File not found.
PermissionDenied(String)
Permission denied.
Io(Error)
IO error.
InvalidPath(String)
Invalid path.
DiskNotConfigured(String)
Disk not configured.
NotImplemented(String)
Feature not yet implemented.
Serialization(String)
Serialization error.
Implementations§
Source§impl Error
impl Error
Sourcepub fn permission_denied(msg: impl Into<String>) -> Self
pub fn permission_denied(msg: impl Into<String>) -> Self
Create a permission denied error.
Sourcepub fn invalid_path(path: impl Into<String>) -> Self
pub fn invalid_path(path: impl Into<String>) -> Self
Create an invalid path error.
Sourcepub fn disk_not_configured(disk: impl Into<String>) -> Self
pub fn disk_not_configured(disk: impl Into<String>) -> Self
Create a disk not configured error.
Sourcepub fn not_implemented(feature: impl Into<String>) -> Self
pub fn not_implemented(feature: impl Into<String>) -> Self
Create a not implemented 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)>
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 UnsafeUnpin 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