Skip to main content

ColumnHasTable

Trait ColumnHasTable 

Source
pub trait ColumnHasTable {
    type Table;

    // Required methods
    fn table(&self) -> Self::Table;
    fn name(&self) -> &str;
}
Expand description

A helper trait to access associated information for a given column

Usually you want to use the QueryFragment implementation for your column type to construct a correctly quoted query fragment containing the fully qualified identifier

Required Associated Types§

Source

type Table

The table type of this column

Required Methods§

Source

fn table(&self) -> Self::Table

The table the column belongs to

Source

fn name(&self) -> &str

The name of the table

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<C> ColumnHasTable for C
where C: Column, C::Table: Default,

Source§

type Table = <C as Column>::Table