IServerSyncProvider.cs 1.1 KB

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