mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-06-04 23:08:42 +01:00
Fix some warnings
This commit is contained in:
@@ -23,10 +23,6 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts
|
||||
{
|
||||
public abstract class BaseTunerHost
|
||||
{
|
||||
protected readonly IServerConfigurationManager Config;
|
||||
protected readonly ILogger<BaseTunerHost> Logger;
|
||||
protected readonly IFileSystem FileSystem;
|
||||
|
||||
private readonly IMemoryCache _memoryCache;
|
||||
|
||||
protected BaseTunerHost(IServerConfigurationManager config, ILogger<BaseTunerHost> logger, IFileSystem fileSystem, IMemoryCache memoryCache)
|
||||
@@ -37,12 +33,20 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts
|
||||
FileSystem = fileSystem;
|
||||
}
|
||||
|
||||
protected IServerConfigurationManager Config { get; }
|
||||
|
||||
protected ILogger<BaseTunerHost> Logger { get; }
|
||||
|
||||
protected IFileSystem FileSystem { get; }
|
||||
|
||||
public virtual bool IsSupported => true;
|
||||
|
||||
protected abstract Task<List<ChannelInfo>> GetChannelsInternal(TunerHostInfo tuner, CancellationToken cancellationToken);
|
||||
|
||||
public abstract string Type { get; }
|
||||
|
||||
protected virtual string ChannelIdPrefix => Type + "_";
|
||||
|
||||
protected abstract Task<List<ChannelInfo>> GetChannelsInternal(TunerHostInfo tuner, CancellationToken cancellationToken);
|
||||
|
||||
public async Task<List<ChannelInfo>> GetChannels(TunerHostInfo tuner, bool enableCache, CancellationToken cancellationToken)
|
||||
{
|
||||
var key = tuner.Id;
|
||||
@@ -217,8 +221,6 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts
|
||||
throw new LiveTvConflictException();
|
||||
}
|
||||
|
||||
protected virtual string ChannelIdPrefix => Type + "_";
|
||||
|
||||
protected virtual bool IsValidChannelId(string channelId)
|
||||
{
|
||||
if (string.IsNullOrEmpty(channelId))
|
||||
|
||||
@@ -101,7 +101,8 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts.HdHomerun
|
||||
}
|
||||
}
|
||||
|
||||
if (localAddress.IsIPv4MappedToIPv6) {
|
||||
if (localAddress.IsIPv4MappedToIPv6)
|
||||
{
|
||||
localAddress = localAddress.MapToIPv4();
|
||||
}
|
||||
|
||||
|
||||
@@ -20,14 +20,6 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts
|
||||
{
|
||||
private readonly IConfigurationManager _configurationManager;
|
||||
|
||||
protected readonly IFileSystem FileSystem;
|
||||
|
||||
protected readonly IStreamHelper StreamHelper;
|
||||
|
||||
protected string TempFilePath;
|
||||
protected readonly ILogger Logger;
|
||||
protected readonly CancellationTokenSource LiveStreamCancellationTokenSource = new CancellationTokenSource();
|
||||
|
||||
public LiveStream(
|
||||
MediaSourceInfo mediaSource,
|
||||
TunerHostInfo tuner,
|
||||
@@ -55,7 +47,15 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts
|
||||
SetTempFilePath("ts");
|
||||
}
|
||||
|
||||
protected virtual int EmptyReadLimit => 1000;
|
||||
protected IFileSystem FileSystem { get; }
|
||||
|
||||
protected IStreamHelper StreamHelper { get; }
|
||||
|
||||
protected ILogger Logger { get; }
|
||||
|
||||
protected CancellationTokenSource LiveStreamCancellationTokenSource { get; } = new CancellationTokenSource();
|
||||
|
||||
protected string TempFilePath { get; set; }
|
||||
|
||||
public MediaSourceInfo OriginalMediaSource { get; set; }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user