using System; using System.Collections.Generic; namespace DTOs { public class LibraryDTO { // // must initialize optional collections // public string ProductId { get; set; } public string Title { get; set; } /// Whether this product is episodic. These will not have a book download link or personal library ratings public bool IsEpisodes { get; set; } // order matters. do not use a hashtable/dictionary public List<(string authorName, string authorId)> Authors { get; set; } = new List<(string name, string id)>(); public string[] Narrators { get; set; } = new string[0]; public int LengthInMinutes { get; set; } public string Description { get; set; } public string PictureId { get; set; } /// Key: Id. Value: Name public Dictionary Series { get; } = new Dictionary(); // aggregate community ratings for this product public float Product_OverallStars { get; set; } public float Product_PerformanceStars { get; set; } public float Product_StoryStars { get; set; } // my personal user ratings for this product (only products i own. ie: in library) public int MyUserRating_Overall { get; set; } public int MyUserRating_Performance { get; set; } public int MyUserRating_Story { get; set; } public List SupplementUrls { get; set; } = new List(); public DateTime DateAdded { get; set; } public string DownloadBookLink { get; set; } public override string ToString() => $"[{ProductId}] {Title}"; } }