public void DownloadFile(string fileId, Stream stream, CancellationToken token = new CancellationToken()) { var command = new DownloadFileCommand(this, fileId, stream, Settings, token, WebProxy); command.FileDownloadProgressChanged += command_FileDownloadProgressChanged; command.Execute(); }
public void DownloadFile(FileCompact file, Stream stream, CancellationToken token = new CancellationToken()) { var command = new DownloadFileCommand(this, file, stream, Settings, token, WebProxy); command.FileDownloadProgressChanged += command_FileDownloadProgressChanged; command.Execute(); }
public void DownloadFile(FileCompact file, string filePath, int maxChunkSize, int maxThreadCount, CancellationToken token = new CancellationToken()) { var command = new DownloadFileCommand(this, file, filePath, Settings, maxThreadCount, maxChunkSize, token); command.FileDownloadProgressChanged += command_FileDownloadProgressChanged; command.Execute(); }
public void DownloadFile(FileCompact file, string filePath, CancellationToken token = new CancellationToken()) { var command = new DownloadFileCommand(this, file, filePath, Settings, token); command.FileDownloadProgressChanged += command_FileDownloadProgressChanged; command.Execute(); }
public Task DownloadFileTaskByIdAsync(string fileId, Stream stream, CancellationToken token = new CancellationToken()) { var command = new DownloadFileCommand(this, fileId, stream, ClientSettings, token); command.FileDownloadProgressChanged += command_FileDownloadProgressChanged; return Task.Factory.StartNew(command.Execute, token); }