Module sea_orm::entity [−][src]
Expand description
Module for the Entity type and operations
Modules
Re-export common types from the entity
Structs
Defines a value from an ActiveModel and its state.
The field value
takes in an Option type where Option::Some(V)
, with V
holding
the value that operations like UPDATE
are being performed on and
the state
field is either ActiveValueState::Set
or ActiveValueState::Unchanged
.
Option::None in the value
field indicates no value being performed by an operation
and that the state
field of the ActiveValue is set to ActiveValueState::Unset
.
Defines a Column for an Entity
Defines a helper to build a relation
Defines a relationship
Enums
The type of column as defined in the SQL format
Defines an operation for an Entity
Defines the type of relationship
Value variants
Traits
Enforce a set of constraints to a override the ActiveModel behavior Behaviors for users to override. The type must also implement the ActiveModelTrait
Enforces a set of constraints on any type performing an Create, Update or Delete operation. The type must also implement the EntityTrait. See module level docs crate::entity for a full example
Wrapper of the identically named method in sea_query::Expr
Enforces the naming of an entity to a set of constraints
An Entity implementing EntityTrait
represents a table in a database.
A set of constraints for implementing a QueryResult
Ensure the identifier for an Entity can be converted to a static str
Check the Identity of an Entity
Enforce constraints for conversion to an ActiveModel
Constraints to perform the conversion of a type into an ActiveValue
Performs a conversion into an Identity
This trait designates that an Enum
can be iterated over. It can
be auto generated using strum_macros
on your behalf.
A set of constraints for links between Entities
A set of constraints for a Model
How to map a Primary Key to a column
A set of constraints to be used to define a Primary Key.
Checks if Entities are related
Constraints a type to implement the trait to create a relationship
Functions
Defines a set operation on an ActiveValue
Defines an unset operation on an ActiveValue
Type Definitions
Action to perform on a foreign key whenever there are changes to an ActiveModel
Same as RelationDef