#[non_exhaustive]pub enum KeyResolutionError {
Unsupported(Box<KeyReference>),
Failed(Box<dyn Error + Send + Sync + 'static>),
}Expand description
Why a KeyResolver found no key.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Unsupported(Box<KeyReference>)
The resolver does not handle this kind of reference.
Failed(Box<dyn Error + Send + Sync + 'static>)
The resolver handles the reference and could not find or use the key.
Implementations§
Source§impl KeyResolutionError
impl KeyResolutionError
Sourcepub fn unsupported(key: &KeyReference) -> Self
pub fn unsupported(key: &KeyReference) -> Self
The resolver does not handle key.
Sourcepub fn is_unsupported(&self) -> bool
pub fn is_unsupported(&self) -> bool
Whether the resolver does not handle the reference.
Trait Implementations§
Source§impl Debug for KeyResolutionError
impl Debug for KeyResolutionError
Source§impl Display for KeyResolutionError
impl Display for KeyResolutionError
Source§impl Error for KeyResolutionError
impl Error for KeyResolutionError
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<DereferenceError> for KeyResolutionError
impl From<DereferenceError> for KeyResolutionError
Source§fn from(error: DereferenceError) -> Self
fn from(error: DereferenceError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for KeyResolutionError
impl !UnwindSafe for KeyResolutionError
impl Freeze for KeyResolutionError
impl Send for KeyResolutionError
impl Sync for KeyResolutionError
impl Unpin for KeyResolutionError
impl UnsafeUnpin for KeyResolutionError
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