pub struct Table { /* private fields */ }Expand description
A 2-d table for formatting properly spaced values in a table.
Implementations§
Source§impl Table
impl Table
pub fn new<I>(header: I, nrows: usize) -> Selfwhere
I: IntoIterator<Item: Display + 'static>,
pub fn nrows(&self) -> usize
pub fn ncols(&self) -> usize
pub fn insert<T>(&mut self, item: T, row: usize, col: usize) -> boolwhere
T: Display + 'static,
pub fn get(&self, row: usize, col: usize) -> Option<&dyn Display>
pub fn row(&mut self, row: usize) -> Row<'_>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Table
impl !RefUnwindSafe for Table
impl !Send for Table
impl !Sync for Table
impl Unpin for Table
impl UnsafeUnpin for Table
impl !UnwindSafe for Table
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