pub struct FutureQueueContext { /* private fields */ }
Expand description
Context for a function in a FutureQueue
or FutureQueueGrouped
.
Implementations§
Source§impl FutureQueueContext
impl FutureQueueContext
Sourcepub fn global_slot(&self) -> u64
pub fn global_slot(&self) -> u64
Returns a global slot number: an integer that is unique for the lifetime
of the future, within the context of the FutureQueue
or
FutureQueueGrouped
it is running in.
The slot number is compact: it starts from 0, and is always the smallest possible number that could be assigned to the future at the moment the function is called.
Sourcepub fn group_slot(&self) -> Option<u64>
pub fn group_slot(&self) -> Option<u64>
Returns a group slot number: an integer that is unique for the lifetime of the future within a group.
The slot number is compact: it starts from 0, and is always the smallest possible number that could be assigned to the future at the moment the function is called.
Only set in case FutureQueueGrouped
is used, and the future is part
of a group.
Trait Implementations§
Source§impl Clone for FutureQueueContext
impl Clone for FutureQueueContext
Source§fn clone(&self) -> FutureQueueContext
fn clone(&self) -> FutureQueueContext
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for FutureQueueContext
impl RefUnwindSafe for FutureQueueContext
impl Send for FutureQueueContext
impl Sync for FutureQueueContext
impl Unpin for FutureQueueContext
impl UnwindSafe for FutureQueueContext
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