pub struct PostRedirections { /* private fields */ }
Expand description
Structure which stores possible post redirection options to pass to post_redirections
.
Implementations§
Source§impl PostRedirections
impl PostRedirections
Sourcepub fn new() -> PostRedirections
pub fn new() -> PostRedirections
Create an empty PostRedirection setting with no flags set.
Sourcepub fn redirect_301(&mut self, on: bool) -> &mut PostRedirections
pub fn redirect_301(&mut self, on: bool) -> &mut PostRedirections
Configure POST method behaviour on a 301 redirect. Setting the value to true will preserve the method when following the redirect, else the method is changed to GET.
Sourcepub fn redirect_302(&mut self, on: bool) -> &mut PostRedirections
pub fn redirect_302(&mut self, on: bool) -> &mut PostRedirections
Configure POST method behaviour on a 302 redirect. Setting the value to true will preserve the method when following the redirect, else the method is changed to GET.
Sourcepub fn redirect_303(&mut self, on: bool) -> &mut PostRedirections
pub fn redirect_303(&mut self, on: bool) -> &mut PostRedirections
Configure POST method behaviour on a 303 redirect. Setting the value to true will preserve the method when following the redirect, else the method is changed to GET.
Sourcepub fn redirect_all(&mut self, on: bool) -> &mut PostRedirections
pub fn redirect_all(&mut self, on: bool) -> &mut PostRedirections
Configure POST method behaviour for all redirects. Setting the value to true will preserve the method when following the redirect, else the method is changed to GET.