mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-09-28 04:51:45 +02:00
job structure cleanup.
This commit is contained in:
29
NzbDrone.Core/Jobs/Framework/JobQueueItem.cs
Normal file
29
NzbDrone.Core/Jobs/Framework/JobQueueItem.cs
Normal file
@@ -0,0 +1,29 @@
|
||||
using System.Linq;
|
||||
using System;
|
||||
|
||||
namespace NzbDrone.Core.Jobs.Framework
|
||||
{
|
||||
public class JobQueueItem : IEquatable<JobQueueItem>
|
||||
{
|
||||
public Type JobType { get; set; }
|
||||
public dynamic Options { get; set; }
|
||||
|
||||
public JobSourceType Source { get; set; }
|
||||
|
||||
public bool Equals(JobQueueItem other)
|
||||
{
|
||||
return (JobType == other.JobType && Options == other.Options);
|
||||
}
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return string.Format("[{0}({1})]", JobType.Name, Options);
|
||||
}
|
||||
|
||||
public enum JobSourceType
|
||||
{
|
||||
User,
|
||||
Scheduler
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user