pub struct RowCount { /* private fields */ }Expand description
Returns a count of the total number of rows.
The entry point for setting up a czv::count::RowCountBuilder by running RowCount::new().
§Example
Let’s say we want to print the total number of non-header rows in our data:
use czv::{RowCount, Result};
fn main() -> Result<()> {
let data = "\
fruits,price
apple,2.50
banana,3.00
strawberry,1.50
";
let output = RowCount::new().file_data(data).execute()?;
println!("{output}"); // 3
Ok(())
}Implementations§
Auto Trait Implementations§
impl Freeze for RowCount
impl RefUnwindSafe for RowCount
impl Send for RowCount
impl Sync for RowCount
impl Unpin for RowCount
impl UnwindSafe for RowCount
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