pub struct RuntimeSendCap<P: Permission> { /* private fields */ }Expand description
A thread-safe revocable capability token.
Created via RuntimeCap::make_send. Unlike RuntimeCap, this implements
Send + Sync, making it usable with std::thread::spawn, tokio::spawn, etc.
Implementations§
Source§impl<P: Permission> RuntimeSendCap<P>
impl<P: Permission> RuntimeSendCap<P>
Sourcepub fn try_cap(&self) -> Result<Cap<P>, CapSecError>
pub fn try_cap(&self) -> Result<Cap<P>, CapSecError>
Trait Implementations§
Source§impl<P: Permission> Clone for RuntimeSendCap<P>
impl<P: Permission> Clone for RuntimeSendCap<P>
impl<P: Permission> Send for RuntimeSendCap<P>
impl<P: Permission> Sync for RuntimeSendCap<P>
Auto Trait Implementations§
impl<P> Freeze for RuntimeSendCap<P>
impl<P> RefUnwindSafe for RuntimeSendCap<P>where
P: RefUnwindSafe,
impl<P> Unpin for RuntimeSendCap<P>where
P: Unpin,
impl<P> UnsafeUnpin for RuntimeSendCap<P>
impl<P> UnwindSafe for RuntimeSendCap<P>where
P: UnwindSafe,
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