pub struct SocketClientBuilder<S: State = Empty> { /* private fields */ }Expand description
Use builder syntax to set the inputs and finish with connect().
Implementations§
Source§impl<S: State> SocketClientBuilder<S>
impl<S: State> SocketClientBuilder<S>
Sourcepub async fn connect(self) -> Result<SocketClient>where
S: IsComplete,
pub async fn connect(self) -> Result<SocketClient>where
S: IsComplete,
Finishes building and performs the requested action.
Sourcepub fn config(self, value: SocketConfig) -> SocketClientBuilder<SetConfig<S>>where
S::Config: IsUnset,
pub fn config(self, value: SocketConfig) -> SocketClientBuilder<SetConfig<S>>where
S::Config: IsUnset,
Required.
Sourcepub fn post_reconnection(
self,
value: Arc<dyn Fn() + Send + Sync>,
) -> SocketClientBuilder<SetPostReconnection<S>>where
S::PostReconnection: IsUnset,
pub fn post_reconnection(
self,
value: Arc<dyn Fn() + Send + Sync>,
) -> SocketClientBuilder<SetPostReconnection<S>>where
S::PostReconnection: IsUnset,
Sourcepub fn maybe_post_reconnection(
self,
value: Option<Arc<dyn Fn() + Send + Sync>>,
) -> SocketClientBuilder<SetPostReconnection<S>>where
S::PostReconnection: IsUnset,
pub fn maybe_post_reconnection(
self,
value: Option<Arc<dyn Fn() + Send + Sync>>,
) -> SocketClientBuilder<SetPostReconnection<S>>where
S::PostReconnection: IsUnset,
Sourcepub fn state_sink(
self,
value: SocketStateSink,
) -> SocketClientBuilder<SetStateSink<S>>where
S::StateSink: IsUnset,
pub fn state_sink(
self,
value: SocketStateSink,
) -> SocketClientBuilder<SetStateSink<S>>where
S::StateSink: IsUnset,
Sourcepub fn maybe_state_sink(
self,
value: Option<SocketStateSink>,
) -> SocketClientBuilder<SetStateSink<S>>where
S::StateSink: IsUnset,
pub fn maybe_state_sink(
self,
value: Option<SocketStateSink>,
) -> SocketClientBuilder<SetStateSink<S>>where
S::StateSink: IsUnset,
Sourcepub fn reconnect_replay(
self,
value: SocketReconnectReplay,
) -> SocketClientBuilder<SetReconnectReplay<S>>where
S::ReconnectReplay: IsUnset,
pub fn reconnect_replay(
self,
value: SocketReconnectReplay,
) -> SocketClientBuilder<SetReconnectReplay<S>>where
S::ReconnectReplay: IsUnset,
Sourcepub fn maybe_reconnect_replay(
self,
value: Option<SocketReconnectReplay>,
) -> SocketClientBuilder<SetReconnectReplay<S>>where
S::ReconnectReplay: IsUnset,
pub fn maybe_reconnect_replay(
self,
value: Option<SocketReconnectReplay>,
) -> SocketClientBuilder<SetReconnectReplay<S>>where
S::ReconnectReplay: IsUnset,
Auto Trait Implementations§
impl<S = Empty> !RefUnwindSafe for SocketClientBuilder<S>
impl<S = Empty> !UnwindSafe for SocketClientBuilder<S>
impl<S> Freeze for SocketClientBuilder<S>
impl<S> Send for SocketClientBuilder<S>
impl<S> Sync for SocketClientBuilder<S>
impl<S> Unpin for SocketClientBuilder<S>
impl<S> UnsafeUnpin for SocketClientBuilder<S>
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