using MediaBrowser.Controller.Entities;
using MediaBrowser.Controller.Library;
using MediaBrowser.Model.Configuration;
using MediaBrowser.Model.Entities;
using MediaBrowser.Model.Providers;
using System.Collections.Generic;
using System.IO;
using System.Threading;
using System.Threading.Tasks;
namespace MediaBrowser.Controller.Providers
{
///
/// Interface IProviderManager
///
public interface IProviderManager
{
///
/// Refreshes the metadata.
///
/// The item.
/// The options.
/// The cancellation token.
/// Task.
Task RefreshMetadata(IHasMetadata item, MetadataRefreshOptions options, CancellationToken cancellationToken);
///
/// Saves the image.
///
/// The item.
/// The URL.
/// The resource pool.
/// The type.
/// Index of the image.
/// The cancellation token.
/// Task.
Task SaveImage(BaseItem item, string url, SemaphoreSlim resourcePool, ImageType type, int? imageIndex, CancellationToken cancellationToken);
///
/// Saves the image.
///
/// The item.
/// The source.
/// Type of the MIME.
/// The type.
/// Index of the image.
/// The cancellation token.
/// Task.
Task SaveImage(BaseItem item, Stream source, string mimeType, ImageType type, int? imageIndex, CancellationToken cancellationToken);
///
/// Adds the metadata providers.
///
/// The image providers.
/// The metadata services.
/// The metadata providers.
/// The savers.
void AddParts(IEnumerable imageProviders, IEnumerable metadataServices, IEnumerable metadataProviders,
IEnumerable savers);
///
/// Gets the available remote images.
///
/// The item.
/// The query.
/// The cancellation token.
/// Task{IEnumerable{RemoteImageInfo}}.
Task> GetAvailableRemoteImages(IHasImages item, RemoteImageQuery query, CancellationToken cancellationToken);
///
/// Gets the image providers.
///
/// The item.
/// IEnumerable{ImageProviderInfo}.
IEnumerable GetRemoteImageProviderInfo(IHasImages item);
///
/// Gets all metadata plugins.
///
/// IEnumerable{MetadataPlugin}.
IEnumerable GetAllMetadataPlugins();
///
/// Saves the metadata.
///
/// The item.
/// Type of the update.
/// Task.
Task SaveMetadata(IHasMetadata item, ItemUpdateType updateType);
///
/// Gets the metadata options.
///
/// The item.
/// MetadataOptions.
MetadataOptions GetMetadataOptions(IHasImages item);
}
}