Interface IMigrationContext
Provides context to migrations.
Namespace: Umbraco.Cms.Infrastructure.Migrations
Assembly: Umbraco.Infrastructure.dll
Syntax
public interface IMigrationContext
Properties
View SourceBuildingExpression
Gets or sets a value indicating whether an expression is being built.
Declaration
bool BuildingExpression { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Database
Gets the database instance.
Declaration
IUmbracoDatabase Database { get; }
Property Value
Type | Description |
---|---|
IUmbracoDatabase |
Index
Gets or sets the expression index.
Declaration
int Index { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |
Logger
Gets the logger.
Declaration
ILogger<IMigrationContext> Logger { get; }
Property Value
Type | Description |
---|---|
ILogger<IMigrationContext> |
Plan
Gets the current migration plan
Declaration
MigrationPlan Plan { get; }
Property Value
Type | Description |
---|---|
MigrationPlan |
SqlContext
Gets the Sql context.
Declaration
ISqlContext SqlContext { get; }
Property Value
Type | Description |
---|---|
ISqlContext |
Methods
View SourceAddPostMigration<TMigration>()
Adds a post-migration.
Declaration
void AddPostMigration<TMigration>()
where TMigration : MigrationBase
Type Parameters
Name | Description |
---|---|
TMigration |