// Copyright (c) Umbraco.
// See LICENSE for more details.
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
namespace Umbraco.Cms.Core.Configuration.Models
{
///
/// Typed configuration options for healthcheck notification settings.
///
public class HealthChecksNotificationSettings
{
internal const bool StaticEnabled = false;
internal const string StaticPeriod = "1.00:00:00"; //TimeSpan.FromHours(24);
///
/// Gets or sets a value indicating whether health check notifications are enabled.
///
[DefaultValue(StaticEnabled)]
public bool Enabled { get; set; } = StaticEnabled;
///
/// Gets or sets a value for the first run time of a healthcheck notification in crontab format.
///
public string FirstRunTime { get; set; } = string.Empty;
///
/// Gets or sets a value for the period of the healthcheck notification.
///
[DefaultValue(StaticPeriod)]
public TimeSpan Period { get; set; } = TimeSpan.Parse(StaticPeriod);
///
/// Gets or sets a value for the collection of health check notification methods.
///
public IDictionary NotificationMethods { get; set; } = new Dictionary();
///
/// Gets or sets a value for the collection of health checks that are disabled for notifications.
///
public IEnumerable DisabledChecks { get; set; } = Enumerable.Empty();
}
}