public async Task RenameFileAsync(string sourceFilePath, string destinationFilePath) { var sourceKey = PathRelativeToSourceDirectory(sourceFilePath); var destinationKey = PathRelativeToSourceDirectory(destinationFilePath); await _s3Client.CopyObjectAsync(_bucketName, sourceKey, _bucketName, destinationKey).ConfigureAwait(false); await _s3Client.DeleteObjectAsync(_bucketName, sourceKey).ConfigureAwait(false); }
Task Delete(Amazon.S3.Model.S3Object item) { var request = new Amazon.S3.Model.DeleteObjectRequest { BucketName = item.BucketName, Key = item.Key }; return(S3Client.DeleteObjectAsync(request)); }