pub struct WaitList<L: Lock, I, O> {
pub lock: L,
/* private fields */
}
Expand description
An intrusive linked list of futures.
Fields§
§lock: L
The lock used by the WaitList
.
This is used for internal synchronization, but you can also protect arbitrary state useful to you in here.
Implementations§
Source§impl<L, I, O> WaitList<L, I, O>
impl<L, I, O> WaitList<L, I, O>
Sourcepub fn lock_exclusive(&self) -> LockedExclusive<'_, L, I, O>
pub fn lock_exclusive(&self) -> LockedExclusive<'_, L, I, O>
Take an exclusive lock on the contents of this list.
This function should not be called recursively as it may deadlock, panic or abort.
Take a shared lock on the contents of this list.
If your chosen lock type only supports exclusive locks, this will take an exclusive lock instead.
Trait Implementations§
impl<L, I, O> Send for WaitList<L, I, O>
impl<L, I, O> Sync for WaitList<L, I, O>
Auto Trait Implementations§
impl<L, I, O> !Freeze for WaitList<L, I, O>
impl<L, I, O> !RefUnwindSafe for WaitList<L, I, O>
impl<L, I, O> Unpin for WaitList<L, I, O>where
L: Unpin,
impl<L, I, O> !UnwindSafe for WaitList<L, I, O>
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