Search Results for

    Show / Hide Table of Contents

    Interface ICustomUpgrader

    Namespace: LemonEdge.API.Migrations.Core
    Assembly: API.dll
    Syntax
    public interface ICustomUpgrader

    Properties

    AlwaysRunOnUpgrade

    Indicates if this custom upgrader should always be run when the db is upgrading

    (RequiresDBUpgrade(ICustomUpgradeVersionHandler) can still be false indicating this should not force the db to upgrade, but if it is upgrading then it should run too)

    Declaration
    bool AlwaysRunOnUpgrade { get; }
    Property Value
    Type Description
    System.Boolean

    Order

    The custom order in which this upgrade should be run

    Declaration
    short Order { get; }
    Property Value
    Type Description
    System.Int16

    Methods

    RequiresDBUpgrade(ICustomUpgradeVersionHandler)

    Inidicates the database needs to be updated, and that this customupgrade must run

    Declaration
    Task<bool> RequiresDBUpgrade(ICustomUpgradeVersionHandler upgradeVersionHandler)
    Parameters
    Type Name Description
    ICustomUpgradeVersionHandler upgradeVersionHandler

    The version handler which can be used to interogate if upgrades have already been run or not

    Returns
    Type Description
    System.Threading.Tasks.Task<System.Boolean>

    RunCustomUpgrade(CustomUpgradeHelper)

    Allows the implementing class to run a custom upgrade on the database

    Declaration
    Task RunCustomUpgrade(CustomUpgradeHelper helper)
    Parameters
    Type Name Description
    CustomUpgradeHelper helper

    A helper class providing functionality to modify the database for upgrading

    Returns
    Type Description
    System.Threading.Tasks.Task

    A task indicating the completion of the custom upgrade

    Extension Methods

    MiscExtensions.SetIfNotEqual<T, P>(T, Expression<Func<T, P>>, P)
    ReflectionExtensions.ClearEventInvocations(Object, String)
    StringExtensions.ToCSVFormatString(Object, Type)
    SQLExtensions.ToSQLValue(Object, Boolean)
    In This Article
    Back to top © LemonTree Software Ltd. All rights reserved.