From e56477abb057a327552fe3d95d46349153566fe1 Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Fri, 13 Apr 2012 16:44:23 -0700 Subject: [PATCH] New: Womble's Index --- NzbDrone.Core/NzbDrone.Core.csproj | 1 + NzbDrone.Core/Providers/Indexer/Wombles.cs | 79 ++++++++++++++++++++++ 2 files changed, 80 insertions(+) create mode 100644 NzbDrone.Core/Providers/Indexer/Wombles.cs diff --git a/NzbDrone.Core/NzbDrone.Core.csproj b/NzbDrone.Core/NzbDrone.Core.csproj index 7d67e161f..af92c6e02 100644 --- a/NzbDrone.Core/NzbDrone.Core.csproj +++ b/NzbDrone.Core/NzbDrone.Core.csproj @@ -273,6 +273,7 @@ + diff --git a/NzbDrone.Core/Providers/Indexer/Wombles.cs b/NzbDrone.Core/Providers/Indexer/Wombles.cs new file mode 100644 index 000000000..f000545ec --- /dev/null +++ b/NzbDrone.Core/Providers/Indexer/Wombles.cs @@ -0,0 +1,79 @@ +using System; +using System.Collections.Generic; +using System.ServiceModel.Syndication; +using System.Text.RegularExpressions; +using Ninject; +using NzbDrone.Common; +using NzbDrone.Core.Model; +using NzbDrone.Core.Providers.Core; + +namespace NzbDrone.Core.Providers.Indexer +{ + public class Wombles : IndexerBase + { + [Inject] + public Wombles(HttpProvider httpProvider, ConfigProvider configProvider) : base(httpProvider, configProvider) + { + } + + protected override string[] Urls + { + get + { + return new[] + { + string.Format("http://nzb.isasecret.com/rss") + }; + } + } + + public override bool IsConfigured + { + get + { + return true; + } + } + + public override string Name + { + get { return "Wombles"; } + } + + protected override string NzbDownloadUrl(SyndicationItem item) + { + return item.Links[0].Uri.ToString(); + } + + + protected override IList GetEpisodeSearchUrls(string seriesTitle, int seasonNumber, int episodeNumber) + { + return new List(); + } + + protected override IList GetSeasonSearchUrls(string seriesTitle, int seasonNumber) + { + return new List(); + } + + protected override IList GetDailyEpisodeSearchUrls(string seriesTitle, DateTime date) + { + return new List(); + } + + protected override IList GetPartialSeasonSearchUrls(string seriesTitle, int seasonNumber, int episodeWildcard) + { + return new List(); + } + + protected override EpisodeParseResult CustomParser(SyndicationItem item, EpisodeParseResult currentResult) + { + if (currentResult != null) + { + currentResult.Size = 0; + } + + return currentResult; + } + } +} \ No newline at end of file