pub struct RwLockWriteGuard<T: AsOpenFile> { /* private fields */ }
Expand description
Implementations§
Trait Implementations§
Source§impl<T: AsOpenFile + AsyncBufRead> AsyncBufRead for RwLockWriteGuard<T>
impl<T: AsOpenFile + AsyncBufRead> AsyncBufRead for RwLockWriteGuard<T>
Source§impl<T: AsOpenFile + AsyncRead> AsyncRead for RwLockWriteGuard<T>
Delegate AsyncRead
to the inner file.
impl<T: AsOpenFile + AsyncRead> AsyncRead for RwLockWriteGuard<T>
Delegate AsyncRead
to the inner file.
Source§impl<T: AsOpenFile + AsyncSeek> AsyncSeek for RwLockWriteGuard<T>
impl<T: AsOpenFile + AsyncSeek> AsyncSeek for RwLockWriteGuard<T>
Source§impl<T: AsOpenFile + AsyncWrite> AsyncWrite for RwLockWriteGuard<T>
Delegate AsyncWrite
to the inner file.
impl<T: AsOpenFile + AsyncWrite> AsyncWrite for RwLockWriteGuard<T>
Delegate AsyncWrite
to the inner file.
Source§fn poll_write(
self: Pin<&mut Self>,
cx: &mut Context<'_>,
buf: &[u8],
) -> Poll<Result<usize, Error>>
fn poll_write( self: Pin<&mut Self>, cx: &mut Context<'_>, buf: &[u8], ) -> Poll<Result<usize, Error>>
Attempt to write bytes from
buf
into the object. Read moreSource§fn poll_write_vectored(
self: Pin<&mut Self>,
cx: &mut Context<'_>,
bufs: &[IoSlice<'_>],
) -> Poll<Result<usize, Error>>
fn poll_write_vectored( self: Pin<&mut Self>, cx: &mut Context<'_>, bufs: &[IoSlice<'_>], ) -> Poll<Result<usize, Error>>
Like
poll_write
, except that it writes from a slice of buffers. Read moreSource§fn is_write_vectored(&self) -> bool
fn is_write_vectored(&self) -> bool
Determines if this writer has an efficient
poll_write_vectored
implementation. Read moreSource§impl<T: AsOpenFile + BufRead> BufRead for RwLockWriteGuard<T>
impl<T: AsOpenFile + BufRead> BufRead for RwLockWriteGuard<T>
Source§fn fill_buf(&mut self) -> Result<&[u8]>
fn fill_buf(&mut self) -> Result<&[u8]>
Returns the contents of the internal buffer, filling it with more data, via
Read
methods, if empty. Read moreSource§fn consume(&mut self, amt: usize)
fn consume(&mut self, amt: usize)
Marks the given
amount
of additional bytes from the internal buffer as having been read.
Subsequent calls to read
only return bytes that have not been marked as read. Read moreSource§fn read_line(&mut self, buf: &mut String) -> Result<usize>
fn read_line(&mut self, buf: &mut String) -> Result<usize>
Reads all bytes until a newline (the
0xA
byte) is reached, and append
them to the provided String
buffer. Read moreSource§fn has_data_left(&mut self) -> Result<bool, Error>
fn has_data_left(&mut self) -> Result<bool, Error>
🔬This is a nightly-only experimental API. (
buf_read_has_data_left
)Checks if there is any data left to be
read
. Read more1.83.0 · Source§fn skip_until(&mut self, byte: u8) -> Result<usize, Error>
fn skip_until(&mut self, byte: u8) -> Result<usize, Error>
Skips all bytes until the delimiter
byte
or EOF is reached. Read moreSource§impl<T: Debug + AsOpenFile> Debug for RwLockWriteGuard<T>
impl<T: Debug + AsOpenFile> Debug for RwLockWriteGuard<T>
Source§impl<T: AsOpenFile> Drop for RwLockWriteGuard<T>
impl<T: AsOpenFile> Drop for RwLockWriteGuard<T>
Source§impl<T: AsOpenFile + Read> Read for RwLockWriteGuard<T>
Delegate Read
to the inner file.
impl<T: AsOpenFile + Read> Read for RwLockWriteGuard<T>
Delegate Read
to the inner file.
Source§fn read(&mut self, buf: &mut [u8]) -> Result<usize>
fn read(&mut self, buf: &mut [u8]) -> Result<usize>
Pull some bytes from this source into the specified buffer, returning
how many bytes were read. Read more
Source§fn read_vectored(&mut self, bufs: &mut [IoSliceMut<'_>]) -> Result<usize>
fn read_vectored(&mut self, bufs: &mut [IoSliceMut<'_>]) -> Result<usize>
Like
read
, except that it reads into a slice of buffers. Read moreSource§fn read_to_end(&mut self, buf: &mut Vec<u8>) -> Result<usize>
fn read_to_end(&mut self, buf: &mut Vec<u8>) -> Result<usize>
Reads all bytes until EOF in this source, placing them into
buf
. Read moreSource§fn read_to_string(&mut self, buf: &mut String) -> Result<usize>
fn read_to_string(&mut self, buf: &mut String) -> Result<usize>
Reads all bytes until EOF in this source, appending them to
buf
. Read moreSource§fn read_exact(&mut self, buf: &mut [u8]) -> Result<()>
fn read_exact(&mut self, buf: &mut [u8]) -> Result<()>
Reads the exact number of bytes required to fill
buf
. Read moreSource§fn by_ref(&mut self) -> &mut Selfwhere
Self: Sized,
fn by_ref(&mut self) -> &mut Selfwhere
Self: Sized,
Creates a “by reference” adaptor for this instance of
Read
. Read moreSource§fn is_read_vectored(&self) -> bool
fn is_read_vectored(&self) -> bool
🔬This is a nightly-only experimental API. (
can_vector
)Source§fn read_buf(&mut self, buf: BorrowedCursor<'_>) -> Result<(), Error>
fn read_buf(&mut self, buf: BorrowedCursor<'_>) -> Result<(), Error>
🔬This is a nightly-only experimental API. (
read_buf
)Pull some bytes from this source into the specified buffer. Read more
Source§fn read_buf_exact(&mut self, cursor: BorrowedCursor<'_>) -> Result<(), Error>
fn read_buf_exact(&mut self, cursor: BorrowedCursor<'_>) -> Result<(), Error>
🔬This is a nightly-only experimental API. (
read_buf
)Reads the exact number of bytes required to fill
cursor
. Read moreSource§impl<T: AsOpenFile + Seek> Seek for RwLockWriteGuard<T>
impl<T: AsOpenFile + Seek> Seek for RwLockWriteGuard<T>
Source§fn seek(&mut self, pos: SeekFrom) -> Result<u64>
fn seek(&mut self, pos: SeekFrom) -> Result<u64>
Seek to an offset, in bytes, in a stream. Read more
Source§fn stream_position(&mut self) -> Result<u64>
fn stream_position(&mut self) -> Result<u64>
Returns the current seek position from the start of the stream. Read more
Source§impl<T: AsOpenFile + Write> Write for RwLockWriteGuard<T>
Delegate Write
to the inner file.
impl<T: AsOpenFile + Write> Write for RwLockWriteGuard<T>
Delegate Write
to the inner file.
Source§fn write(&mut self, buf: &[u8]) -> Result<usize>
fn write(&mut self, buf: &[u8]) -> Result<usize>
Writes a buffer into this writer, returning how many bytes were written. Read more
Source§fn write_all(&mut self, buf: &[u8]) -> Result<()>
fn write_all(&mut self, buf: &[u8]) -> Result<()>
Attempts to write an entire buffer into this writer. Read more
Source§fn write_fmt(&mut self, fmt: Arguments<'_>) -> Result<()>
fn write_fmt(&mut self, fmt: Arguments<'_>) -> Result<()>
Writes a formatted string into this writer, returning any error
encountered. Read more
Source§fn by_ref(&mut self) -> &mut Selfwhere
Self: Sized,
fn by_ref(&mut self) -> &mut Selfwhere
Self: Sized,
Creates a “by reference” adapter for this instance of
Write
. Read moreSource§fn flush(&mut self) -> Result<()>
fn flush(&mut self) -> Result<()>
Flushes this output stream, ensuring that all intermediately buffered
contents reach their destination. Read more
Source§fn is_write_vectored(&self) -> bool
fn is_write_vectored(&self) -> bool
🔬This is a nightly-only experimental API. (
can_vector
)impl<'pin, T: AsOpenFile> Unpin for RwLockWriteGuard<T>where
PinnedFieldsOf<__RwLockWriteGuard<'pin, T>>: Unpin,
Auto Trait Implementations§
impl<T> Freeze for RwLockWriteGuard<T>where
T: Freeze,
impl<T> RefUnwindSafe for RwLockWriteGuard<T>where
T: RefUnwindSafe,
impl<T> Send for RwLockWriteGuard<T>where
T: Send,
impl<T> Sync for RwLockWriteGuard<T>where
T: Sync,
impl<T> UnwindSafe for RwLockWriteGuard<T>where
T: UnwindSafe,
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