logo

Trait sea_orm::entity::prelude::EntityName[][src]

pub trait EntityName: IdenStatic + Default {
    fn table_name(&self) -> &str;

    fn schema_name(&self) -> Option<&str> { ... }
fn module_name(&self) -> &str { ... }
fn table_ref(&self) -> TableRef { ... } }
Expand description

A Trait for mapping an Entity to a database table

Required methods

Get the name of the table

Provided methods

Method to get the name for the schema, defaults to Option::None if not set

Get the name of the module from the invoking self.table_name()

Get the TableRef from invoking the self.schema_name()

Implementors