pub struct FromStd<T: ?Sized> { /* private fields */ }Available on crate feature
std only.Expand description
Adapter from std::io traits.
Implementations§
Source§impl<T> FromStd<T>
impl<T> FromStd<T>
Sourcepub fn into_inner(self) -> T
pub fn into_inner(self) -> T
Consume the adapter, returning the inner object.
Trait Implementations§
Source§impl<T: BufRead + ?Sized> BufRead for FromStd<T>
impl<T: BufRead + ?Sized> BufRead for FromStd<T>
Source§impl<T: Read + ?Sized> Read for FromStd<T>
impl<T: Read + ?Sized> Read for FromStd<T>
Source§fn read(&mut self, buf: &mut [u8]) -> Result<usize, Self::Error>
fn read(&mut self, buf: &mut [u8]) -> Result<usize, Self::Error>
Read some bytes from this source into the specified buffer, returning how many bytes were read. Read more
Source§fn read_exact(
&mut self,
buf: &mut [u8],
) -> Result<(), ReadExactError<Self::Error>>
fn read_exact( &mut self, buf: &mut [u8], ) -> Result<(), ReadExactError<Self::Error>>
Read the exact number of bytes required to fill
buf. Read moreSource§impl<T: Seek + ?Sized> Seek for FromStd<T>
impl<T: Seek + ?Sized> Seek for FromStd<T>
Source§fn seek(&mut self, pos: SeekFrom) -> Result<u64, Self::Error>
fn seek(&mut self, pos: SeekFrom) -> Result<u64, Self::Error>
Seek to an offset, in bytes, in a stream.
A seek beyond the end of a stream is allowed, but behavior is defined
by the implementation. Read more
Source§fn rewind(&mut self) -> Result<(), Self::Error>
fn rewind(&mut self) -> Result<(), Self::Error>
Rewind to the beginning of a stream. Read more
Source§impl<T: Write + ?Sized> Write for FromStd<T>
impl<T: Write + ?Sized> Write for FromStd<T>
Source§fn write(&mut self, buf: &[u8]) -> Result<usize, Self::Error>
fn write(&mut self, buf: &[u8]) -> Result<usize, Self::Error>
Write a buffer into this writer, returning how many bytes were written. Read more
Source§fn write_all(&mut self, buf: &[u8]) -> Result<(), Self::Error>
fn write_all(&mut self, buf: &[u8]) -> Result<(), Self::Error>
Write an entire buffer into this writer. Read more
Auto Trait Implementations§
impl<T> Freeze for FromStd<T>
impl<T> RefUnwindSafe for FromStd<T>where
T: RefUnwindSafe + ?Sized,
impl<T> Send for FromStd<T>
impl<T> Sync for FromStd<T>
impl<T> Unpin for FromStd<T>
impl<T> UnwindSafe for FromStd<T>where
T: UnwindSafe + ?Sized,
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