DbMigrator Class

Used to apply existing migrations to a database. This class can be used to upgrade and downgrade to any given migration. To scaffold migrations based on changes to your model, use MigrationScaffolder.

Namespace:  System.Data.Entity.Migrations
Assembly:  EntityFramework (in EntityFramework.dll)

public class DbMigrator : MigratorBase

The DbMigrator type exposes the following members.

Public methodDbMigrator Initializes a new instance of the DbMigrator class.

Public propertyConfiguration Gets the configuration that is being used for the migration process. (Overrides MigratorBase.Configuration.)

Public methodEquals (Inherited from Object.)
Protected methodFinalize (Inherited from Object.)
Public methodGetDatabaseMigrations Gets all migrations that have been applied to the target database. (Overrides MigratorBase.GetDatabaseMigrations().)
Public methodGetHashCode (Inherited from Object.)
Public methodGetLocalMigrations Gets all migrations that are defined in the configured migrations assembly. (Overrides MigratorBase.GetLocalMigrations().)
Public methodGetPendingMigrations Gets all migrations that are defined in the assembly but haven't been applied to the target database. (Overrides MigratorBase.GetPendingMigrations().)
Public methodGetType (Inherited from Object.)
Protected methodMemberwiseClone (Inherited from Object.)
Public methodToString (Inherited from Object.)
Public methodUpdate() Updates the target database to the latest migration. (Inherited from MigratorBase.)
Public methodUpdate(String) Updates the target database to a given migration. (Overrides MigratorBase.Update(String).)

Public fieldStatic memberInitialDatabase Migration Id representing the state of the database before any migrations are applied.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.