SeriesMetadata.cs 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. using System.Collections.Generic;
  2. using System.ComponentModel.DataAnnotations;
  3. using Jellyfin.Data.Interfaces;
  4. namespace Jellyfin.Data.Entities.Libraries
  5. {
  6. /// <summary>
  7. /// An entity representing series metadata.
  8. /// </summary>
  9. public class SeriesMetadata : ItemMetadata, IHasCompanies
  10. {
  11. /// <summary>
  12. /// Initializes a new instance of the <see cref="SeriesMetadata"/> class.
  13. /// </summary>
  14. /// <param name="title">The title or name of the object.</param>
  15. /// <param name="language">ISO-639-3 3-character language codes.</param>
  16. public SeriesMetadata(string title, string language) : base(title, language)
  17. {
  18. Networks = new HashSet<Company>();
  19. }
  20. /// <summary>
  21. /// Gets or sets the outline.
  22. /// </summary>
  23. /// <remarks>
  24. /// Max length = 1024.
  25. /// </remarks>
  26. [MaxLength(1024)]
  27. [StringLength(1024)]
  28. public string? Outline { get; set; }
  29. /// <summary>
  30. /// Gets or sets the plot.
  31. /// </summary>
  32. /// <remarks>
  33. /// Max length = 65535.
  34. /// </remarks>
  35. [MaxLength(65535)]
  36. [StringLength(65535)]
  37. public string? Plot { get; set; }
  38. /// <summary>
  39. /// Gets or sets the tagline.
  40. /// </summary>
  41. /// <remarks>
  42. /// Max length = 1024.
  43. /// </remarks>
  44. [MaxLength(1024)]
  45. [StringLength(1024)]
  46. public string? Tagline { get; set; }
  47. /// <summary>
  48. /// Gets or sets the country code.
  49. /// </summary>
  50. /// <remarks>
  51. /// Max length = 2.
  52. /// </remarks>
  53. [MaxLength(2)]
  54. [StringLength(2)]
  55. public string? Country { get; set; }
  56. /// <summary>
  57. /// Gets a collection containing the networks.
  58. /// </summary>
  59. public virtual ICollection<Company> Networks { get; private set; }
  60. /// <inheritdoc />
  61. public ICollection<Company> Companies => Networks;
  62. }
  63. }