mirror of
https://github.com/BinaryAlley/Nemera.git
synced 2026-12-03 05:11:10 +00:00
Adds artwork provider system and Calibre plugin
This commit is contained in:
1 parent
c82fadc7a2
commit
6693ff3f60
124 files changed
+9715
-74
No files matched your search
+28
@@ -0,0 +1,28 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using Lumina.Application.Common.DataAccess.Entities.Plugins;
|
||||
using Lumina.Contracts.Responses.Plugins;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Application.Common.Mapping.Plugins;
|
||||
|
||||
/// <summary>
|
||||
/// Extension methods for converting <see cref="LibraryArtworkProviderConfigurationEntity"/>.
|
||||
/// </summary>
|
||||
public static class LibraryArtworkProviderConfigurationEntityMapping
|
||||
{
|
||||
/// <summary>
|
||||
/// Converts <paramref name="configuration"/> to <see cref="LibraryArtworkProviderResponse"/>.
|
||||
/// </summary>
|
||||
/// <param name="configuration">The repository entity to be converted.</param>
|
||||
/// <param name="providerName">The display name of the artwork provider.</param>
|
||||
/// <returns>The converted response.</returns>
|
||||
public static LibraryArtworkProviderResponse ToResponse(this LibraryArtworkProviderConfigurationEntity configuration, string providerName)
|
||||
{
|
||||
return new LibraryArtworkProviderResponse(
|
||||
PluginId: configuration.PluginId,
|
||||
Name: providerName,
|
||||
IsEnabled: configuration.IsEnabled,
|
||||
Rank: configuration.Rank
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user