pub struct Builder<T>(/* private fields */);Expand description
A builder for ServiceConfig
Implementations§
Source§impl Builder<Complete>
impl Builder<Complete>
Sourcepub fn uris(self, uris: impl IntoIterator<Item = Url>) -> Builder<Complete>
pub fn uris(self, uris: impl IntoIterator<Item = Url>) -> Builder<Complete>
Sets the uris field.
Sourcepub fn extend_uris(
self,
uris: impl IntoIterator<Item = Url>,
) -> Builder<Complete>
pub fn extend_uris( self, uris: impl IntoIterator<Item = Url>, ) -> Builder<Complete>
Adds values to the uris field.
Sourcepub fn security(
self,
security: impl Into<Option<SecurityConfig>>,
) -> Builder<Complete>
pub fn security( self, security: impl Into<Option<SecurityConfig>>, ) -> Builder<Complete>
Sets the security field.
Sourcepub fn proxy(self, proxy: impl Into<Option<ProxyConfig>>) -> Builder<Complete>
pub fn proxy(self, proxy: impl Into<Option<ProxyConfig>>) -> Builder<Complete>
Sets the proxy field.
Sourcepub fn connect_timeout(
self,
connect_timeout: impl Into<Option<Duration>>,
) -> Builder<Complete>
pub fn connect_timeout( self, connect_timeout: impl Into<Option<Duration>>, ) -> Builder<Complete>
Sets the connect_timeout field.
Sourcepub fn read_timeout(
self,
read_timeout: impl Into<Option<Duration>>,
) -> Builder<Complete>
pub fn read_timeout( self, read_timeout: impl Into<Option<Duration>>, ) -> Builder<Complete>
Sets the read_timeout field.
Sourcepub fn write_timeout(
self,
write_timeout: impl Into<Option<Duration>>,
) -> Builder<Complete>
pub fn write_timeout( self, write_timeout: impl Into<Option<Duration>>, ) -> Builder<Complete>
Sets the write_timeout field.
Sourcepub fn backoff_slot_size(
self,
backoff_slot_size: impl Into<Option<Duration>>,
) -> Builder<Complete>
pub fn backoff_slot_size( self, backoff_slot_size: impl Into<Option<Duration>>, ) -> Builder<Complete>
Sets the backoff_slot_size field.
Sourcepub fn max_num_retries(
self,
max_num_retries: impl Into<Option<u32>>,
) -> Builder<Complete>
pub fn max_num_retries( self, max_num_retries: impl Into<Option<u32>>, ) -> Builder<Complete>
Sets the max_num_retries field.
Sourcepub fn build(self) -> ServiceConfig
pub fn build(self) -> ServiceConfig
Consumes the builder, returning a ServiceConfig.
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for Builder<T>where
T: Freeze,
impl<T> RefUnwindSafe for Builder<T>where
T: RefUnwindSafe,
impl<T> Send for Builder<T>where
T: Send,
impl<T> Sync for Builder<T>where
T: Sync,
impl<T> Unpin for Builder<T>where
T: Unpin,
impl<T> UnwindSafe for Builder<T>where
T: UnwindSafe,
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more