mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-21 05:53:33 -07:00
Moved Jobs to their own folder.
This commit is contained in:
parent
cc8c70d7f5
commit
fabc4c84bd
52 changed files with 124 additions and 132 deletions
36
NzbDrone.Core/Jobs/UpdateSceneMappingsJob.cs
Normal file
36
NzbDrone.Core/Jobs/UpdateSceneMappingsJob.cs
Normal file
|
@ -0,0 +1,36 @@
|
|||
using System.Linq;
|
||||
using NzbDrone.Core.Model.Notification;
|
||||
using NzbDrone.Core.Providers;
|
||||
|
||||
namespace NzbDrone.Core.Jobs
|
||||
{
|
||||
public abstract class UpdateSceneMappingsJob : IJob
|
||||
{
|
||||
private readonly SceneMappingProvider _sceneNameMappingProvider;
|
||||
|
||||
public UpdateSceneMappingsJob(SceneMappingProvider sceneNameMappingProvider)
|
||||
{
|
||||
_sceneNameMappingProvider = sceneNameMappingProvider;
|
||||
}
|
||||
|
||||
public UpdateSceneMappingsJob()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public string Name
|
||||
{
|
||||
get { return "Update Scene Mappings"; }
|
||||
}
|
||||
|
||||
public int DefaultInterval
|
||||
{
|
||||
get { return 720; } //Every 12 hours
|
||||
}
|
||||
|
||||
public virtual void Start(ProgressNotification notification, int targetId, int secondaryTargetId)
|
||||
{
|
||||
_sceneNameMappingProvider.UpdateMappings();
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue