Set default Metadata name

pull/6/head
Mark McDowall 10 years ago
parent 0e865fff8c
commit e296d94417

@ -30,6 +30,14 @@ namespace NzbDrone.Core.Metadata.Consumers.MediaBrowser
_logger = logger;
}
public override string Name
{
get
{
return "Emby (Media Browser)";
}
}
public override List<MetadataFile> AfterRename(Series series, List<MetadataFile> existingMetadataFiles, List<EpisodeFile> episodeFiles)
{
var updatedMetadataFiles = new List<MetadataFile>();

@ -34,6 +34,14 @@ namespace NzbDrone.Core.Metadata.Consumers.Roksbox
private static List<string> ValidCertification = new List<string> { "G", "NC-17", "PG", "PG-13", "R", "UR", "UNRATED", "NR", "TV-Y", "TV-Y7", "TV-Y7-FV", "TV-G", "TV-PG", "TV-14", "TV-MA" };
private static readonly Regex SeasonImagesRegex = new Regex(@"^(season (?<season>\d+))|(?<specials>specials)", RegexOptions.Compiled | RegexOptions.IgnoreCase);
public override string Name
{
get
{
return "Roksbox";
}
}
public override List<MetadataFile> AfterRename(Series series, List<MetadataFile> existingMetadataFiles, List<EpisodeFile> episodeFiles)
{
var episodeFilesMetadata = existingMetadataFiles.Where(c => c.EpisodeFileId > 0).ToList();

@ -33,6 +33,14 @@ namespace NzbDrone.Core.Metadata.Consumers.Wdtv
private static readonly Regex SeasonImagesRegex = new Regex(@"^(season (?<season>\d+))|(?<specials>specials)", RegexOptions.Compiled | RegexOptions.IgnoreCase);
public override string Name
{
get
{
return "WDTV";
}
}
public override List<MetadataFile> AfterRename(Series series, List<MetadataFile> existingMetadataFiles, List<EpisodeFile> episodeFiles)
{
var episodeFilesMetadata = existingMetadataFiles.Where(c => c.EpisodeFileId > 0).ToList();

@ -35,6 +35,14 @@ namespace NzbDrone.Core.Metadata.Consumers.Xbmc
private static readonly Regex SeasonImagesRegex = new Regex(@"^season(?<season>\d{2,}|-all|-specials)-(?<type>poster|banner|fanart)\.(?:png|jpg)", RegexOptions.Compiled | RegexOptions.IgnoreCase);
private static readonly Regex EpisodeImageRegex = new Regex(@"-thumb\.(?:png|jpg)", RegexOptions.Compiled | RegexOptions.IgnoreCase);
public override string Name
{
get
{
return "Kodi (XBMC)";
}
}
public override List<MetadataFile> AfterRename(Series series, List<MetadataFile> existingMetadataFiles, List<EpisodeFile> episodeFiles)
{
var episodeFilesMetadata = existingMetadataFiles.Where(c => c.EpisodeFileId > 0).ToList();

@ -32,7 +32,7 @@ namespace NzbDrone.Core.Metadata
definitions.Add(new MetadataDefinition
{
Enable = false,
Name = provider.GetType().Name.Replace("Metadata", ""),
Name = provider.Name,
Implementation = provider.GetType().Name,
Settings = (IProviderConfig)Activator.CreateInstance(provider.ConfigContract)
});

@ -10,13 +10,7 @@ namespace NzbDrone.Core.Metadata
{
public abstract class MetadataBase<TSettings> : IMetadata where TSettings : IProviderConfig, new()
{
public string Name
{
get
{
return GetType().Name;
}
}
public abstract string Name { get; }
public Type ConfigContract
{

Loading…
Cancel
Save