pub struct FrameProducer {
pub info: Frame,
/* private fields */
}Expand description
Used to write a frame’s worth of data in chunks.
Fields§
§info: FrameImplementations§
Source§impl FrameProducer
impl FrameProducer
pub fn new(info: Frame) -> Self
pub fn write_chunk<B: Into<Bytes>>(&mut self, chunk: B)
pub fn close(self)
pub fn abort(self, err: Error)
Sourcepub fn consume(&self) -> FrameConsumer
pub fn consume(&self) -> FrameConsumer
Create a new consumer for the frame.
pub fn unused(&self) -> impl Future<Output = ()> + use<>
Trait Implementations§
Source§impl Clone for FrameProducer
impl Clone for FrameProducer
Source§fn clone(&self) -> FrameProducer
fn clone(&self) -> FrameProducer
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for FrameProducer
impl RefUnwindSafe for FrameProducer
impl Send for FrameProducer
impl Sync for FrameProducer
impl Unpin for FrameProducer
impl UnwindSafe for FrameProducer
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