Search Results for

    Show / Hide Table of Contents
    View Source

    Class UmbracoPlan

    Represents the Umbraco CMS migration plan.

    Inheritance
    System.Object
    MigrationPlan
    Namespace: Umbraco.Cms.Infrastructure.Migrations.Upgrade
    Assembly: Umbraco.Infrastructure.dll
    Syntax
    public class UmbracoPlan : MigrationPlan

    Constructors

    View Source

    UmbracoPlan(IUmbracoVersion)

    Initializes a new instance of the UmbracoPlan class.

    Declaration
    public UmbracoPlan(IUmbracoVersion umbracoVersion)
    Parameters
    Type Name Description
    IUmbracoVersion umbracoVersion

    The Umbraco version.

    Properties

    View Source

    InitialState

    Gets the initial state.

    Declaration
    public override string InitialState { get; }
    Property Value
    Type Description
    System.String
    Remarks

    The default initial state in plans is string.Empty.

    When upgrading from version 7, we want to use specific initial states that are e.g. "{init-7.9.3}", "{init-7.11.1}", etc. so we can chain the proper migrations.

    This is also where we detect the current version, and reject invalid upgrades (from a tool old version, or going back in time, etc).

    Methods

    View Source

    DefinePlan()

    Defines the plan.

    Declaration
    protected void DefinePlan()
    View Source

    ThrowOnUnknownInitialState(String)

    Throws an exception when the initial state is unknown.

    Declaration
    public override void ThrowOnUnknownInitialState(string state)
    Parameters
    Type Name Description
    System.String state
    • Improve this Doc
    • View Source
    In This Article
    • Constructors
      • UmbracoPlan(IUmbracoVersion)
    • Properties
      • InitialState
    • Methods
      • DefinePlan()
      • ThrowOnUnknownInitialState(String)
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX