TvExternalIds.cs 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. using MediaBrowser.Controller.Entities.TV;
  2. using MediaBrowser.Controller.Providers;
  3. using MediaBrowser.Model.Entities;
  4. using MediaBrowser.Providers.TV.TheTVDB;
  5. namespace MediaBrowser.Providers.TV
  6. {
  7. public class Zap2ItExternalId : IExternalId
  8. {
  9. public string Name => "Zap2It";
  10. public string Key => MetadataProviders.Zap2It.ToString();
  11. public string UrlFormatString => "http://tvlistings.zap2it.com/overview.html?programSeriesId={0}";
  12. public bool Supports(IHasProviderIds item)
  13. {
  14. return item is Series;
  15. }
  16. }
  17. public class TvdbExternalId : IExternalId
  18. {
  19. public string Name => "TheTVDB";
  20. public string Key => MetadataProviders.Tvdb.ToString();
  21. public string UrlFormatString => TvdbUtils.TvdbBaseUrl + "?tab=series&id={0}";
  22. public bool Supports(IHasProviderIds item)
  23. {
  24. return item is Series;
  25. }
  26. }
  27. public class TvdbSeasonExternalId : IExternalId
  28. {
  29. public string Name => "TheTVDB";
  30. public string Key => MetadataProviders.Tvdb.ToString();
  31. public string UrlFormatString => null;
  32. public bool Supports(IHasProviderIds item)
  33. {
  34. return item is Season;
  35. }
  36. }
  37. public class TvdbEpisodeExternalId : IExternalId
  38. {
  39. public string Name => "TheTVDB";
  40. public string Key => MetadataProviders.Tvdb.ToString();
  41. public string UrlFormatString => TvdbUtils.TvdbBaseUrl + "?tab=episode&id={0}";
  42. public bool Supports(IHasProviderIds item)
  43. {
  44. return item is Episode;
  45. }
  46. }
  47. }