Struct distant_net::client::ClientBuilder
source · pub struct ClientBuilder<H, C> { /* private fields */ }Expand description
Builder for a Client or UntypedClient.
Implementations
sourceimpl<H, C> ClientBuilder<H, C>
impl<H, C> ClientBuilder<H, C>
pub fn auth_handler<U>(self, auth_handler: U) -> ClientBuilder<U, C>
pub fn connector<U>(self, connector: U) -> ClientBuilder<H, U>
pub fn reconnect_strategy(
self,
reconnect_strategy: ReconnectStrategy
) -> ClientBuilder<H, C>
pub fn timeout(self, timeout: impl Into<Option<Duration>>) -> Self
sourceimpl<H, C> ClientBuilder<H, C>where
H: AuthHandler + Send,
C: Connector,
impl<H, C> ClientBuilder<H, C>where
H: AuthHandler + Send,
C: Connector,
sourcepub async fn connect_untyped(self) -> Result<UntypedClient>
pub async fn connect_untyped(self) -> Result<UntypedClient>
Establishes a connection with a remote server using the configured Transport
and other settings, returning a new UntypedClient instance once the connection
is fully established and authenticated.
Trait Implementations
Auto Trait Implementations
impl<H, C> RefUnwindSafe for ClientBuilder<H, C>where
C: RefUnwindSafe,
H: RefUnwindSafe,
impl<H, C> Send for ClientBuilder<H, C>where
C: Send,
H: Send,
impl<H, C> Sync for ClientBuilder<H, C>where
C: Sync,
H: Sync,
impl<H, C> Unpin for ClientBuilder<H, C>where
C: Unpin,
H: Unpin,
impl<H, C> UnwindSafe for ClientBuilder<H, C>where
C: UnwindSafe,
H: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more