pub struct FlowSubscriber<T: Flows> { /* private fields */ }
Expand description
Subscriber which receives data from a Flow
.
Implementations§
Source§impl<T: Flows> FlowSubscriber<T>
impl<T: Flows> FlowSubscriber<T>
Sourcepub fn try_next(&mut self) -> Result<PublishedData<'_, T>, Error>
pub fn try_next(&mut self) -> Result<PublishedData<'_, T>, Error>
Tries to receive the next message from
the flow, returning a PublishedData
iff successful.
Sourcepub async fn next(&mut self) -> Result<PublishedData<'_, T>, Error>
pub async fn next(&mut self) -> Result<PublishedData<'_, T>, Error>
Awaits and receives the next message from
the flow, returning a PublishedData
iff successful.
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for FlowSubscriber<T>
impl<T> !RefUnwindSafe for FlowSubscriber<T>
impl<T> Send for FlowSubscriber<T>
impl<T> Sync for FlowSubscriber<T>
impl<T> Unpin for FlowSubscriber<T>
impl<T> !UnwindSafe for FlowSubscriber<T>
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