ItemImageInfo.cs 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. using MediaBrowser.Model.Entities;
  2. using System;
  3. using MediaBrowser.Model.Serialization;
  4. namespace MediaBrowser.Controller.Entities
  5. {
  6. public class ItemImageInfo
  7. {
  8. /// <summary>
  9. /// Gets or sets the path.
  10. /// </summary>
  11. /// <value>The path.</value>
  12. public string Path { get; set; }
  13. /// <summary>
  14. /// Gets or sets the type.
  15. /// </summary>
  16. /// <value>The type.</value>
  17. public ImageType Type { get; set; }
  18. /// <summary>
  19. /// Gets or sets the date modified.
  20. /// </summary>
  21. /// <value>The date modified.</value>
  22. public DateTime DateModified { get; set; }
  23. public int Width { get; set; }
  24. public int Height { get; set; }
  25. [IgnoreDataMember]
  26. public bool IsLocalFile
  27. {
  28. get
  29. {
  30. if (Path != null)
  31. {
  32. if (Path.StartsWith("http", StringComparison.OrdinalIgnoreCase))
  33. {
  34. return false;
  35. }
  36. }
  37. return true;
  38. }
  39. }
  40. }
  41. }