Struct scutiger_core::errors::Error [−][src]
pub struct Error { /* fields omitted */ }
Implementations
impl Error
[src]
impl Error
[src]pub fn new<E: Into<Box<dyn Error + Send + Sync>>>(
kind: ErrorKind,
error: Option<E>
) -> Self
[src]
pub fn new<E: Into<Box<dyn Error + Send + Sync>>>(
kind: ErrorKind,
error: Option<E>
) -> Self
[src]Create a new error.
If this error was caused by another error, specify it as Some(error)
.
pub fn new_simple(kind: ErrorKind) -> Self
[src]
pub fn new_simple(kind: ErrorKind) -> Self
[src]Create a new error without wrapping any other error.
pub fn from_message<M: Into<String>>(kind: ErrorKind, msg: M) -> Self
[src]
pub fn from_message<M: Into<String>>(kind: ErrorKind, msg: M) -> Self
[src]Create a new error without wrapping any other error.
pub fn io_kind(&self) -> ErrorKind
[src]
pub fn io_kind(&self) -> ErrorKind
[src]Return the kind of this error when converted into an io::Error
.
If the internal error is an io::Error
, returns its kind; otherwise, returns the kind it
would have if it were converted into an io::Error
.
pub fn fatal(&self) -> bool
[src]
pub fn fatal(&self) -> bool
[src]Indicate whether this error is considered fatal.
An error is fatal if it results in an exit of 2 or higher. A missing revision is not considered fatal, but other errors are.
pub fn exit_status(&self) -> ExitStatus
[src]
pub fn exit_status(&self) -> ExitStatus
[src]Return the exit status for this error.
Trait Implementations
impl Error for Error
[src]
impl Error for Error
[src]fn description(&self) -> &str
[src]
fn description(&self) -> &str
[src]👎 Deprecated since 1.42.0:
use the Display impl or to_string()
fn source(&self) -> Option<&(dyn Error + 'static)>
1.30.0[src]
fn source(&self) -> Option<&(dyn Error + 'static)>
1.30.0[src]The lower-level source of this error, if any. Read more
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
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more