pub enum Error {
BranchNotFound(String),
FastForwardOnly,
Fungus(FuError),
Git2(Error),
NoMessageWasFound,
Progress(Error),
RepoNotFound(String),
UrlNotSet,
}Expand description
Define common error wrapper type
Variants§
BranchNotFound(String)
An error indicating that the given branch was not found.
FastForwardOnly
An error indicating that only fast forwards are allowed.
Fungus(FuError)
An error from fungus which might contain more errors
Git2(Error)
Git2 wrapped error
NoMessageWasFound
An error indicating that no message was found.
Progress(Error)
RepoNotFound(String)
An error indicating that the given repo was not found.
UrlNotSet
An error indicating that the URL was not set for the repo.
Implementations§
Source§impl Error
impl Error
Sourcepub fn branch_not_found<T>(pkg: T) -> Error
pub fn branch_not_found<T>(pkg: T) -> Error
Return an error indicating that the given branch was not found.
Sourcepub fn repo_not_found<T>(repo: T) -> Error
pub fn repo_not_found<T>(repo: T) -> Error
Return an error indicating that the given repo was not found.
Sourcepub fn is<T>(&self) -> boolwhere
T: Error + 'static,
pub fn is<T>(&self) -> boolwhere
T: Error + 'static,
Implemented directly on the Error type to reduce casting required
Sourcepub fn downcast_ref<T>(&self) -> Option<&T>where
T: Error + 'static,
pub fn downcast_ref<T>(&self) -> Option<&T>where
T: Error + 'static,
Implemented directly on the Error type to reduce casting required
Sourcepub fn downcast_mut<T>(&mut self) -> Option<&mut T>where
T: Error + 'static,
pub fn downcast_mut<T>(&mut self) -> Option<&mut T>where
T: Error + 'static,
Implemented directly on the Error type to reduce casting required
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()
Source§impl From<Error> for RelicError
impl From<Error> for RelicError
Source§fn from(err: Error) -> RelicError
fn from(err: Error) -> RelicError
Converts to this type from the input type.
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