BaseItemPerson.cs 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. using System;
  2. using System.ComponentModel;
  3. using System.Diagnostics;
  4. using System.Runtime.Serialization;
  5. namespace MediaBrowser.Model.Dto
  6. {
  7. /// <summary>
  8. /// This is used by the api to get information about a Person within a BaseItem
  9. /// </summary>
  10. [DebuggerDisplay("Name = {Name}, Role = {Role}, Type = {Type}")]
  11. public class BaseItemPerson : INotifyPropertyChanged
  12. {
  13. /// <summary>
  14. /// Gets or sets the name.
  15. /// </summary>
  16. /// <value>The name.</value>
  17. public string Name { get; set; }
  18. /// <summary>
  19. /// Gets or sets the role.
  20. /// </summary>
  21. /// <value>The role.</value>
  22. public string Role { get; set; }
  23. /// <summary>
  24. /// Gets or sets the type.
  25. /// </summary>
  26. /// <value>The type.</value>
  27. public string Type { get; set; }
  28. /// <summary>
  29. /// Gets or sets the primary image tag.
  30. /// </summary>
  31. /// <value>The primary image tag.</value>
  32. public Guid? PrimaryImageTag { get; set; }
  33. /// <summary>
  34. /// Gets a value indicating whether this instance has primary image.
  35. /// </summary>
  36. /// <value><c>true</c> if this instance has primary image; otherwise, <c>false</c>.</value>
  37. [IgnoreDataMember]
  38. public bool HasPrimaryImage
  39. {
  40. get
  41. {
  42. return PrimaryImageTag.HasValue;
  43. }
  44. }
  45. /// <summary>
  46. /// Occurs when [property changed].
  47. /// </summary>
  48. public event PropertyChangedEventHandler PropertyChanged;
  49. }
  50. }