pub struct TableDef {
pub name: String,
pub struct_name: String,
pub columns: Vec<ColumnDef>,
pub relations: Vec<RelationDef>,
}Fields§
§name: StringSQL table name (products).
struct_name: StringRust struct name (Product).
columns: Vec<ColumnDef>§relations: Vec<RelationDef>Prisma-style relation fields: struct fields that are not database
columns but hold a related row (Option<OtherTable>), populated by an
eager join when a query asks for them via include:. Skipped by the
migration diff entirely — they carry no DDL.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for TableDef
impl<'de> Deserialize<'de> for TableDef
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for TableDef
Auto Trait Implementations§
impl Freeze for TableDef
impl RefUnwindSafe for TableDef
impl Send for TableDef
impl Sync for TableDef
impl Unpin for TableDef
impl UnsafeUnpin for TableDef
impl UnwindSafe for TableDef
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more