mirror of
https://github.com/Radarr/Radarr.git
synced 2024-09-17 15:02:34 +02:00
Set default Metadata name
This commit is contained in:
parent
0e865fff8c
commit
e296d94417
@ -30,6 +30,14 @@ public MediaBrowserMetadata(IMapCoversToLocal mediaCoverService,
|
||||
_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 @@ public RoksboxMetadata(IMapCoversToLocal mediaCoverService,
|
||||
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 @@ public WdtvMetadata(IMapCoversToLocal mediaCoverService,
|
||||
|
||||
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 @@ public XbmcMetadata(IMapCoversToLocal mediaCoverService,
|
||||
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 @@ protected override void InitializeProviders()
|
||||
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…
Reference in New Issue
Block a user