using MediaBrowser.Controller.Entities;
using MediaBrowser.Controller.Library;
using MediaBrowser.Controller.Persistence;
using System;
using System.Threading;
using System.Threading.Tasks;
namespace MediaBrowser.Server.Implementations.Library
{
///
/// Class UserDataManager
///
public class UserDataManager : IUserDataManager
{
///
/// Gets or sets the repository.
///
/// The repository.
public IUserDataRepository Repository { get; set; }
///
/// Saves the user data.
///
/// The user id.
/// The key.
/// The user data.
/// The cancellation token.
/// Task.
public Task SaveUserData(Guid userId, string key, UserItemData userData, CancellationToken cancellationToken)
{
return Repository.SaveUserData(userId, key, userData, cancellationToken);
}
///
/// Gets the user data.
///
/// The user id.
/// The key.
/// Task{UserItemData}.
public UserItemData GetUserData(Guid userId, string key)
{
return Repository.GetUserData(userId, key);
}
}
}