using System.Collections.Generic; using Kyoo.Common.Models.Attributes; using Kyoo.Models.Attributes; namespace Kyoo.Models { /// /// A genre that allow one to specify categories for shows. /// public class Genre : IResource { /// public int ID { get; set; } /// public string Slug { get; set; } /// /// The name of this genre. /// public string Name { get; set; } /// /// The list of shows that have this genre. /// [LoadableRelation] public ICollection Shows { get; set; } #if ENABLE_INTERNAL_LINKS /// /// The internal link between this genre and shows in the list. /// [Link] public ICollection> ShowLinks { get; set; } #endif /// /// Create a new, empty . /// public Genre() {} /// /// Create a new and specify it's . /// The is automatically calculated from it's name. /// /// The name of this genre. public Genre(string name) { Slug = Utility.ToSlug(name); Name = name; } } }