pub struct OdinConfigBuilder { /* private fields */ }
Expand description
Builder for OdinConfig
Implementations§
Source§impl OdinConfigBuilder
impl OdinConfigBuilder
Sourcepub fn network_endpoint<S: Into<String>>(self, endpoint: S) -> Self
pub fn network_endpoint<S: Into<String>>(self, endpoint: S) -> Self
Set the network endpoint
Sourcepub fn max_connections(self, max_connections: usize) -> Self
pub fn max_connections(self, max_connections: usize) -> Self
Set the maximum number of connections
Sourcepub fn heartbeat_interval(self, interval: Duration) -> Self
pub fn heartbeat_interval(self, interval: Duration) -> Self
Set the heartbeat interval
Sourcepub fn max_retries(self, max_retries: u32) -> Self
pub fn max_retries(self, max_retries: u32) -> Self
Set the maximum retry attempts
Sourcepub fn performance_monitoring(self, enabled: bool) -> Self
pub fn performance_monitoring(self, enabled: bool) -> Self
Enable or disable performance monitoring
Sourcepub fn max_message_size(self, size: usize) -> Self
pub fn max_message_size(self, size: usize) -> Self
Set the maximum message size
Sourcepub fn buffer_size(self, size: usize) -> Self
pub fn buffer_size(self, size: usize) -> Self
Set the buffer size
Sourcepub fn build(self) -> Result<OdinConfig>
pub fn build(self) -> Result<OdinConfig>
Build the configuration
Trait Implementations§
Source§impl Debug for OdinConfigBuilder
impl Debug for OdinConfigBuilder
Source§impl Default for OdinConfigBuilder
impl Default for OdinConfigBuilder
Source§fn default() -> OdinConfigBuilder
fn default() -> OdinConfigBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for OdinConfigBuilder
impl RefUnwindSafe for OdinConfigBuilder
impl Send for OdinConfigBuilder
impl Sync for OdinConfigBuilder
impl Unpin for OdinConfigBuilder
impl UnwindSafe for OdinConfigBuilder
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