pub struct ServicesConfigBuilder(/* private fields */);
Expand description
A builder type for ServiceConfig
.
Implementations§
source§impl ServicesConfigBuilder
impl ServicesConfigBuilder
sourcepub fn service(&mut self, name: &str, config: ServiceConfig) -> &mut Self
pub fn service(&mut self, name: &str, config: ServiceConfig) -> &mut Self
Adds a service to the builder.
sourcepub fn security(&mut self, security: SecurityConfig) -> &mut Self
pub fn security(&mut self, security: SecurityConfig) -> &mut Self
Sets the security configuration.
sourcepub fn proxy(&mut self, proxy: ProxyConfig) -> &mut Self
pub fn proxy(&mut self, proxy: ProxyConfig) -> &mut Self
Sets the proxy configuration.
sourcepub fn connect_timeout(&mut self, connect_timeout: Duration) -> &mut Self
pub fn connect_timeout(&mut self, connect_timeout: Duration) -> &mut Self
Sets the connect timeout.
sourcepub fn read_timeout(&mut self, read_timeout: Duration) -> &mut Self
pub fn read_timeout(&mut self, read_timeout: Duration) -> &mut Self
Sets the read timeout.
sourcepub fn write_timeout(&mut self, write_timeout: Duration) -> &mut Self
pub fn write_timeout(&mut self, write_timeout: Duration) -> &mut Self
Sets the write timeout.
sourcepub fn backoff_slot_size(&mut self, backoff_slot_size: Duration) -> &mut Self
pub fn backoff_slot_size(&mut self, backoff_slot_size: Duration) -> &mut Self
Sets the backoff slot size.
sourcepub fn build(&self) -> ServicesConfig
pub fn build(&self) -> ServicesConfig
Creates a new ServicesConfig
.
Trait Implementations§
source§impl Default for ServicesConfigBuilder
impl Default for ServicesConfigBuilder
source§fn default() -> ServicesConfigBuilder
fn default() -> ServicesConfigBuilder
Returns the “default value” for a type. Read more
source§impl From<ServicesConfig> for ServicesConfigBuilder
impl From<ServicesConfig> for ServicesConfigBuilder
source§fn from(config: ServicesConfig) -> ServicesConfigBuilder
fn from(config: ServicesConfig) -> ServicesConfigBuilder
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ServicesConfigBuilder
impl RefUnwindSafe for ServicesConfigBuilder
impl Send for ServicesConfigBuilder
impl Sync for ServicesConfigBuilder
impl Unpin for ServicesConfigBuilder
impl UnwindSafe for ServicesConfigBuilder
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