pub trait TaskletsStreamExt {
    // Required method
    fn tasklets_poll(&self, cx: &mut Context<'_>) -> Poll<Option<()>>;

    // Provided method
    fn tasklets_stream(&self) -> TaskletsStream<'_, Self> { ... }
}
Expand description

Trait used to wrap around a mutex that polls internally without needing to externally unlock the mutex.

Required Methods§

source

fn tasklets_poll(&self, cx: &mut Context<'_>) -> Poll<Option<()>>

Method which polls the tasklets for processing updates.

Provided Methods§

source

fn tasklets_stream(&self) -> TaskletsStream<'_, Self>

Returns an asynchronous stream which can be used for processing tasklets.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl<T: AsRef<Instance>> TaskletsStreamExt for Mutex<T>

source§

fn tasklets_poll(&self, cx: &mut Context<'_>) -> Poll<Option<()>>

source§

impl<T: AsRef<Instance>> TaskletsStreamExt for Mutex<T>

source§

fn tasklets_poll(&self, cx: &mut Context<'_>) -> Poll<Option<()>>

Implementors§