EfMigratorBackend Class

Namespace
Cake.EntityFramework.Migrator
Interfaces
Base Types
  • object
  • MarshalByRefObject
graph TD Base0["MarshalByRefObject"]-->Type Base1["object"]-->Base0 Interface0["IEfMigratorBackend"]-.->Type click Interface0 "/Cake.EntityFramework/api/Cake.EntityFramework.Interfaces/IEfMigratorBackend" Type["EfMigratorBackend"] class Type type-node

Syntax

public class EfMigratorBackend : MarshalByRefObject, IEfMigratorBackend

Properties

Name Value Summary
Ready bool
Gets a boolean value if the migration is currently ready. Specifically the AppDomain is ready

Methods

Name Value Summary
GenerateScriptForLatest() ScriptResult
Generates a script for the latest version if any
GenerateScriptForVersion(string) ScriptResult
Generates a script for the specific version if any
GetCurrentMigration() string
Gets last migration that has been applied to the target database.
GetLatestMigration() string
Gets latest migration that is defined in the assembly but has not been applied to the target database.
GetLocalMigrations() IEnumerable<string>
Gets all migrations that are defined in the configured migrations assembly.
GetPendingMigrations() IEnumerable<string>
Gets all migrations that are defined in the assembly but haven't been applied to the target database.
GetRemoteMigrations() IEnumerable<string>
Gets all migrations that have been applied to the target database.
HasPendingMigrations() bool
Determines if there are any pending migrations
Initialize(string, string, string, string, string) void
Initalized the migrator with requred settings
MigrateTo(string) MigrationResult
Migrates the data store to the specific version
MigrateToLatest() MigrationResult
Migrates the data store to the lastest version if any
SetAllowDataLossOnMigrations(bool) void
Determines whether to allow data loss on the migration