Search Results for

    Show / Hide Table of Contents
    View Source

    Class DeletingVersionsNotification<T>

    Abstract base class for cancelable notifications published before versions are deleted.

    Inheritance
    object
    StatefulNotification
    DeletedVersionsNotificationBase<T>
    Namespace: Umbraco.Cms.Core.Notifications
    Assembly: Umbraco.Core.dll
    Syntax
    public abstract class DeletingVersionsNotification<T> : DeletedVersionsNotificationBase<T>, IStatefulNotification, ICancelableNotification, INotification where T : class
    Type Parameters
    Name Description
    T

    The type of entity whose versions are being deleted.

    Remarks

    This notification is published before versions are deleted, allowing handlers to cancel the operation by setting Cancel to true.

    Constructors

    View Source

    DeletingVersionsNotification(int, EventMessages, int, bool, DateTime)

    Initializes a new instance of the DeletingVersionsNotification<T> class.

    Declaration
    protected DeletingVersionsNotification(int id, EventMessages messages, int specificVersion = 0, bool deletePriorVersions = false, DateTime dateToRetain = default)
    Parameters
    Type Name Description
    int id

    The ID of the entity whose versions are being deleted.

    EventMessages messages

    The event messages collection.

    int specificVersion

    The specific version to delete, or default to delete based on other criteria.

    bool deletePriorVersions

    Whether to delete all versions prior to the specified version.

    DateTime dateToRetain

    The date before which versions should be deleted.

    Properties

    View Source

    Cancel

    Gets or sets a value indicating whether the operation should be canceled.

    Declaration
    public bool Cancel { get; set; }
    Property Value
    Type Description
    bool

    true if the operation should be canceled; otherwise, false.

    • View Source
    In this article
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX