20 lines
965 B
C#
20 lines
965 B
C#
namespace Musify.Application.Contracts.Infrastructure
|
|
{
|
|
public interface IStorageService
|
|
{
|
|
Task<Stream> GetFileAsync(string bucket, string key, CancellationToken cancellationToken);
|
|
|
|
Task<string> GetUrlAsync(string bucket, string key, TimeSpan ExpirationTime, CancellationToken cancellationToken);
|
|
|
|
Task UploadFileAsync(string filePath, string bucket, string key, CancellationToken cancellationToken);
|
|
|
|
Task UploadFileAsync(Stream sourceStream, string contentType, string bucket, string key, CancellationToken cancellationToken);
|
|
|
|
Task TransferFilesAsync(string sourceDirectory, string bucket, string route, CancellationToken cancellationToken);
|
|
|
|
Task RemoveFileAsync(string bucket, string key, CancellationToken cancellationToken);
|
|
|
|
Task CopyFileAsync(string sourceBucket, string sourceKey, string destinationBucket, string destinationKey,
|
|
CancellationToken cancellationToken);
|
|
}
|
|
} |