IServerSyncProvider.cs 1.1 KB

1234567891011121314151617181920212223242526272829303132
  1. #nullable disable
  2. #pragma warning disable CS1591
  3. using System;
  4. using System.IO;
  5. using System.Threading;
  6. using System.Threading.Tasks;
  7. using MediaBrowser.Model.IO;
  8. using MediaBrowser.Model.Querying;
  9. using MediaBrowser.Model.Sync;
  10. namespace MediaBrowser.Controller.Sync
  11. {
  12. public interface IServerSyncProvider : ISyncProvider
  13. {
  14. /// <summary>
  15. /// Transfers the file.
  16. /// </summary>
  17. Task<SyncedFileInfo> SendFile(SyncJob syncJob, string originalMediaPath, Stream inputStream, bool isMedia, string[] outputPathParts, SyncTarget target, IProgress<double> progress, CancellationToken cancellationToken);
  18. Task<QueryResult<FileSystemMetadata>> GetFiles(string[] directoryPathParts, SyncTarget target, CancellationToken cancellationToken);
  19. }
  20. public interface ISupportsDirectCopy
  21. {
  22. /// <summary>
  23. /// Sends the file.
  24. /// </summary>
  25. Task<SyncedFileInfo> SendFile(SyncJob syncJob, string originalMediaPath, string inputPath, bool isMedia, string[] outputPathParts, SyncTarget target, IProgress<double> progress, CancellationToken cancellationToken);
  26. }
  27. }