enum Rotor::Operation
What a migration does, one step: its DSL records these, and
Rotor::Migrator.render writes their SQL (the one place a dialect is
rendered).
/home/runner/work/rotor/rotor/src/migration.qz:35
Variants
variant Rotor::Operation::CreateTable(name: String, columns: Array[Rotor::ColumnDef], indexes: Array[Rotor::IndexDef], if_not_exists: Bool)
variant Rotor::Operation::DropTable(name: String, columns: Array[Rotor::ColumnDef]?, indexes: Array[Rotor::IndexDef], if_exists: Bool)
(columns nil: not given, so not reversible.)
variant Rotor::Operation::RenameTable(name: String, to: String)
variant Rotor::Operation::AddColumn(table: String, column: Rotor::ColumnDef)
variant Rotor::Operation::RemoveColumn(table: String, name: String, column: Rotor::ColumnDef?)
(column nil: its type not given, so not reversible.)
variant Rotor::Operation::RenameColumn(table: String, name: String, to: String)
variant Rotor::Operation::ChangeColumn(table: String, name: String, null: Bool?, default: Int | Float | String | Bool | Bytes | Rotor::SQL::Raw | Rotor::NoDefault | Nil, was: Rotor::Was?)
variant Rotor::Operation::CreateIndex(index: Rotor::IndexDef)
variant Rotor::Operation::DropIndex(name: String, index: Rotor::IndexDef?, concurrently: Bool)
(index nil: named alone, so not reversible.)
variant Rotor::Operation::AddForeignKey(table: String, column: String, reference: Rotor::Reference)
variant Rotor::Operation::Execute(sql: String, down: String?)
Class methods
def self.irreversible(op: Rotor::Operation, hint: String) -> Nothing
(op cannot be reversed; hint says what would make it so.)
Methods
def describe -> String
The call that records it, for messages: create_table :users.
def reverse -> Rotor::Operation
The operation that undoes this one; raises
Rotor::IrreversibleMigration when it cannot be known.