pub struct RegistrationScope<'scope>(/* private fields */);Expand description
Scope helper used to obtain short-lived &mut Registration borrows.
This enforces that Registration references obtained cannot be retained beyond the
registration_scope function call
Implementations§
Source§impl<'scope> RegistrationScope<'scope>
impl<'scope> RegistrationScope<'scope>
Sourcepub fn from_client_index(
&self,
_vm: &BarrierHeldMainRef,
client_index: u32,
) -> Option<&'scope mut Registration>
pub fn from_client_index( &self, _vm: &BarrierHeldMainRef, client_index: u32, ) -> Option<&'scope mut Registration>
Look up a Registration by VPP client index.
Returns Some(&mut Registration) when the client index corresponds to a current
registration, or None if no registration exists for that index.
Auto Trait Implementations§
impl<'scope> Freeze for RegistrationScope<'scope>
impl<'scope> RefUnwindSafe for RegistrationScope<'scope>
impl<'scope> Send for RegistrationScope<'scope>
impl<'scope> Sync for RegistrationScope<'scope>
impl<'scope> Unpin for RegistrationScope<'scope>
impl<'scope> UnsafeUnpin for RegistrationScope<'scope>
impl<'scope> UnwindSafe for RegistrationScope<'scope>
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