Skip to main content

S3StorageFile

A class in Alta.IO, Alta.Utilities.

A file object in an S3 bucket, used through the IFileAccess storage interface. Probably server or tooling only, as it needs S3 credentials.

Constructors​

MemberWhat it is
S3StorageFile(string bucketName, string fullName)Creates a S3StorageFile from bucketName and fullName.

Fields​

1 private and internal field
MemberWhat it is
private static Logger loggerNLog logger for this class.

Properties​

MemberWhat it is
bool Exists { get; }Whether the object exists, by fetching it. Any error counts as not existing.

Methods​

MemberWhat it is
async Task DownloadAsync(Stream localStream)Streams the object's contents into the given local stream.
async Task<bool> IsExistingAsync()Async version of Exists.
void Refresh()Does nothing for S3 files.
void Upload(Stream fileStream)Uploads the stream to this key, blocking.
async Task UploadAsync(Stream fileStream)Uploads the stream to this key.

Used in​

Members of other types that take, return or hold a S3StorageFile: