Skip to main content

ColumnRef

Trait ColumnRef 

Source
pub trait ColumnRef<M> {
    // Required method
    fn column_name(&self) -> &str;
}
Expand description

A column reference accepted by query builder methods: either a typed Column<M, T> generated by #[derive(Model)] (checked at compile time) or a &str (checked by the database at runtime).

Required Methods§

Source

fn column_name(&self) -> &str

Dyn Compatibility§

This trait is dyn compatible.

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

Implementations on Foreign Types§

Source§

impl<M> ColumnRef<M> for &str

Source§

fn column_name(&self) -> &str

Implementors§

Source§

impl<M, T> ColumnRef<M> for Column<M, T>