pub enum Error {
Show 16 variants
Custom(String),
ParseMissingAttribute {
tag: String,
attr: String,
},
ParseUnknownDirectiveTag {
tag: String,
},
ApplyPathNotFound {
op: String,
path: String,
},
ApplyNoChanges {
file_path: String,
},
SecurityViolation {
target: String,
base_dir: String,
},
DiffyParsePatch {
path: String,
cause: String,
patch: String,
},
DiffyApplyPatch {
path: String,
cause: String,
patch: String,
},
PatchCompletion {
cause: String,
},
IoReadFile(PathAndCause),
IoCreateFile(PathAndCause),
IoWriteFile(PathAndCause),
IoRenamePath {
from_path: String,
to_path: String,
cause: String,
},
IoDeleteFile(PathAndCause),
IoDeleteDirAll(PathAndCause),
SimpleFs {
cause: String,
},
}Variants§
Custom(String)
ParseMissingAttribute
ParseUnknownDirectiveTag
ApplyPathNotFound
ApplyNoChanges
SecurityViolation
DiffyParsePatch
DiffyApplyPatch
PatchCompletion
IoReadFile(PathAndCause)
IoCreateFile(PathAndCause)
IoWriteFile(PathAndCause)
IoRenamePath
IoDeleteFile(PathAndCause)
IoDeleteDirAll(PathAndCause)
SimpleFs
Implementations§
Source§impl Error
impl Error
pub fn parse_missing_attribute( tag: impl Into<String>, attr: impl Into<String>, ) -> Self
pub fn parse_unknown_directive_tag(tag: impl Into<String>) -> Self
pub fn apply_path_not_found( op: impl Into<String>, path: impl Into<String>, ) -> Self
pub fn apply_no_changes(file_path: impl Into<String>) -> Self
pub fn security_violation( target: impl Into<String>, base_dir: impl Into<String>, ) -> Self
pub fn io_read_file(path: impl Into<String>, err: impl Error) -> Self
pub fn io_create_file(path: impl Into<String>, err: impl Error) -> Self
pub fn io_write_file(path: impl Into<String>, err: impl Error) -> Self
pub fn io_rename_path( from_path: impl Into<String>, to_path: impl Into<String>, err: impl Error, ) -> Self
pub fn io_delete_file(path: impl Into<String>, err: impl Error) -> Self
pub fn io_delete_dir_all(path: impl Into<String>, err: impl Error) -> Self
pub fn simple_fs(err: impl Error) -> Self
pub fn diffy_parse_patch( path: impl Into<String>, err: impl Error, patch: impl Into<String>, ) -> Self
pub fn diffy_apply_patch( path: impl Into<String>, err: impl Error, patch: impl Into<String>, ) -> Self
pub fn patch_completion(cause: impl Into<String>) -> Self
Trait Implementations§
Source§impl Error for Error
impl Error for Error
1.30.0 · 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