Struct karabiner_onetime::Lock
[−]
[src]
pub struct Lock<T> { /* fields omitted */ }
Methods
impl<T> Lock<T> where
T: Send + Sync,
[src]
T: Send + Sync,
fn new(inner: T) -> Lock<T>
fn try_lock(&self) -> Option<LockGuard<T>>
fn wait(&self)
fn into_inner(self) -> T
Trait Implementations
impl<T: Default> Default for Lock<T>
[src]
impl<T: Send> Send for Lock<T>
[src]
impl<T: Sync> Sync for Lock<T>
[src]
impl<T> Deref for Lock<T> where
T: Send + Sync,
[src]
T: Send + Sync,
type Target = T
The resulting type after dereferencing
fn deref(&self) -> &T
Dereference to the value inside the Lock. This can block if the Lock is in its lock state.
impl<T> DerefMut for Lock<T> where
T: Send + Sync,
[src]
T: Send + Sync,
fn deref_mut(&mut self) -> &mut T
The method called to mutably dereference a value