pub struct ClientLease<M: ClientManager> { /* private fields */ }Expand description
Exclusive checkout of one local client.
Implementations§
Source§impl<M: ClientManager> ClientLease<M>
impl<M: ClientManager> ClientLease<M>
Sourcepub fn observe<O, P: ClientPolicy<O>>(&self, policy: &P, outcome: &O)
pub fn observe<O, P: ClientPolicy<O>>(&self, policy: &P, outcome: &O)
Apply the application policy for one protocol-specific outcome.
Sourcepub fn cancellation_token(&self) -> CancellationToken
pub fn cancellation_token(&self) -> CancellationToken
Optional cancellation for active work holding this lease.
Its request policy controls whether drain signals it immediately, after
an explicit grace period, or only through ClientPool::cancel_active.
Trait Implementations§
Source§impl<M: ClientManager> Deref for ClientLease<M>
impl<M: ClientManager> Deref for ClientLease<M>
Source§impl<M: ClientManager> DerefMut for ClientLease<M>
impl<M: ClientManager> DerefMut for ClientLease<M>
Source§impl<M: ClientManager> Drop for ClientLease<M>
impl<M: ClientManager> Drop for ClientLease<M>
Auto Trait Implementations§
impl<M> Freeze for ClientLease<M>
impl<M> RefUnwindSafe for ClientLease<M>
impl<M> Send for ClientLease<M>
impl<M> Sync for ClientLease<M>
impl<M> Unpin for ClientLease<M>
impl<M> UnsafeUnpin for ClientLease<M>
impl<M> UnwindSafe for ClientLease<M>
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