Struct tauri::api::http::ClientBuilder
source · pub struct ClientBuilder {
pub max_redirections: Option<usize>,
pub connect_timeout: Option<Duration>,
}
Available on crate feature
http-api
only.Expand description
The builder of Client
.
Fields§
§max_redirections: Option<usize>
Max number of redirections to follow.
connect_timeout: Option<Duration>
Connect timeout for the request.
Implementations§
source§impl ClientBuilder
impl ClientBuilder
sourcepub fn max_redirections(self, max_redirections: usize) -> Self
pub fn max_redirections(self, max_redirections: usize) -> Self
Sets the maximum number of redirections.
sourcepub fn connect_timeout(self, connect_timeout: Duration) -> Self
pub fn connect_timeout(self, connect_timeout: Duration) -> Self
Sets the connection timeout.
Trait Implementations§
source§impl Clone for ClientBuilder
impl Clone for ClientBuilder
source§fn clone(&self) -> ClientBuilder
fn clone(&self) -> ClientBuilder
Returns a copy of the value. Read more
1.0.0 · 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 ClientBuilder
impl Debug for ClientBuilder
source§impl Default for ClientBuilder
impl Default for ClientBuilder
source§fn default() -> ClientBuilder
fn default() -> ClientBuilder
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for ClientBuilder
impl<'de> Deserialize<'de> for ClientBuilder
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ClientBuilder
impl RefUnwindSafe for ClientBuilder
impl Send for ClientBuilder
impl Sync for ClientBuilder
impl Unpin for ClientBuilder
impl UnwindSafe for ClientBuilder
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