2012-09-04 08:49:04 +02:00
|
|
|
|
using System.Linq;
|
|
|
|
|
using System;
|
|
|
|
|
using Ninject;
|
|
|
|
|
using NLog;
|
|
|
|
|
using NzbDrone.Core.Model.Notification;
|
|
|
|
|
using NzbDrone.Core.Providers;
|
|
|
|
|
using NzbDrone.Core.Providers.Converting;
|
|
|
|
|
|
|
|
|
|
namespace NzbDrone.Core.Jobs
|
|
|
|
|
{
|
|
|
|
|
public class EmptyRecycleBinJob : IJob
|
|
|
|
|
{
|
|
|
|
|
private readonly RecycleBinProvider _recycleBinProvider;
|
|
|
|
|
|
|
|
|
|
[Inject]
|
|
|
|
|
public EmptyRecycleBinJob(RecycleBinProvider recycleBinProvider)
|
|
|
|
|
{
|
|
|
|
|
_recycleBinProvider = recycleBinProvider;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public string Name
|
|
|
|
|
{
|
|
|
|
|
get { return "Empty Recycle Bin"; }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public TimeSpan DefaultInterval
|
|
|
|
|
{
|
|
|
|
|
get { return TimeSpan.FromTicks(0); }
|
|
|
|
|
}
|
|
|
|
|
|
2012-09-10 21:04:17 +02:00
|
|
|
|
public void Start(ProgressNotification notification, dynamic options)
|
2012-09-04 08:49:04 +02:00
|
|
|
|
{
|
|
|
|
|
_recycleBinProvider.Empty();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|