pub enum FetchOutcome<T> {
Success(T),
NotFound,
}Expand description
Typed success/absence outcome. Hard failures are Err(AcquisitionError).
NotFound is data (the exact URL is absent); the consumer decides what it
means. It never triggers fallback inside a transport.
Variants§
Success(T)
The exact URL produced a usable response.
NotFound
The exact URL is definitively absent (HTTP 404 equivalent).
Implementations§
Source§impl<T> FetchOutcome<T>
impl<T> FetchOutcome<T>
Sourcepub fn is_success(&self) -> bool
pub fn is_success(&self) -> bool
Returns true for Success.
Sourcepub fn is_not_found(&self) -> bool
pub fn is_not_found(&self) -> bool
Returns true for NotFound.
Trait Implementations§
Source§impl<T: Clone> Clone for FetchOutcome<T>
impl<T: Clone> Clone for FetchOutcome<T>
Source§impl<T: Debug> Debug for FetchOutcome<T>
impl<T: Debug> Debug for FetchOutcome<T>
impl<T: Eq> Eq for FetchOutcome<T>
Source§impl<T: PartialEq> PartialEq for FetchOutcome<T>
impl<T: PartialEq> PartialEq for FetchOutcome<T>
impl<T: PartialEq> StructuralPartialEq for FetchOutcome<T>
Auto Trait Implementations§
impl<T> Freeze for FetchOutcome<T>where
T: Freeze,
impl<T> RefUnwindSafe for FetchOutcome<T>where
T: RefUnwindSafe,
impl<T> Send for FetchOutcome<T>where
T: Send,
impl<T> Sync for FetchOutcome<T>where
T: Sync,
impl<T> Unpin for FetchOutcome<T>where
T: Unpin,
impl<T> UnsafeUnpin for FetchOutcome<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for FetchOutcome<T>where
T: UnwindSafe,
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