pub enum StatementTarget {
Table {
schema: Option<String>,
name: String,
columns: Vec<String>,
},
Index {
schema: Option<String>,
name: String,
unique: bool,
columns: Vec<String>,
},
View {
schema: Option<String>,
name: String,
},
Enum {
schema: Option<String>,
name: String,
values: Vec<String>,
},
Unclassified,
}Available on crate feature
std only.Expand description
What a migration statement creates, when that is decidable from its text.
Variants§
Table
CREATE TABLE [IF NOT EXISTS] <name> (<columns>).
Fields
Index
CREATE [UNIQUE] INDEX [CONCURRENTLY] [IF NOT EXISTS] <name> ON ....
Fields
View
CREATE VIEW <name> AS ....
Fields
Enum
CREATE TYPE <name> AS ENUM (<values>).
Fields
Unclassified
Anything else. Never provable, therefore never skippable.
Implementations§
Source§impl StatementTarget
impl StatementTarget
Sourcepub const fn is_classified(&self) -> bool
pub const fn is_classified(&self) -> bool
Whether this statement kind can ever be proven already-applied.
Trait Implementations§
Source§impl Clone for StatementTarget
impl Clone for StatementTarget
Source§fn clone(&self) -> StatementTarget
fn clone(&self) -> StatementTarget
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for StatementTarget
impl Debug for StatementTarget
impl Eq for StatementTarget
Source§impl PartialEq for StatementTarget
impl PartialEq for StatementTarget
impl StructuralPartialEq for StatementTarget
Auto Trait Implementations§
impl Freeze for StatementTarget
impl RefUnwindSafe for StatementTarget
impl Send for StatementTarget
impl Sync for StatementTarget
impl Unpin for StatementTarget
impl UnsafeUnpin for StatementTarget
impl UnwindSafe for StatementTarget
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