calamine

Trait ReaderRef

Source
pub trait ReaderRef<RS>: Reader<RS>
where RS: Read + Seek,
{ // Required method fn worksheet_range_ref<'a>( &'a mut self, name: &str, ) -> Result<Range<DataRef<'a>>, Self::Error>; // Provided method fn worksheet_range_at_ref( &mut self, n: usize, ) -> Option<Result<Range<DataRef<'_>>, Self::Error>> { ... } }
Expand description

A trait to share spreadsheets reader functions across different FileTypes

Required Methods§

Source

fn worksheet_range_ref<'a>( &'a mut self, name: &str, ) -> Result<Range<DataRef<'a>>, Self::Error>

Get worksheet range where shared string values are only borrowed.

This is implemented only for [calamine::Xlsb] and [calamine::Xlsx], as Xls and Ods formats do not support lazy iteration.

Provided Methods§

Source

fn worksheet_range_at_ref( &mut self, n: usize, ) -> Option<Result<Range<DataRef<'_>>, Self::Error>>

Get the nth worksheet range where shared string values are only borrowed. Shortcut for getting the nth sheet_name, then the corresponding worksheet.

This is implemented only for [calamine::Xlsb] and [calamine::Xlsx], as Xls and Ods formats do not support lazy iteration.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<RS> ReaderRef<RS> for Sheets<RS>
where RS: Read + Seek,

Source§

impl<RS: Read + Seek> ReaderRef<RS> for Xlsb<RS>

Source§

impl<RS: Read + Seek> ReaderRef<RS> for Xlsx<RS>