Struct IoVecWrapperMut

Source
pub struct IoVecWrapperMut<T> { /* private fields */ }
Expand description

A wrapper to make IoVecBufMut impl IoBufMut.

Implementations§

Source§

impl<T: IoVecBufMut> IoVecWrapperMut<T>

Source

pub fn new(iovec_buf: T) -> Result<Self, T>

Create a new IoVecWrapperMut with something that impl IoVecBufMut.

Source

pub fn into_inner(self) -> T

Consume self and return raw iovec buf.

Trait Implementations§

Source§

impl<T: IoVecBufMut> IoBufMut for IoVecWrapperMut<T>

Source§

fn write_ptr(&mut self) -> *mut u8

Returns a raw mutable pointer to the vector’s buffer. Read more
Source§

fn bytes_total(&mut self) -> usize

Total size of the buffer, including uninitialized memory, if any. Read more
Source§

unsafe fn set_init(&mut self, _pos: usize)

Updates the number of initialized bytes. Read more
Source§

unsafe fn slice_mut_unchecked( self, range: impl RangeBounds<usize>, ) -> SliceMut<Self>
where Self: Sized,

Returns a view of the buffer with the specified range. Read more

Auto Trait Implementations§

§

impl<T> Freeze for IoVecWrapperMut<T>
where T: Freeze,

§

impl<T> RefUnwindSafe for IoVecWrapperMut<T>
where T: RefUnwindSafe,

§

impl<T> Send for IoVecWrapperMut<T>
where T: Send,

§

impl<T> Sync for IoVecWrapperMut<T>
where T: Sync,

§

impl<T> Unpin for IoVecWrapperMut<T>
where T: Unpin,

§

impl<T> UnwindSafe for IoVecWrapperMut<T>
where T: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.