pub struct Consumer { /* private fields */ }Expand description
Consume a group, frame-by-frame.
Implementations§
Source§impl Consumer
impl Consumer
Sourcepub async fn next_frame(&mut self) -> Result<Option<Consumer>>
pub async fn next_frame(&mut self) -> Result<Option<Consumer>>
Return a consumer for the next frame for chunked reading.
Sourcepub fn poll_next_frame(
&mut self,
waiter: &Waiter,
) -> Poll<Result<Option<Consumer>>>
pub fn poll_next_frame( &mut self, waiter: &Waiter, ) -> Poll<Result<Option<Consumer>>>
Poll for the next frame, without blocking.
Returns None if the group is finished and the index is out of range.
Sourcepub fn poll_read_frame(
&mut self,
waiter: &Waiter,
) -> Poll<Result<Option<Frame>>>
pub fn poll_read_frame( &mut self, waiter: &Waiter, ) -> Poll<Result<Option<Frame>>>
Read the next frame (timestamp and payload) all at once, without blocking.
Sourcepub async fn read_frame(&mut self) -> Result<Option<Frame>>
pub async fn read_frame(&mut self) -> Result<Option<Frame>>
Read the next frame (timestamp and payload) all at once.
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for Consumer
impl RefUnwindSafe for Consumer
impl Send for Consumer
impl Sync for Consumer
impl Unpin for Consumer
impl UnsafeUnpin for Consumer
impl UnwindSafe for Consumer
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