Struct calloop::TokenFactory
source · pub struct TokenFactory {
key: CalloopKey,
sub_id: u32,
}
Expand description
Factory for creating tokens in your registrations
When composing event sources, each sub-source needs to have its own token to identify itself. This factory is provided to produce such unique tokens.
Fields§
§key: CalloopKey
§sub_id: u32
Implementations§
source§impl TokenFactory
impl TokenFactory
pub(crate) fn new(key: CalloopKey) -> TokenFactory
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for TokenFactory
impl Send for TokenFactory
impl Sync for TokenFactory
impl Unpin for TokenFactory
impl UnwindSafe for TokenFactory
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