jellyfin/MediaBrowser.Server.Implementations/LiveTv/EmbyTV/SeriesTimerManager.cs

28 lines
886 B
C#
Raw Normal View History

2015-07-20 18:32:55 +00:00
using MediaBrowser.Controller.LiveTv;
using MediaBrowser.Model.Logging;
using MediaBrowser.Model.Serialization;
using System;
2015-10-04 04:23:11 +00:00
using CommonIO;
2015-09-13 23:07:54 +00:00
using MediaBrowser.Common.IO;
2015-07-20 18:32:55 +00:00
namespace MediaBrowser.Server.Implementations.LiveTv.EmbyTV
{
public class SeriesTimerManager : ItemDataProvider<SeriesTimerInfo>
{
2015-09-13 23:07:54 +00:00
public SeriesTimerManager(IFileSystem fileSystem, IJsonSerializer jsonSerializer, ILogger logger, string dataPath)
: base(fileSystem, jsonSerializer, logger, dataPath, (r1, r2) => string.Equals(r1.Id, r2.Id, StringComparison.OrdinalIgnoreCase))
2015-07-20 18:32:55 +00:00
{
}
public override void Add(SeriesTimerInfo item)
{
if (string.IsNullOrWhiteSpace(item.Id))
{
throw new ArgumentException("SeriesTimerInfo.Id cannot be null or empty.");
}
base.Add(item);
}
}
}