pub struct ChainError {
pub attempts: Vec<Attempt>,
pub chain_len: usize,
}Expand description
No provider produced an answer, with what each one contributed.
attempts is never empty: ProviderChain::new rejects an empty chain, so
a file that could not be analyzed always names at least one provider. It can
be shorter than chain_len — a 401 at the head stops the chain, and the
providers below it were never consulted.
chain_len is carried so the caller can tell “the only provider failed”
from “a chain stopped early”, which are the same attempts.len() == 1 but
very different questions for the user.
Fields§
§attempts: Vec<Attempt>§chain_len: usizeTrait Implementations§
Auto Trait Implementations§
impl Freeze for ChainError
impl RefUnwindSafe for ChainError
impl Send for ChainError
impl Sync for ChainError
impl Unpin for ChainError
impl UnsafeUnpin for ChainError
impl UnwindSafe for ChainError
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