using MediaBrowser.Model.Querying; using MediaBrowser.Model.Sync; using Interfaces.IO; using System; using System.IO; using System.Threading; using System.Threading.Tasks; namespace MediaBrowser.Controller.Sync { public interface IServerSyncProvider : ISyncProvider { /// /// Transfers the file. /// /// The stream. /// The path parts. /// The target. /// The progress. /// The cancellation token. /// Task. Task SendFile(Stream stream, string[] pathParts, SyncTarget target, IProgress progress, CancellationToken cancellationToken); /// /// Deletes the file. /// /// The identifier. /// The target. /// The cancellation token. /// Task. Task DeleteFile(string id, SyncTarget target, CancellationToken cancellationToken); /// /// Gets the file. /// /// The identifier. /// The target. /// The progress. /// The cancellation token. /// Task<Stream>. Task GetFile(string id, SyncTarget target, IProgress progress, CancellationToken cancellationToken); /// /// Gets the files. /// /// The query. /// The target. /// The cancellation token. /// Task<QueryResult<FileMetadata>>. Task> GetFiles(FileQuery query, SyncTarget target, CancellationToken cancellationToken); } public interface ISupportsDirectCopy { /// /// Sends the file. /// /// The path. /// The path parts. /// The target. /// The progress. /// The cancellation token. /// Task<SyncedFileInfo>. Task SendFile(string path, string[] pathParts, SyncTarget target, IProgress progress, CancellationToken cancellationToken); } }