pub struct DgramSocketBuilder<S: State = Empty> { /* private fields */ }
Expand description
Use builder syntax to set the inputs and finish with build()
.
Implementations§
Source§impl<S: State> DgramSocketBuilder<S>
impl<S: State> DgramSocketBuilder<S>
Sourcepub fn build(self) -> DgramSocketwhere
S: IsComplete,
pub fn build(self) -> DgramSocketwhere
S: IsComplete,
Finish building and return the requested object
Sourcepub fn id(self, value: String) -> DgramSocketBuilder<SetId<S>>where
S::Id: IsUnset,
pub fn id(self, value: String) -> DgramSocketBuilder<SetId<S>>where
S::Id: IsUnset,
Required.
Sourcepub fn local_host(self, value: String) -> DgramSocketBuilder<SetLocalHost<S>>where
S::LocalHost: IsUnset,
pub fn local_host(self, value: String) -> DgramSocketBuilder<SetLocalHost<S>>where
S::LocalHost: IsUnset,
Required.
Sourcepub fn local_port(self, value: usize) -> DgramSocketBuilder<SetLocalPort<S>>where
S::LocalPort: IsUnset,
pub fn local_port(self, value: usize) -> DgramSocketBuilder<SetLocalPort<S>>where
S::LocalPort: IsUnset,
Required.
Sourcepub fn remote_host(self, value: String) -> DgramSocketBuilder<SetRemoteHost<S>>where
S::RemoteHost: IsUnset,
pub fn remote_host(self, value: String) -> DgramSocketBuilder<SetRemoteHost<S>>where
S::RemoteHost: IsUnset,
Sourcepub fn maybe_remote_host(
self,
value: Option<String>,
) -> DgramSocketBuilder<SetRemoteHost<S>>where
S::RemoteHost: IsUnset,
pub fn maybe_remote_host(
self,
value: Option<String>,
) -> DgramSocketBuilder<SetRemoteHost<S>>where
S::RemoteHost: IsUnset,
Sourcepub fn remote_port(self, value: u16) -> DgramSocketBuilder<SetRemotePort<S>>where
S::RemotePort: IsUnset,
pub fn remote_port(self, value: u16) -> DgramSocketBuilder<SetRemotePort<S>>where
S::RemotePort: IsUnset,
Sourcepub fn maybe_remote_port(
self,
value: Option<u16>,
) -> DgramSocketBuilder<SetRemotePort<S>>where
S::RemotePort: IsUnset,
pub fn maybe_remote_port(
self,
value: Option<u16>,
) -> DgramSocketBuilder<SetRemotePort<S>>where
S::RemotePort: IsUnset,
Auto Trait Implementations§
impl<S> Freeze for DgramSocketBuilder<S>
impl<S> RefUnwindSafe for DgramSocketBuilder<S>
impl<S> Send for DgramSocketBuilder<S>
impl<S> Sync for DgramSocketBuilder<S>
impl<S> Unpin for DgramSocketBuilder<S>
impl<S> UnwindSafe for DgramSocketBuilder<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