Interface IFileStore
Interface for a file store.
Namespace: DataWeb.Media
Assembly: DataWeb.Core.dll
Syntax
public interface IFileStore
Properties
Name
Gets the name of the file store.
Declaration
string Name { get; }
Property Value
Type | Description |
---|---|
string |
Methods
GetFileAsync(FileFilter, CancellationToken)
Gets a file that matches the specified filter.
Declaration
Task<FileData> GetFileAsync(FileFilter filter, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
FileFilter | filter | The FileFilter to apply to the file. |
CancellationToken | cancellationToken |
Returns
Type | Description |
---|---|
Task<FileData> | The file data that match the filter. |
GetFileSettings(string)
Gets the file settings.
Declaration
FileSettings GetFileSettings(string rawSettings)
Parameters
Type | Name | Description |
---|---|---|
string | rawSettings | The raw settings to parse. |
Returns
Type | Description |
---|---|
FileSettings | The structured file settings. |
GetFilesAsync(FileFilter, CancellationToken)
Gets a collection of files that match the specified filter.
Declaration
Task<IEnumerable<FileData>> GetFilesAsync(FileFilter filter, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
FileFilter | filter | The cref="FileFilter"/> to apply to the files. |
CancellationToken | cancellationToken |
Returns
Type | Description |
---|---|
Task<IEnumerable<FileData>> | A collection of file data that match the filter. |
UpdateIsInStorageAsync(string, bool, CancellationToken)
Updates the IsInStorage property of the file with the specified IdMaster.
Declaration
Task UpdateIsInStorageAsync(string fileIdMaster, bool isInStorage, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
string | fileIdMaster | The IdMaster of the file to update. |
bool | isInStorage | The value to set for the IsInStorage property. |
CancellationToken | cancellationToken |
Returns
Type | Description |
---|---|
Task |