Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 18 additions & 4 deletions src/Umbraco.Core/Deploy/IFileSource.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,19 +61,31 @@ public interface IFileSource
/// <returns>The length of the file, or -1 if the file does not exist.</returns>
Task<long> GetFileLengthAsync(StringUdi udi, CancellationToken token);

// TODO (V14): Remove obsolete methods and default implementations for GetFiles and GetFilesAsync overloads.

/// <summary>
/// Gets files and store them using a file store.
/// </summary>
/// <param name="udis">The udis of the files to get.</param>
/// <param name="udis">The UDIs of the files to get.</param>
/// <param name="fileTypes">A collection of file types which can store the files.</param>
[Obsolete("Please use the method overload taking all parameters. This method overload will be removed in Umbraco 14.")]
void GetFiles(IEnumerable<StringUdi> udis, IFileTypeCollection fileTypes);

// TODO (V14): Remove obsolete method and default implementation for GetFilesAsync overloads.
/// <summary>
/// Gets files and store them using a file store.
/// </summary>
/// <param name="udis">The UDIs of the files to get.</param>
/// <param name="fileTypes">A collection of file types which can store the files.</param>
/// <param name="continueOnFileNotFound">A flag indicating whether to continue if a file isn't found or to stop and throw a FileNotFoundException.</param>
void GetFiles(IEnumerable<StringUdi> udis, bool continueOnFileNotFound, IFileTypeCollection fileTypes)
#pragma warning disable CS0618 // Type or member is obsolete
=> GetFiles(udis, fileTypes);
#pragma warning restore CS0618 // Type or member is obsolete

/// <summary>
/// Gets files and store them using a file store.
/// </summary>
/// <param name="udis">The udis of the files to get.</param>
/// <param name="udis">The UDIs of the files to get.</param>
/// <param name="fileTypes">A collection of file types which can store the files.</param>
/// <param name="token">A cancellation token.</param>
[Obsolete("Please use the method overload taking all parameters. This method overload will be removed in Umbraco 14.")]
Expand All @@ -82,10 +94,12 @@ public interface IFileSource
/// <summary>
/// Gets files and store them using a file store.
/// </summary>
/// <param name="udis">The udis of the files to get.</param>
/// <param name="udis">The UDIs of the files to get.</param>
/// <param name="fileTypes">A collection of file types which can store the files.</param>
/// <param name="continueOnFileNotFound">A flag indicating whether to continue if a file isn't found or to stop and throw a FileNotFoundException.</param>
/// <param name="token">A cancellation token.</param>
Task GetFilesAsync(IEnumerable<StringUdi> udis, IFileTypeCollection fileTypes, bool continueOnFileNotFound, CancellationToken token)
#pragma warning disable CS0618 // Type or member is obsolete
=> GetFilesAsync(udis, fileTypes, token);
#pragma warning restore CS0618 // Type or member is obsolete
}