pub struct ColumnDef {
pub column: ColumnName,
pub attributes: Option<Vec<ColumnAttribute>>,
pub data_type_def: DataTypeDef,
pub foreign: Option<Foreign>,
}
Fields§
§column: ColumnName
§attributes: Option<Vec<ColumnAttribute>>
§data_type_def: DataTypeDef
§foreign: Option<Foreign>
Implementations§
source§impl ColumnDef
impl ColumnDef
pub fn is_primary(&self) -> bool
pub fn is_autoincrement_and_primary(&self) -> bool
pub fn data_type(&self) -> DataType
sourcepub fn has_generated_default(&self) -> bool
pub fn has_generated_default(&self) -> bool
returns true if this datatype definition have a generated value or a default value
Trait Implementations§
source§impl<'de> Deserialize<'de> for ColumnDef
impl<'de> Deserialize<'de> for ColumnDef
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
source§impl PartialEq for ColumnDef
impl PartialEq for ColumnDef
impl StructuralPartialEq for ColumnDef
Auto Trait Implementations§
impl Freeze for ColumnDef
impl RefUnwindSafe for ColumnDef
impl Send for ColumnDef
impl Sync for ColumnDef
impl Unpin for ColumnDef
impl UnwindSafe for ColumnDef
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