pub struct StreamingPlan {
pub frames: VecDeque<PriorityStreamFrame>,
}
Expand description
Plan for streaming JSON with priority ordering
Fields§
§frames: VecDeque<PriorityStreamFrame>
Implementations§
Source§impl StreamingPlan
impl StreamingPlan
pub fn new() -> Self
Sourcepub fn next_frame(&mut self) -> Option<PriorityStreamFrame>
pub fn next_frame(&mut self) -> Option<PriorityStreamFrame>
Get next frame to send
Sourcepub fn is_complete(&self) -> bool
pub fn is_complete(&self) -> bool
Check if streaming is complete
Sourcepub fn remaining_frames(&self) -> usize
pub fn remaining_frames(&self) -> usize
Get remaining frame count
Sourcepub fn frames(&self) -> impl Iterator<Item = &PriorityStreamFrame>
pub fn frames(&self) -> impl Iterator<Item = &PriorityStreamFrame>
Get iterator over frames
Trait Implementations§
Source§impl Debug for StreamingPlan
impl Debug for StreamingPlan
Auto Trait Implementations§
impl Freeze for StreamingPlan
impl RefUnwindSafe for StreamingPlan
impl Send for StreamingPlan
impl Sync for StreamingPlan
impl Unpin for StreamingPlan
impl UnwindSafe for StreamingPlan
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