Struct term_data_table::Row
source · [−]pub struct Row<'data> { /* private fields */ }
Expand description
A set of table cells
Implementations
sourceimpl<'data> Row<'data>
impl<'data> Row<'data>
pub fn new() -> Self
sourcepub fn with_separator(self, has_separator: bool) -> Self
pub fn with_separator(self, has_separator: bool) -> Self
Whether the row should have a top border or not
sourcepub fn set_has_separator(&mut self, has_separator: bool) -> &mut Self
pub fn set_has_separator(&mut self, has_separator: bool) -> &mut Self
Whether the row should have a top border or not
pub fn add_cell(&mut self, cell: impl Into<Cell<'data>>) -> &mut Self
pub fn with_cell(self, cell: impl Into<Cell<'data>>) -> Self
pub fn render_top_separator(
&self,
cell_widths: &[usize],
style: &TableStyle,
f: &mut Formatter<'_>
) -> Result
pub fn render_bottom_separator(
&self,
cell_widths: &[usize],
style: &TableStyle,
f: &mut Formatter<'_>
) -> Result
pub fn render_separator(
&self,
prev: &Row<'_>,
cell_widths: &[usize],
style: &TableStyle,
f: &mut Formatter<'_>
) -> Result
sourcepub fn num_columns(&self) -> usize
pub fn num_columns(&self) -> usize
Number of columns in the row.
This is the sum of all cell’s col_span values
Trait Implementations
Auto Trait Implementations
impl<'data> !RefUnwindSafe for Row<'data>
impl<'data> Send for Row<'data>
impl<'data> !Sync for Row<'data>
impl<'data> Unpin for Row<'data>
impl<'data> UnwindSafe for Row<'data>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more