Struct drying_paint::SyncWatchedMeta
source · [−]pub struct SyncWatchedMeta { /* private fields */ }Expand description
SyncWatchedMeta is like WatchedMeta, however allows you to create a trigger which may be sent to other threads.
When this trigger is invoked, watch functions in the single-threaded watch context will be re-run.
Implementations
sourceimpl SyncWatchedMeta
impl SyncWatchedMeta
sourcepub fn watched<'ctx, O: ?Sized>(&self, ctx: WatchArg<'_, 'ctx, O>)
pub fn watched<'ctx, O: ?Sized>(&self, ctx: WatchArg<'_, 'ctx, O>)
When run in a function designed to watch a value, will bind so that function will be re-run when a trigger associated with this AtomicWatchedMeta is invoked.
sourcepub fn create_trigger(&self) -> SyncTrigger
pub fn create_trigger(&self) -> SyncTrigger
Create a trigger for this AtomicWatchedMeta which may be sent to another thread.
Trait Implementations
sourceimpl Debug for SyncWatchedMeta
impl Debug for SyncWatchedMeta
Auto Trait Implementations
impl !RefUnwindSafe for SyncWatchedMeta
impl Send for SyncWatchedMeta
impl !Sync for SyncWatchedMeta
impl Unpin for SyncWatchedMeta
impl UnwindSafe for SyncWatchedMeta
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more