using MediaBrowser.Controller.Library;
using Microsoft.Extensions.Logging;
using System;
using System.Threading;
using System.Threading.Tasks;
using MediaBrowser.Controller.Persistence;
namespace Emby.Server.Implementations.Library.Validators
{
///
/// Class MusicGenresPostScanTask
///
public class MusicGenresPostScanTask : ILibraryPostScanTask
{
///
/// The _library manager
///
private readonly ILibraryManager _libraryManager;
private readonly ILogger _logger;
private readonly IItemRepository _itemRepo;
///
/// Initializes a new instance of the class.
///
/// The library manager.
/// The logger.
public MusicGenresPostScanTask(ILibraryManager libraryManager, ILogger logger, IItemRepository itemRepo)
{
_libraryManager = libraryManager;
_logger = logger;
_itemRepo = itemRepo;
}
///
/// Runs the specified progress.
///
/// The progress.
/// The cancellation token.
/// Task.
public Task Run(IProgress progress, CancellationToken cancellationToken)
{
return new MusicGenresValidator(_libraryManager, _logger, _itemRepo).Run(progress, cancellationToken);
}
}
}