pub struct ArcRwLockUdpSocket(/* private fields */);Expand description
Thread-safe wrapper for UDP socket with read-write lock.
Provides synchronized access to UDP socket operations.
Implementations§
Source§impl ArcRwLockUdpSocket
Implementation of ArcRwLockUdpSocket methods.
impl ArcRwLockUdpSocket
Implementation of ArcRwLockUdpSocket methods.
Provides construction and access methods for thread-safe UDP socket.
Sourcepub fn from_socket(socket: UdpSocket) -> Self
pub fn from_socket(socket: UdpSocket) -> Self
Sourcepub async fn get_read_lock(&self) -> RwLockReadGuardUdpSocket<'_>
pub async fn get_read_lock(&self) -> RwLockReadGuardUdpSocket<'_>
Sourcepub async fn get_write_lock(&self) -> RwLockWriteGuardUdpSocket<'_>
pub async fn get_write_lock(&self) -> RwLockWriteGuardUdpSocket<'_>
Acquires a write lock on the socket.
§Returns
RwLockWriteGuardUdpSocket- Write guard for the socket.
Trait Implementations§
Source§impl Clone for ArcRwLockUdpSocket
impl Clone for ArcRwLockUdpSocket
Source§fn clone(&self) -> ArcRwLockUdpSocket
fn clone(&self) -> ArcRwLockUdpSocket
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ArcRwLockUdpSocket
impl !RefUnwindSafe for ArcRwLockUdpSocket
impl Send for ArcRwLockUdpSocket
impl Sync for ArcRwLockUdpSocket
impl Unpin for ArcRwLockUdpSocket
impl !UnwindSafe for ArcRwLockUdpSocket
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