pub struct ConstraintEntity {
pub custom_features: Option<HashMap<String, Value>>,
pub name: Option<String>,
pub reference_columns: Option<Vec<String>>,
pub reference_table: Option<String>,
pub table_columns: Option<Vec<String>>,
pub table_name: Option<String>,
pub type_: Option<String>,
}
Expand description
Constraint is not used as an independent entity, it is retrieved as part of another entity such as Table or View.
This type is not used in any activity, and only used as part of another schema.
Fields§
§custom_features: Option<HashMap<String, Value>>
Custom engine specific features.
name: Option<String>
The name of the table constraint.
reference_columns: Option<Vec<String>>
Reference columns which may be associated with the constraint. For example, if the constraint is a FOREIGN_KEY, this represents the list of full names of referenced columns by the foreign key.
reference_table: Option<String>
Reference table which may be associated with the constraint. For example, if the constraint is a FOREIGN_KEY, this represents the list of full name of the referenced table by the foreign key.
table_columns: Option<Vec<String>>
Table columns used as part of the Constraint, for example primary key constraint should list the columns which constitutes the key.
table_name: Option<String>
Table which is associated with the constraint. In case the constraint is defined on a table, this field is left empty as this information is stored in parent_name. However, if constraint is defined on a view, this field stores the table name on which the view is defined.
type_: Option<String>
Type of constraint, for example unique, primary key, foreign key (currently only primary key is supported).
Trait Implementations§
Source§impl Clone for ConstraintEntity
impl Clone for ConstraintEntity
Source§fn clone(&self) -> ConstraintEntity
fn clone(&self) -> ConstraintEntity
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for ConstraintEntity
impl Debug for ConstraintEntity
Source§impl Default for ConstraintEntity
impl Default for ConstraintEntity
Source§fn default() -> ConstraintEntity
fn default() -> ConstraintEntity
Source§impl<'de> Deserialize<'de> for ConstraintEntity
impl<'de> Deserialize<'de> for ConstraintEntity
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>,
Source§impl Serialize for ConstraintEntity
impl Serialize for ConstraintEntity
impl Part for ConstraintEntity
Auto Trait Implementations§
impl Freeze for ConstraintEntity
impl RefUnwindSafe for ConstraintEntity
impl Send for ConstraintEntity
impl Sync for ConstraintEntity
impl Unpin for ConstraintEntity
impl UnwindSafe for ConstraintEntity
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more