pub enum FetchEvent {
BodyWanted,
Head(HttpHead),
Data(Vec<u8>),
End,
Failed(String),
}Expand description
What happens to a request, in order: (for a streamed body) any number
of BodyWanted; then Head, Data… and End — or Failed at any
point.
Variants§
BodyWanted
A streamed body’s next chunk is wanted: first when the stack is ready to send, then each time the last chunk was handed on.
Head(HttpHead)
The response’s status and headers arrived.
Data(Vec<u8>)
Bytes of the response body, in order.
End
The body is complete.
Failed(String)
The request failed (no response, or the body broke off).
Trait Implementations§
Source§impl Clone for FetchEvent
impl Clone for FetchEvent
Source§fn clone(&self) -> FetchEvent
fn clone(&self) -> FetchEvent
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FetchEvent
impl Debug for FetchEvent
impl Eq for FetchEvent
Source§impl PartialEq for FetchEvent
impl PartialEq for FetchEvent
impl StructuralPartialEq for FetchEvent
Auto Trait Implementations§
impl Freeze for FetchEvent
impl RefUnwindSafe for FetchEvent
impl Send for FetchEvent
impl Sync for FetchEvent
impl Unpin for FetchEvent
impl UnsafeUnpin for FetchEvent
impl UnwindSafe for FetchEvent
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.