LiveTvOptions.cs 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. using System.Collections.Generic;
  2. using MediaBrowser.Model.Dto;
  3. using MediaBrowser.Model.Extensions;
  4. namespace MediaBrowser.Model.LiveTv
  5. {
  6. public class LiveTvOptions
  7. {
  8. public int? GuideDays { get; set; }
  9. public bool EnableMovieProviders { get; set; }
  10. public string RecordingPath { get; set; }
  11. public string MovieRecordingPath { get; set; }
  12. public string SeriesRecordingPath { get; set; }
  13. public bool EnableRecordingEncoding { get; set; }
  14. public string RecordingEncodingFormat { get; set; }
  15. public bool EnableRecordingSubfolders { get; set; }
  16. public bool EnableOriginalAudioWithEncodedRecordings { get; set; }
  17. public string RecordedVideoCodec { get; set; }
  18. public List<TunerHostInfo> TunerHosts { get; set; }
  19. public List<ListingsProviderInfo> ListingProviders { get; set; }
  20. public int PrePaddingSeconds { get; set; }
  21. public int PostPaddingSeconds { get; set; }
  22. public string[] MediaLocationsCreated { get; set; }
  23. public string RecordingPostProcessor { get; set; }
  24. public string RecordingPostProcessorArguments { get; set; }
  25. public LiveTvOptions()
  26. {
  27. EnableMovieProviders = true;
  28. TunerHosts = new List<TunerHostInfo>();
  29. ListingProviders = new List<ListingsProviderInfo>();
  30. MediaLocationsCreated = new string[] { };
  31. RecordingEncodingFormat = "mp4";
  32. RecordingPostProcessorArguments = "\"{path}\"";
  33. EnableRecordingEncoding = true;
  34. }
  35. }
  36. public class TunerHostInfo
  37. {
  38. public string Id { get; set; }
  39. public string Url { get; set; }
  40. public string Type { get; set; }
  41. public string DeviceId { get; set; }
  42. public bool ImportFavoritesOnly { get; set; }
  43. public bool AllowHWTranscoding { get; set; }
  44. public bool IsEnabled { get; set; }
  45. public bool EnableTvgId { get; set; }
  46. public TunerHostInfo()
  47. {
  48. IsEnabled = true;
  49. AllowHWTranscoding = true;
  50. }
  51. }
  52. public class ListingsProviderInfo
  53. {
  54. public string Id { get; set; }
  55. public string Type { get; set; }
  56. public string Username { get; set; }
  57. public string Password { get; set; }
  58. public string ListingsId { get; set; }
  59. public string ZipCode { get; set; }
  60. public string Country { get; set; }
  61. public string Path { get; set; }
  62. public string[] EnabledTuners { get; set; }
  63. public bool EnableAllTuners { get; set; }
  64. public string[] NewsCategories { get; set; }
  65. public string[] SportsCategories { get; set; }
  66. public string[] KidsCategories { get; set; }
  67. public string[] MovieCategories { get; set; }
  68. public NameValuePair[] ChannelMappings { get; set; }
  69. public string MoviePrefix { get; set; }
  70. public bool EnableNewProgramIds { get; set; }
  71. public ListingsProviderInfo()
  72. {
  73. NewsCategories = new string[] { "news", "journalism", "documentary", "current affairs" };
  74. SportsCategories = new string[] { "sports", "basketball", "baseball", "football" };
  75. KidsCategories = new string[] { "kids", "family", "children", "childrens", "disney" };
  76. MovieCategories = new string[] { "movie" };
  77. EnabledTuners = new string[] { };
  78. EnableAllTuners = true;
  79. ChannelMappings = new NameValuePair[] {};
  80. }
  81. }
  82. }