Struct trackable::error::Failure [−][src]
pub struct Failure(_);
TrackableError type specialized for Failed.
Methods
impl Failure[src]
impl Failurepub fn from_error<E>(error: E) -> Self where
E: Into<BoxError>, [src]
pub fn from_error<E>(error: E) -> Self where
E: Into<BoxError>, Makes a new Failure instance which was caused by the error.
Methods from Deref<Target = TrackableError<Failed>>
pub fn kind(&self) -> &K[src]
pub fn kind(&self) -> &KReturns the kind of this error.
pub fn concrete_cause<T>(&self) -> Option<&T> where
T: Error + 'static, [src]
pub fn concrete_cause<T>(&self) -> Option<&T> where
T: Error + 'static, Tries to return the cause of this error as a value of T type.
If neither this error has a cause nor it is an T value,
this method will return None.
Trait Implementations
impl Debug for Failure[src]
impl Debug for Failurefn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl Clone for Failure[src]
impl Clone for Failurefn clone(&self) -> Failure[src]
fn clone(&self) -> FailureReturns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)Performs copy-assignment from source. Read more
impl Deref for Failure[src]
impl Deref for Failuretype Target = TrackableError<Failed>
The resulting type after dereferencing.
fn deref(&self) -> &Self::Target[src]
fn deref(&self) -> &Self::TargetDereferences the value.
impl Display for Failure[src]
impl Display for Failurefn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl Error for Failure[src]
impl Error for Failurefn description(&self) -> &str[src]
fn description(&self) -> &strThis method is soft-deprecated. Read more
fn cause(&self) -> Option<&Error>[src]
fn cause(&self) -> Option<&Error>The lower-level cause of this error, if any. Read more
impl Trackable for Failure[src]
impl Trackable for Failuretype Event = Location
Event type which a history of an instance of this type can have.
fn history(&self) -> Option<&History<Self::Event>>[src]
fn history(&self) -> Option<&History<Self::Event>>Returns the reference of the tracking history of this instance. Read more
fn history_mut(&mut self) -> Option<&mut History<Self::Event>>[src]
fn history_mut(&mut self) -> Option<&mut History<Self::Event>>Returns the mutable reference of the tracking history of this instance. Read more
fn track<F>(&mut self, f: F) where
F: FnOnce() -> Self::Event, [src]
fn track<F>(&mut self, f: F) where
F: FnOnce() -> Self::Event, Add an event into the tail of the history of this instance. Read more
fn in_tracking(&self) -> bool[src]
fn in_tracking(&self) -> boolReturns true if it is being tracked, otherwise false.
impl From<TrackableError<Failed>> for Failure[src]
impl From<TrackableError<Failed>> for Failurefn from(f: TrackableError<Failed>) -> Self[src]
fn from(f: TrackableError<Failed>) -> SelfPerforms the conversion.
impl From<Failure> for TrackableError<Failed>[src]
impl From<Failure> for TrackableError<Failed>impl From<Failed> for Failure[src]
impl From<Failed> for Failureimpl From<Failure> for IoError[src]
impl From<Failure> for IoError