pub enum PgTableConstraint<'s> {
PrimaryKey(TablePrimaryKey<'s>),
Unique(TableUniqueConstraint<'s>),
Check(TableCheck<'s>),
ForeignKey(TableForeignKey<'s>),
}Variants§
PrimaryKey(TablePrimaryKey<'s>)
Unique(TableUniqueConstraint<'s>)
Check(TableCheck<'s>)
ForeignKey(TableForeignKey<'s>)
Implementations§
Source§impl PgTableConstraint<'_>
impl PgTableConstraint<'_>
pub fn rename_alter( &self, new_name: DbConstraint, out: &mut Vec<Alternation>, rn: &mut RenameMap, )
pub fn create_alter_non_fk( &self, out: &mut Vec<Alternation>, rn: &RenameMap, report: &mut Report, )
pub fn create_alter_fk(&self, out: &mut Vec<Alternation>, rn: &RenameMap)
pub fn create_inline_non_fk( &self, rn: &RenameMap, report: &mut Report, ) -> Option<String>
Trait Implementations§
Source§impl<'s> Clone for PgTableConstraint<'s>
impl<'s> Clone for PgTableConstraint<'s>
Source§fn clone(&self) -> PgTableConstraint<'s>
fn clone(&self) -> PgTableConstraint<'s>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'s> Debug for PgTableConstraint<'s>
impl<'s> Debug for PgTableConstraint<'s>
Source§impl HasDefaultDbName for PgTableConstraint<'_>
impl HasDefaultDbName for PgTableConstraint<'_>
type Kind = ConstraintKind
fn default_db(&self) -> Option<DbIdent<Self::Kind>>
Source§impl IsCompatible for PgTableConstraint<'_>
impl IsCompatible for PgTableConstraint<'_>
Source§impl IsIsomorph for PgTableConstraint<'_>
impl IsIsomorph for PgTableConstraint<'_>
impl<'s> Copy for PgTableConstraint<'s>
Auto Trait Implementations§
impl<'s> Freeze for PgTableConstraint<'s>
impl<'s> RefUnwindSafe for PgTableConstraint<'s>
impl<'s> Send for PgTableConstraint<'s>
impl<'s> Sync for PgTableConstraint<'s>
impl<'s> Unpin for PgTableConstraint<'s>
impl<'s> UnwindSafe for PgTableConstraint<'s>
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
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>
Converts
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>
Converts
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