Expand description
Next action suggested after before_request()
Variants
Fresh(Parts)
Good news! You can use it with body from the cache. No need to contact the server.
Stale
Fields
request: Parts
Send this request to the server (it has added revalidation headers when appropriate)
matches: bool
If false
, request was for some other resource that isn’t
semantically the same as previously cached request+response
You must send the request to the server first.
Implementations
sourceimpl BeforeRequest
impl BeforeRequest
sourcepub fn satisfies_without_revalidation(&self) -> bool
pub fn satisfies_without_revalidation(&self) -> bool
For backwards compatibility only.
Don’t forget to use request headers from BeforeRequest::Fresh
Auto Trait Implementations
impl !RefUnwindSafe for BeforeRequest
impl Send for BeforeRequest
impl Sync for BeforeRequest
impl Unpin for BeforeRequest
impl !UnwindSafe for BeforeRequest
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more