pub struct NotifyRead<K, V> { /* private fields */ }
Implementations§
Source§impl<K: Eq + Hash + Clone, V: Clone> NotifyRead<K, V>
impl<K: Eq + Hash + Clone, V: Clone> NotifyRead<K, V>
pub fn new() -> Self
Sourcepub fn notify(&self, key: &K, value: &V) -> usize
pub fn notify(&self, key: &K, value: &V) -> usize
Asynchronously notifies waiters and return number of remaining pending registration
pub fn register_one(&self, key: &K) -> Registration<'_, K, V> ⓘ
pub fn register_all(&self, keys: &[K]) -> Vec<Registration<'_, K, V>>
pub fn num_pending(&self) -> usize
Trait Implementations§
Auto Trait Implementations§
impl<K, V> !Freeze for NotifyRead<K, V>
impl<K, V> !RefUnwindSafe for NotifyRead<K, V>
impl<K, V> Send for NotifyRead<K, V>
impl<K, V> Sync for NotifyRead<K, V>
impl<K, V> Unpin for NotifyRead<K, V>where
K: Unpin,
impl<K, V> !UnwindSafe for NotifyRead<K, V>
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