76 lines
2.5 KiB
C#
76 lines
2.5 KiB
C#
using MediaBrowser.Model.Plugins;
|
|
|
|
namespace Jellyfin.Plugin.YandexMusic.Configuration;
|
|
|
|
/// <summary>
|
|
/// Plugin configuration.
|
|
/// </summary>
|
|
public class PluginConfiguration : BasePluginConfiguration
|
|
{
|
|
/// <summary>
|
|
/// Gets or sets the Yandex OAuth token. Optional, required only for lyrics.
|
|
/// </summary>
|
|
public string Token { get; set; } = string.Empty;
|
|
|
|
/// <summary>
|
|
/// Gets or sets the preferred language for genre names and artist descriptions.
|
|
/// </summary>
|
|
public string Language { get; set; } = "ru";
|
|
|
|
/// <summary>
|
|
/// Gets or sets a value indicating whether song metadata is enabled.
|
|
/// </summary>
|
|
public bool EnableSongMetadata { get; set; } = true;
|
|
|
|
/// <summary>
|
|
/// Gets or sets a value indicating whether album metadata is enabled.
|
|
/// </summary>
|
|
public bool EnableAlbumMetadata { get; set; } = true;
|
|
|
|
/// <summary>
|
|
/// Gets or sets a value indicating whether artist metadata is enabled.
|
|
/// </summary>
|
|
public bool EnableArtistMetadata { get; set; } = true;
|
|
|
|
/// <summary>
|
|
/// Gets or sets a value indicating whether cover art is enabled.
|
|
/// </summary>
|
|
public bool EnableImages { get; set; } = true;
|
|
|
|
/// <summary>
|
|
/// Gets or sets a value indicating whether lyrics are enabled.
|
|
/// </summary>
|
|
public bool EnableLyrics { get; set; } = true;
|
|
|
|
/// <summary>
|
|
/// Gets or sets a value indicating whether the real album title from Yandex is written to the track's Album field.
|
|
/// When disabled (default), the existing album tag is kept.
|
|
/// </summary>
|
|
public bool UseYandexAlbumName { get; set; }
|
|
|
|
/// <summary>
|
|
/// Gets or sets a value indicating whether the original release year from Yandex may replace the year tag.
|
|
/// </summary>
|
|
public bool UseYandexYear { get; set; } = true;
|
|
|
|
/// <summary>
|
|
/// Gets or sets the minimum match score (0..1) required to accept a search result.
|
|
/// </summary>
|
|
public double MatchThreshold { get; set; } = 0.72;
|
|
|
|
/// <summary>
|
|
/// Gets or sets the duration tolerance in seconds used while matching tracks.
|
|
/// </summary>
|
|
public int DurationToleranceSeconds { get; set; } = 12;
|
|
|
|
/// <summary>
|
|
/// Gets or sets a value indicating whether genres from Yandex are written to items.
|
|
/// </summary>
|
|
public bool EnableGenres { get; set; } = true;
|
|
|
|
/// <summary>
|
|
/// Gets or sets a value indicating whether labels are written as studios.
|
|
/// </summary>
|
|
public bool EnableLabels { get; set; } = true;
|
|
}
|