pub struct ReverseReader<R> { /* private fields */ }Expand description
An already configured reverse CSV reader.
§Configuration
To configure a ReverseReader, if you need a custom delimiter for instance of if
you want to tweak the size of the inner buffer. Check out the
ReaderBuilder.
Implementations§
Source§impl<R: Read + Seek> ReverseReader<R>
impl<R: Read + Seek> ReverseReader<R>
Sourcepub fn from_reader(reader: R) -> Result<Self>
pub fn from_reader(reader: R) -> Result<Self>
Create a new reverse reader with default configuration using the
provided reader implementing both std::io::Read and
std::io::Seek.
Sourcepub fn byte_headers(&self) -> &ByteRecord
pub fn byte_headers(&self) -> &ByteRecord
Attempt to return a reference to this reader’s first record.
Sourcepub fn read_byte_record(&mut self, record: &mut ByteRecord) -> Result<bool>
pub fn read_byte_record(&mut self, record: &mut ByteRecord) -> Result<bool>
Attempt to read the next CSV record into a pre-allocated ByteRecord.
Returns a boolean indicating whether a record was actually read or if we reached the end of the stream.
Sourcepub fn byte_records(&mut self) -> ReverseByteRecordsIter<'_, R>
pub fn byte_records(&mut self) -> ReverseByteRecordsIter<'_, R>
Return an iterator yielding ByteRecord structs.
Sourcepub fn into_byte_records(self) -> ReverseByteRecordsIntoIter<R>
pub fn into_byte_records(self) -> ReverseByteRecordsIntoIter<R>
Transform the reader into an iterator yielding ByteRecord structs.
Auto Trait Implementations§
impl<R> Freeze for ReverseReader<R>where
R: Freeze,
impl<R> RefUnwindSafe for ReverseReader<R>where
R: RefUnwindSafe,
impl<R> Send for ReverseReader<R>where
R: Send,
impl<R> Sync for ReverseReader<R>where
R: Sync,
impl<R> Unpin for ReverseReader<R>where
R: Unpin,
impl<R> UnwindSafe for ReverseReader<R>where
R: 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