Trait leetcode_tui_rs::migrations::sea_orm::Linked
source · pub trait Linked {
type FromEntity: EntityTrait;
type ToEntity: EntityTrait;
// Required method
fn link(&self) -> Vec<RelationDef, Global>;
// Provided method
fn find_linked(&self) -> Select<Self::ToEntity> { ... }
}
Expand description
A Trait for links between Entities
Required Associated Types§
type FromEntity: EntityTrait
type ToEntity: EntityTrait
Required Methods§
sourcefn link(&self) -> Vec<RelationDef, Global>
fn link(&self) -> Vec<RelationDef, Global>
Link for an Entity
Provided Methods§
sourcefn find_linked(&self) -> Select<Self::ToEntity>
fn find_linked(&self) -> Select<Self::ToEntity>
Find all the Entities that are linked to the Entity