using System; using System.Diagnostics; namespace Umbraco.Cms.Core.Models.PublishedContent { /// /// Contains culture specific values for . /// [DebuggerDisplay("{Culture}")] public class PublishedCultureInfo { /// /// Initializes a new instance of the class. /// public PublishedCultureInfo(string culture, string name, string urlSegment, DateTime date) { if (name == null) throw new ArgumentNullException(nameof(name)); if (string.IsNullOrWhiteSpace(name)) throw new ArgumentException("Value can't be empty or consist only of white-space characters.", nameof(name)); Culture = culture ?? throw new ArgumentNullException(nameof(culture)); Name = name; UrlSegment = urlSegment; Date = date; } /// /// Gets the culture. /// public string Culture { get; } /// /// Gets the name of the item. /// public string Name { get; } /// /// Gets the URL segment of the item. /// public string UrlSegment { get; } /// /// Gets the date associated with the culture. /// /// /// For published culture, this is the date the culture was published. For draft /// cultures, this is the date the culture was made available, ie the last time its /// name changed. /// public DateTime Date { get; } } }