pub struct SchemaTable<'a> {
pub schema: &'a Schema,
pub table: &'a Table,
}Fields§
§schema: &'a Schema§table: &'a TableImplementations§
Source§impl<'a> SchemaTable<'a>
impl<'a> SchemaTable<'a>
pub fn schema_column(&'a self, column: ColumnIdent) -> TableColumn<'a>
pub fn columns(&self) -> impl Iterator<Item = TableColumn<'_>>
pub fn indexes(&self) -> impl Iterator<Item = TableIndex<'_>>
pub fn pk(&self) -> Option<&PrimaryKey>
pub fn foreign_keys(&self) -> impl Iterator<Item = TableForeignKey<'_>>
pub fn cardinality( &self, columns: impl IntoIterator<Item = ColumnIdent>, ) -> Cardinality
Source§impl SchemaTable<'_>
impl SchemaTable<'_>
pub fn sql<'a>(&'a self, sql: &'a Sql) -> TableSql<'a>
pub fn primary_key(&self) -> Option<TablePrimaryKey<'_>>
pub fn checks(&self) -> impl Iterator<Item = TableCheck<'_>>
pub fn unique_constraints( &self, ) -> impl Iterator<Item = TableUniqueConstraint<'_>>
Methods from Deref<Target = Table>§
pub fn primary_key(&self) -> Option<&PrimaryKey>
pub fn is_external(&self) -> bool
pub fn db_name(&self, column: &ColumnIdent, rn: &RenameMap) -> DbColumn
pub fn db_names( &self, columns: impl IntoIterator<Item = ColumnIdent>, rn: &RenameMap, ) -> Vec<DbColumn> ⓘ
pub fn format_index_name( &self, columns: impl Iterator<Item = ColumnIdent>, rn: &RenameMap, ) -> String
pub fn print_column_list( &self, out: &mut String, columns: impl Iterator<Item = ColumnIdent>, rn: &RenameMap, )
Trait Implementations§
Source§impl<'a> Clone for SchemaTable<'a>
impl<'a> Clone for SchemaTable<'a>
Source§fn clone(&self) -> SchemaTable<'a>
fn clone(&self) -> SchemaTable<'a>
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<'a> Debug for SchemaTable<'a>
impl<'a> Debug for SchemaTable<'a>
Source§impl Deref for SchemaTable<'_>
impl Deref for SchemaTable<'_>
impl<'a> Copy for SchemaTable<'a>
Auto Trait Implementations§
impl<'a> Freeze for SchemaTable<'a>
impl<'a> RefUnwindSafe for SchemaTable<'a>
impl<'a> Send for SchemaTable<'a>
impl<'a> Sync for SchemaTable<'a>
impl<'a> Unpin for SchemaTable<'a>
impl<'a> UnwindSafe for SchemaTable<'a>
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