pub struct Context { /* private fields */ }Expand description
splice(2) operation context.
Implementations§
Source§impl Context
impl Context
Sourcepub fn poll_copy(
&mut self,
cx: &mut Context<'_>,
src: &mut OwnedReadHalf,
dst: &mut OwnedWriteHalf,
) -> Poll<Result<()>>
pub fn poll_copy( &mut self, cx: &mut Context<'_>, src: &mut OwnedReadHalf, dst: &mut OwnedWriteHalf, ) -> Poll<Result<()>>
Polls copying data from src to dst using splice(2).
Notes that on multiple calls to poll_copy, only the
Waker from the task::Context passed to the most
recent call is scheduled to receive a wakeup, which is probably not what
you want.
Sourcepub const fn transferred(&self) -> usize
pub const fn transferred(&self) -> usize
Returns the total bytes transferred so far.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Context
impl RefUnwindSafe for Context
impl Send for Context
impl Sync for Context
impl Unpin for Context
impl UnwindSafe for Context
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