pub struct SchemaDiffEngine;Expand description
Schema diff engine
Implementations§
Source§impl SchemaDiffEngine
impl SchemaDiffEngine
Sourcepub fn compare_tables(
old_tables: &HashMap<String, Table>,
new_tables: &HashMap<String, Table>,
) -> Vec<SchemaDiff>
pub fn compare_tables( old_tables: &HashMap<String, Table>, new_tables: &HashMap<String, Table>, ) -> Vec<SchemaDiff>
Compare two schema states and return the differences
Sourcepub fn compare_events(
old_events: &HashMap<String, Event>,
new_events: &HashMap<String, Event>,
) -> Vec<SchemaDiff>
pub fn compare_events( old_events: &HashMap<String, Event>, new_events: &HashMap<String, Event>, ) -> Vec<SchemaDiff>
Compare two event collections and return the differences
Sourcepub fn compare_indexes(
old_indexes: &HashMap<String, IndexMeta>,
new_indexes: &HashMap<String, IndexMeta>,
) -> Vec<SchemaDiff>
pub fn compare_indexes( old_indexes: &HashMap<String, IndexMeta>, new_indexes: &HashMap<String, IndexMeta>, ) -> Vec<SchemaDiff>
Compare two index collections and return the differences
Sourcepub fn compare_views(
old_views: &HashMap<String, View>,
new_views: &HashMap<String, View>,
) -> Vec<SchemaDiff>
pub fn compare_views( old_views: &HashMap<String, View>, new_views: &HashMap<String, View>, ) -> Vec<SchemaDiff>
Compare two view schema states and return the differences
Sourcepub fn columns_equal(a: &Column, b: &Column) -> bool
pub fn columns_equal(a: &Column, b: &Column) -> bool
Compare if two columns are equal
Sourcepub fn generate_table_change_sql(
table_name: &str,
old_table: &Table,
new_table: &Table,
) -> Vec<String>
pub fn generate_table_change_sql( table_name: &str, old_table: &Table, new_table: &Table, ) -> Vec<String>
Generate SQL for a specific table change
Sourcepub fn generate_view_change_sql(
view_name: &str,
old_view: &View,
new_view: &View,
) -> Vec<String>
pub fn generate_view_change_sql( view_name: &str, old_view: &View, new_view: &View, ) -> Vec<String>
Generate SQL for a specific view change
Sourcepub fn generate_index_change_sql(
index_name: &str,
old_index: &IndexMeta,
new_index: &IndexMeta,
) -> Vec<String>
pub fn generate_index_change_sql( index_name: &str, old_index: &IndexMeta, new_index: &IndexMeta, ) -> Vec<String>
Generate SQL for a specific index change
Sourcepub fn generate_event_change_sql(
event_name: &str,
old_event: &Event,
new_event: &Event,
) -> Vec<String>
pub fn generate_event_change_sql( event_name: &str, old_event: &Event, new_event: &Event, ) -> Vec<String>
Generate SQL for a specific event change
Sourcepub fn generate_role_change_sql(
role_name: &str,
old_role: &Role,
new_role: &Role,
) -> Vec<String>
pub fn generate_role_change_sql( role_name: &str, old_role: &Role, new_role: &Role, ) -> Vec<String>
Generate SQL for a specific role change
Sourcepub fn generate_grant_change_sql(
grant_name: &str,
old_grant: &Grant,
new_grant: &Grant,
) -> Vec<String>
pub fn generate_grant_change_sql( grant_name: &str, old_grant: &Grant, new_grant: &Grant, ) -> Vec<String>
Generate SQL for a specific grant change
Sourcepub fn compare_roles(
old_roles: &HashMap<String, Role>,
new_roles: &HashMap<String, Role>,
) -> Vec<SchemaDiff>
pub fn compare_roles( old_roles: &HashMap<String, Role>, new_roles: &HashMap<String, Role>, ) -> Vec<SchemaDiff>
Compare role collections
Sourcepub fn compare_grants(
old_grants: &HashMap<String, Grant>,
new_grants: &HashMap<String, Grant>,
) -> Vec<SchemaDiff>
pub fn compare_grants( old_grants: &HashMap<String, Grant>, new_grants: &HashMap<String, Grant>, ) -> Vec<SchemaDiff>
Compare grant collections
Sourcepub fn compare_functions(
old_functions: &HashMap<String, StoredFunction>,
new_functions: &HashMap<String, StoredFunction>,
) -> Vec<SchemaDiff>
pub fn compare_functions( old_functions: &HashMap<String, StoredFunction>, new_functions: &HashMap<String, StoredFunction>, ) -> Vec<SchemaDiff>
Compare functions and generate differences
Sourcepub fn compare_procedures(
old_procedures: &HashMap<String, StoredProcedure>,
new_procedures: &HashMap<String, StoredProcedure>,
) -> Vec<SchemaDiff>
pub fn compare_procedures( old_procedures: &HashMap<String, StoredProcedure>, new_procedures: &HashMap<String, StoredProcedure>, ) -> Vec<SchemaDiff>
Compare procedures and generate differences
Sourcepub fn compare_triggers(
old_triggers: &HashMap<String, Trigger>,
new_triggers: &HashMap<String, Trigger>,
) -> Vec<SchemaDiff>
pub fn compare_triggers( old_triggers: &HashMap<String, Trigger>, new_triggers: &HashMap<String, Trigger>, ) -> Vec<SchemaDiff>
Compare triggers and generate differences
Sourcepub fn compare_composite_types(
old_composite_types: &HashMap<String, CompositeType>,
new_composite_types: &HashMap<String, CompositeType>,
) -> Vec<SchemaDiff>
pub fn compare_composite_types( old_composite_types: &HashMap<String, CompositeType>, new_composite_types: &HashMap<String, CompositeType>, ) -> Vec<SchemaDiff>
Compare composite types and generate differences
Auto Trait Implementations§
impl Freeze for SchemaDiffEngine
impl RefUnwindSafe for SchemaDiffEngine
impl Send for SchemaDiffEngine
impl Sync for SchemaDiffEngine
impl Unpin for SchemaDiffEngine
impl UnsafeUnpin for SchemaDiffEngine
impl UnwindSafe for SchemaDiffEngine
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
impl<T> ErasedDestructor for Twhere
T: 'static,
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