Struct sea_orm_migration::seaql_migrations::Model
source · [−]Fields
version: String
applied_at: i64
Trait Implementations
sourceimpl FromQueryResult for Model
impl FromQueryResult for Model
sourcefn from_query_result(row: &QueryResult, pre: &str) -> Result<Self, DbErr>
fn from_query_result(row: &QueryResult, pre: &str) -> Result<Self, DbErr>
Instantiate a Model from a QueryResult
sourcefn from_query_result_optional(
res: &QueryResult,
pre: &str
) -> Result<Option<Self>, DbErr>
fn from_query_result_optional(
res: &QueryResult,
pre: &str
) -> Result<Option<Self>, DbErr>
Transform the error from instantiating a Model from a QueryResult
and converting it to an Option Read more
sourcefn find_by_statement(stmt: Statement) -> SelectorRaw<SelectModel<Self>>
fn find_by_statement(stmt: Statement) -> SelectorRaw<SelectModel<Self>>
sourceimpl ModelTrait for Model
impl ModelTrait for Model
type Entity = Entity
sourcefn get(&self, c: <Self::Entity as EntityTrait>::Column) -> Value
fn get(&self, c: <Self::Entity as EntityTrait>::Column) -> Value
Get the Value of a column from an Entity
sourcefn set(&mut self, c: <Self::Entity as EntityTrait>::Column, v: Value)
fn set(&mut self, c: <Self::Entity as EntityTrait>::Column, v: Value)
Set the Value of a column in an Entity
Find related Models
sourcefn find_linked<L>(&self, l: L) -> Select<<L as Linked>::ToEntity>where
L: Linked<FromEntity = Self::Entity>,
fn find_linked<L>(&self, l: L) -> Select<<L as Linked>::ToEntity>where
L: Linked<FromEntity = Self::Entity>,
Find linked Models
sourcefn delete<'a, 'async_trait, A, C>(
self,
db: &'a C
) -> Pin<Box<dyn Future<Output = Result<DeleteResult, DbErr>> + Send + 'async_trait, Global>>where
'a: 'async_trait,
Self: IntoActiveModel<A> + 'async_trait,
C: ConnectionTrait + 'async_trait,
A: 'a + ActiveModelTrait<Entity = Self::Entity> + ActiveModelBehavior + Send + 'async_trait,
fn delete<'a, 'async_trait, A, C>(
self,
db: &'a C
) -> Pin<Box<dyn Future<Output = Result<DeleteResult, DbErr>> + Send + 'async_trait, Global>>where
'a: 'async_trait,
Self: IntoActiveModel<A> + 'async_trait,
C: ConnectionTrait + 'async_trait,
A: 'a + ActiveModelTrait<Entity = Self::Entity> + ActiveModelBehavior + Send + 'async_trait,
Delete an model
impl Eq for Model
impl StructuralEq for Model
impl StructuralPartialEq for Model
Auto Trait Implementations
impl RefUnwindSafe for Model
impl Send for Model
impl Sync for Model
impl Unpin for Model
impl UnwindSafe for Model
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
sourcefn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.