pub struct TermsError(/* private fields */);Expand description
What terms fails with: what Terms refuses, or the source’s own
failure.
A source reports through Error::source whichever sink it feeds, so
every failure arrives as a SourceError. term
recovers a TermError from it, the same downcast a caller makes on
EncryptError::Source when Terms runs beside encryption, and
refusal a value refused for its shape, which
encryption reports as EncryptError::Shape.
source_error is the error as it arrived.
Implementations§
Source§impl TermsError
impl TermsError
Sourcepub fn term(&self) -> Option<&TermError>
pub fn term(&self) -> Option<&TermError>
The scalar Terms refused, or None if the source failed on its
own or the value was refused for its shape.
Sourcepub fn refusal(&self) -> Option<&Refusal>
pub fn refusal(&self) -> Option<&Refusal>
The value refused for its shape, as encryption would refuse it, or
None if it was refused for another reason.
Sourcepub fn source_error(&self) -> &SourceError
pub fn source_error(&self) -> &SourceError
The failure as the walk reported it: what Terms refused, or the
source’s own error.
Trait Implementations§
Source§impl Debug for TermsError
impl Debug for TermsError
Source§impl Display for TermsError
impl Display for TermsError
Source§impl Error for TermsError
impl Error for TermsError
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()