pub struct ClientConnectionHandle { /* private fields */ }Expand description
Connection handle for managing connections
Implementations§
Source§impl ClientConnectionHandle
impl ClientConnectionHandle
Sourcepub fn new(id: u64, connection: ClientConnection) -> Self
pub fn new(id: u64, connection: ClientConnection) -> Self
Create a new connection handle
Sourcepub fn connection(&self) -> &Arc<Mutex<ClientConnection>>
pub fn connection(&self) -> &Arc<Mutex<ClientConnection>>
Get a reference to the connection
Sourcepub fn try_lock(&self) -> Result<MutexGuard<'_, ClientConnection>>
pub fn try_lock(&self) -> Result<MutexGuard<'_, ClientConnection>>
Try to lock the connection
Trait Implementations§
Source§impl Clone for ClientConnectionHandle
impl Clone for ClientConnectionHandle
Auto Trait Implementations§
impl Freeze for ClientConnectionHandle
impl RefUnwindSafe for ClientConnectionHandle
impl Send for ClientConnectionHandle
impl Sync for ClientConnectionHandle
impl Unpin for ClientConnectionHandle
impl UnwindSafe for ClientConnectionHandle
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