Search Results for

    Show / Hide Table of Contents
    View Source

    Class ContentScheduleCollection

    Inheritance
    object
    Namespace: Umbraco.Cms.Core.Models
    Assembly: Umbraco.Core.dll
    Syntax
    public class ContentScheduleCollection : IDeepCloneable

    Properties

    View Source

    FullSchedule

    Returns all schedules registered

    Declaration
    public IReadOnlyList<ContentSchedule> FullSchedule { get; }
    Property Value
    Type Description
    IReadOnlyList<ContentSchedule>

    Methods

    View Source

    Add(DateTime?, DateTime?)

    Adds a new schedule for invariant content

    Declaration
    public bool Add(DateTime? releaseDate, DateTime? expireDate)
    Parameters
    Type Name Description
    DateTime? releaseDate
    DateTime? expireDate
    Returns
    Type Description
    bool
    View Source

    Add(string?, DateTime?, DateTime?)

    Adds a new schedule for a culture

    Declaration
    public bool Add(string? culture, DateTime? releaseDate, DateTime? expireDate)
    Parameters
    Type Name Description
    string culture
    DateTime? releaseDate
    DateTime? expireDate
    Returns
    Type Description
    bool

    true if successfully added, false if validation fails

    View Source

    Add(ContentSchedule)

    Add an existing schedule

    Declaration
    public void Add(ContentSchedule schedule)
    Parameters
    Type Name Description
    ContentSchedule schedule
    View Source

    AddOrUpdate(string, DateTime, ContentScheduleAction)

    Declaration
    public void AddOrUpdate(string culture, DateTime dateTime, ContentScheduleAction action)
    Parameters
    Type Name Description
    string culture
    DateTime dateTime
    ContentScheduleAction action
    View Source

    Clear(string?, ContentScheduleAction, DateTime?)

    Clear all of the scheduled change type for the culture

    Declaration
    public void Clear(string? culture, ContentScheduleAction action, DateTime? date = null)
    Parameters
    Type Name Description
    string culture
    ContentScheduleAction action
    DateTime? date

    If specified, will clear all entries with dates less than or equal to the value

    View Source

    Clear(ContentScheduleAction, DateTime?)

    Clear all of the scheduled change type for invariant content

    Declaration
    public void Clear(ContentScheduleAction action, DateTime? changeDate = null)
    Parameters
    Type Name Description
    ContentScheduleAction action
    DateTime? changeDate

    If specified, will clear all entries with dates less than or equal to the value

    View Source

    ClearCollectionChangedEvents()

    Clears all CollectionChanged event handlers

    Declaration
    public void ClearCollectionChangedEvents()
    View Source

    CreateWithEntry(DateTime?, DateTime?)

    Declaration
    public static ContentScheduleCollection CreateWithEntry(DateTime? release, DateTime? expire)
    Parameters
    Type Name Description
    DateTime? release
    DateTime? expire
    Returns
    Type Description
    ContentScheduleCollection
    View Source

    CreateWithEntry(string, DateTime?, DateTime?)

    Declaration
    public static ContentScheduleCollection CreateWithEntry(string culture, DateTime? release, DateTime? expire)
    Parameters
    Type Name Description
    string culture
    DateTime? release
    DateTime? expire
    Returns
    Type Description
    ContentScheduleCollection
    View Source

    DeepClone()

    Declaration
    public object DeepClone()
    Returns
    Type Description
    object
    View Source

    Equals(object?)

    Determines whether the specified object is equal to the current object.

    Declaration
    public override bool Equals(object? obj)
    Parameters
    Type Name Description
    object obj

    The object to compare with the current object.

    Returns
    Type Description
    bool

    true if the specified object is equal to the current object; otherwise, false.

    View Source

    Equals(ContentScheduleCollection?)

    Indicates whether the current object is equal to another object of the same type.

    Declaration
    public bool Equals(ContentScheduleCollection? other)
    Parameters
    Type Name Description
    ContentScheduleCollection other

    An object to compare with this object.

    Returns
    Type Description
    bool

    true if the current object is equal to the other parameter; otherwise, false.

    View Source

    GetHashCode()

    Serves as the default hash function.

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    int

    A hash code for the current object.

    View Source

    GetPending(ContentScheduleAction, DateTime)

    Returns all pending schedules based on the date and type provided

    Declaration
    public IReadOnlyList<ContentSchedule> GetPending(ContentScheduleAction action, DateTime date)
    Parameters
    Type Name Description
    ContentScheduleAction action
    DateTime date
    Returns
    Type Description
    IReadOnlyList<ContentSchedule>
    View Source

    GetSchedule(ContentScheduleAction?)

    Gets the schedule for invariant content

    Declaration
    public IEnumerable<ContentSchedule> GetSchedule(ContentScheduleAction? action = null)
    Parameters
    Type Name Description
    ContentScheduleAction? action
    Returns
    Type Description
    IEnumerable<ContentSchedule>
    View Source

    GetSchedule(string?, ContentScheduleAction?)

    Gets the schedule for a culture

    Declaration
    public IEnumerable<ContentSchedule> GetSchedule(string? culture, ContentScheduleAction? action = null)
    Parameters
    Type Name Description
    string culture
    ContentScheduleAction? action
    Returns
    Type Description
    IEnumerable<ContentSchedule>
    View Source

    Remove(ContentSchedule)

    Remove a scheduled change

    Declaration
    public void Remove(ContentSchedule change)
    Parameters
    Type Name Description
    ContentSchedule change
    View Source

    RemoveIfExists(string, ContentScheduleAction)

    Declaration
    public void RemoveIfExists(string culture, ContentScheduleAction action)
    Parameters
    Type Name Description
    string culture
    ContentScheduleAction action

    Events

    View Source

    CollectionChanged

    Occurs when the collection changes.

    Declaration
    public event NotifyCollectionChangedEventHandler? CollectionChanged
    Event Type
    Type Description
    NotifyCollectionChangedEventHandler
    • Edit this page
    • View Source
    In this article
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX