pub trait TableRow {
// Required method
fn cells(&self) -> Vec<TableCell>;
}Expand description
Implemented by a domain type (an invoice line item, a report row, …)
that knows how to render itself as one table row — lets callers write
Table::new()...from_rows(&items) instead of hand-building
vec![vec![Element::from(..), ...]] per row, where the column order is
invisible at the call site and only checked at runtime. The plain
.rows(vec![vec![..]]) form stays available for ad hoc tables.
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".