2
0

IKeyframeRepository.cs 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Threading;
  4. using System.Threading.Tasks;
  5. using Jellyfin.MediaEncoding.Keyframes;
  6. namespace MediaBrowser.Controller.Persistence;
  7. /// <summary>
  8. /// Provides methods for accessing keyframe data.
  9. /// </summary>
  10. public interface IKeyframeRepository
  11. {
  12. /// <summary>
  13. /// Gets the keyframe data.
  14. /// </summary>
  15. /// <param name="itemId">The item id.</param>
  16. /// <returns>The keyframe data.</returns>
  17. IReadOnlyList<KeyframeData> GetKeyframeData(Guid itemId);
  18. /// <summary>
  19. /// Saves the keyframe data.
  20. /// </summary>
  21. /// <param name="itemId">The item id.</param>
  22. /// <param name="data">The keyframe data.</param>
  23. /// <param name="cancellationToken">The cancellation token.</param>
  24. /// <returns>The task object representing the asynchronous operation.</returns>
  25. Task SaveKeyframeDataAsync(Guid itemId, KeyframeData data, CancellationToken cancellationToken);
  26. /// <summary>
  27. /// Deletes the keyframe data.
  28. /// </summary>
  29. /// <param name="itemId">The item id.</param>
  30. /// <param name="cancellationToken">The cancellation token.</param>
  31. /// <returns>The task object representing the asynchronous operation.</returns>
  32. Task DeleteKeyframeDataAsync(Guid itemId, CancellationToken cancellationToken);
  33. }