pub(super) struct CopyBuffer {
read_done: bool,
need_flush: bool,
pos: usize,
cap: usize,
amt: u64,
buf: Box<[u8]>,
}
Fields§
§read_done: bool
§need_flush: bool
§pos: usize
§cap: usize
§amt: u64
§buf: Box<[u8]>
Implementations§
source§impl CopyBuffer
impl CopyBuffer
pub(super) fn new(buf_size: usize) -> Self
fn poll_fill_buf<R>( &mut self, cx: &mut Context<'_>, reader: Pin<&mut R>, ) -> Poll<Result<()>>
fn poll_write_buf<R, W>( &mut self, cx: &mut Context<'_>, reader: Pin<&mut R>, writer: Pin<&mut W>, ) -> Poll<Result<usize>>
pub(super) fn poll_copy<R, W>( &mut self, cx: &mut Context<'_>, reader: Pin<&mut R>, writer: Pin<&mut W>, ) -> Poll<Result<u64>>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for CopyBuffer
impl RefUnwindSafe for CopyBuffer
impl Send for CopyBuffer
impl Sync for CopyBuffer
impl Unpin for CopyBuffer
impl UnwindSafe for CopyBuffer
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