pub enum RedirectMode {
Follow,
Manual,
Error,
}Expand description
How a redirect response is handled, mirroring WHATWG Fetch’s
RequestInit.redirect (follow | manual | error).
Variants§
Follow
Follow up to the redirect cap (Request::max_redirects), then
error (the default).
Manual
Do not follow: the 3xx response is returned as-is (the JS layer
turns this into an opaque-redirect Response).
Error
Treat any redirect as a network error.
Trait Implementations§
Source§impl Clone for RedirectMode
impl Clone for RedirectMode
Source§fn clone(&self) -> RedirectMode
fn clone(&self) -> RedirectMode
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 moreimpl Copy for RedirectMode
Source§impl Debug for RedirectMode
impl Debug for RedirectMode
Source§impl Default for RedirectMode
impl Default for RedirectMode
Source§fn default() -> RedirectMode
fn default() -> RedirectMode
Returns the “default value” for a type. Read more
impl Eq for RedirectMode
Source§impl PartialEq for RedirectMode
impl PartialEq for RedirectMode
impl StructuralPartialEq for RedirectMode
Auto Trait Implementations§
impl Freeze for RedirectMode
impl RefUnwindSafe for RedirectMode
impl Send for RedirectMode
impl Sync for RedirectMode
impl Unpin for RedirectMode
impl UnsafeUnpin for RedirectMode
impl UnwindSafe for RedirectMode
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