pub enum Error {
ConnectionFailed,
ConnectionClosed,
Timeout,
NackReceived,
VerificationFailed,
IOError(Error),
Other(String),
}Expand description
Failure modes that can occur while running an crate::app::App or
expressing an Interest through an crate::app::AppHandler.
Variants§
ConnectionFailed
Connecting to the local NFD forwarder failed, e.g. the Unix socket doesn’t exist or NFD isn’t running.
ConnectionClosed
The connection to NFD was closed, either by NFD or because a background task exited. The app cannot continue after this.
Timeout
An expressed Interest didn’t receive a Data or NACK before its
InterestLifetime elapsed.
NackReceived
The producer (or forwarder) NACKed the Interest, e.g. because it failed the producer’s verifier or no route matched.
VerificationFailed
A Data packet was received but rejected by the caller-supplied
crate::verifier::DataVerifier.
IOError(Error)
Reading from or writing to the NFD connection failed at the OS level.
Other(String)
A catch-all for errors that don’t fit the other variants.
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)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for Error
impl !UnwindSafe for Error
impl Freeze for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnsafeUnpin 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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more