BaseItemInfo.cs 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. using System;
  2. using System.Diagnostics;
  3. using System.Runtime.Serialization;
  4. namespace MediaBrowser.Model.Entities
  5. {
  6. /// <summary>
  7. /// This is a stub class containing only basic information about an item
  8. /// </summary>
  9. [DebuggerDisplay("Name = {Name}, ID = {Id}, Type = {Type}")]
  10. public class BaseItemInfo
  11. {
  12. /// <summary>
  13. /// Gets or sets the name.
  14. /// </summary>
  15. /// <value>The name.</value>
  16. public string Name { get; set; }
  17. /// <summary>
  18. /// Gets or sets the id.
  19. /// </summary>
  20. /// <value>The id.</value>
  21. public string Id { get; set; }
  22. /// <summary>
  23. /// Gets or sets the type.
  24. /// </summary>
  25. /// <value>The type.</value>
  26. public string Type { get; set; }
  27. /// <summary>
  28. /// Gets or sets the type of the media.
  29. /// </summary>
  30. /// <value>The type of the media.</value>
  31. public string MediaType { get; set; }
  32. /// <summary>
  33. /// Gets or sets the run time ticks.
  34. /// </summary>
  35. /// <value>The run time ticks.</value>
  36. public long? RunTimeTicks { get; set; }
  37. /// <summary>
  38. /// Gets or sets the primary image tag.
  39. /// </summary>
  40. /// <value>The primary image tag.</value>
  41. public Guid? PrimaryImageTag { get; set; }
  42. /// <summary>
  43. /// Gets or sets the thumb image tag.
  44. /// </summary>
  45. /// <value>The thumb image tag.</value>
  46. public Guid? ThumbImageTag { get; set; }
  47. /// <summary>
  48. /// Gets or sets the thumb item identifier.
  49. /// </summary>
  50. /// <value>The thumb item identifier.</value>
  51. public string ThumbItemId { get; set; }
  52. /// <summary>
  53. /// Gets or sets the thumb image tag.
  54. /// </summary>
  55. /// <value>The thumb image tag.</value>
  56. public Guid? BackdropImageTag { get; set; }
  57. /// <summary>
  58. /// Gets or sets the thumb item identifier.
  59. /// </summary>
  60. /// <value>The thumb item identifier.</value>
  61. public string BackdropItemId { get; set; }
  62. /// <summary>
  63. /// Gets or sets the media version identifier.
  64. /// </summary>
  65. /// <value>The media version identifier.</value>
  66. public string MediaSourceId { get; set; }
  67. /// <summary>
  68. /// Gets a value indicating whether this instance has primary image.
  69. /// </summary>
  70. /// <value><c>true</c> if this instance has primary image; otherwise, <c>false</c>.</value>
  71. [IgnoreDataMember]
  72. public bool HasPrimaryImage
  73. {
  74. get { return PrimaryImageTag.HasValue; }
  75. }
  76. }
  77. }