Trait TableHeader

Source
pub trait TableHeader {
    type CellKey: CellKey + ?Sized;

    // Required method
    fn header(
        &self,
    ) -> Option<impl IteratorTrait<Item = (&Self::CellKey, &str)>>;
}
Expand description

Trait returning headers of a table if any.

Required Associated Types§

Source

type CellKey: CellKey + ?Sized

The type used to identify cells within a row, requiring implementation of the Key trait.

Required Methods§

Source

fn header(&self) -> Option<impl IteratorTrait<Item = (&Self::CellKey, &str)>>

Returns an iterator over all fields of the specified type within the entity.

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<T, RowKey, Row, CellKey> TableHeader for AsTable<'_, T, RowKey, Row, CellKey>
where Self: TableRows<RowKey = RowKey, Row = Row, CellKey = CellKey>, RowKey: RowKey, Row: Cells<CellKey>, CellKey: CellKey + ?Sized,

Source§

type CellKey = CellKey