pub struct Record {
pub name: String,
pub description: Option<String>,
pub id_strategy: IdStrategy,
pub fields: Vec<Field>,
}Expand description
An entity definition (record) — a persisted type with identity.
Unlike a TypeDef::Struct (an embedded value), a Record carries an
id and maps to a SurrealDB DEFINE TABLE ... TYPE NORMAL statement.
Fields§
§name: StringRecord name (e.g. "Atlas").
description: Option<String>Optional documentation string (description="...").
id_strategy: IdStrategyHow the record’s id is generated.
fields: Vec<Field>Fields in source order. The id field is not listed here — it is
described by Self::id_strategy.
Trait Implementations§
impl Eq for Record
impl StructuralPartialEq for Record
Auto Trait Implementations§
impl Freeze for Record
impl RefUnwindSafe for Record
impl Send for Record
impl Sync for Record
impl Unpin for Record
impl UnsafeUnpin for Record
impl UnwindSafe for Record
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