Skip to content

Fix minor issues in [Typed]Results docs #55747

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
May 17, 2024
Merged
Show file tree
Hide file tree
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
14 changes: 5 additions & 9 deletions src/Http/Http.Results/src/Results.cs
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ public static IResult Bytes(
/// </summary>
/// <param name="fileStream">The <see cref="System.IO.Stream"/> with the contents of the file.</param>
/// <param name="contentType">The Content-Type of the file.</param>
/// <param name="fileDownloadName">The the file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="fileDownloadName">The file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="lastModified">The <see cref="DateTimeOffset"/> of when the file was last modified.
/// Used to configure the <c>Last-Modified</c> response header and perform conditional range requests.</param>
/// <param name="entityTag">The <see cref="EntityTagHeaderValue"/> to be configure the <c>ETag</c> response header
Expand Down Expand Up @@ -390,7 +390,7 @@ public static IResult File(
/// </summary>
/// <param name="stream">The <see cref="System.IO.Stream"/> to write to the response.</param>
/// <param name="contentType">The <c>Content-Type</c> of the response. Defaults to <c>application/octet-stream</c>.</param>
/// <param name="fileDownloadName">The the file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="fileDownloadName">The file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="lastModified">The <see cref="DateTimeOffset"/> of when the file was last modified.
/// Used to configure the <c>Last-Modified</c> response header and perform conditional range requests.</param>
/// <param name="entityTag">The <see cref="EntityTagHeaderValue"/> to be configure the <c>ETag</c> response header
Expand Down Expand Up @@ -418,7 +418,7 @@ public static IResult Stream(
/// </summary>
/// <param name="pipeReader">The <see cref="System.IO.Pipelines.PipeReader"/> to write to the response.</param>
/// <param name="contentType">The <c>Content-Type</c> of the response. Defaults to <c>application/octet-stream</c>.</param>
/// <param name="fileDownloadName">The the file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="fileDownloadName">The file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="lastModified">The <see cref="DateTimeOffset"/> of when the file was last modified.
/// Used to configure the <c>Last-Modified</c> response header and perform conditional range requests.</param>
/// <param name="entityTag">The <see cref="EntityTagHeaderValue"/> to be configure the <c>ETag</c> response header
Expand All @@ -439,14 +439,10 @@ public static IResult Stream(

/// <summary>
/// Allows writing directly to the response body.
/// <para>
/// This supports range requests (<see cref="StatusCodes.Status206PartialContent"/> or
/// <see cref="StatusCodes.Status416RangeNotSatisfiable"/> if the range is not satisfiable).
/// </para>
/// </summary>
/// <param name="streamWriterCallback">The callback that allows users to write directly to the response body.</param>
/// <param name="contentType">The <c>Content-Type</c> of the response. Defaults to <c>application/octet-stream</c>.</param>
/// <param name="fileDownloadName">The the file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="fileDownloadName">The file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="lastModified">The <see cref="DateTimeOffset"/> of when the file was last modified.
/// Used to configure the <c>Last-Modified</c> response header and perform conditional range requests.</param>
/// <param name="entityTag">The <see cref="EntityTagHeaderValue"/> to be configure the <c>ETag</c> response header
Expand Down Expand Up @@ -782,7 +778,7 @@ private static void CopyExtensions(IDictionary<string, object?>? extensions, Htt

/// <summary>
/// Produces a <see cref="StatusCodes.Status201Created"/> response.
/// </summary>
/// </summary>
/// <returns>The created <see cref="IResult"/> for the response.</returns>
public static IResult Created()
=> TypedResults.Created();
Expand Down
12 changes: 4 additions & 8 deletions src/Http/Http.Results/src/TypedResults.cs
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ public static FileContentHttpResult Bytes(
/// </remarks>
/// <param name="fileStream">The <see cref="System.IO.Stream"/> with the contents of the file.</param>
/// <param name="contentType">The Content-Type of the file.</param>
/// <param name="fileDownloadName">The the file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="fileDownloadName">The file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="lastModified">The <see cref="DateTimeOffset"/> of when the file was last modified.
/// Used to configure the <c>Last-Modified</c> response header and perform conditional range requests.</param>
/// <param name="entityTag">The <see cref="EntityTagHeaderValue"/> to be configure the <c>ETag</c> response header
Expand Down Expand Up @@ -393,7 +393,7 @@ public static FileStreamHttpResult File(
/// </remarks>
/// <param name="stream">The <see cref="System.IO.Stream"/> to write to the response.</param>
/// <param name="contentType">The <c>Content-Type</c> of the response. Defaults to <c>application/octet-stream</c>.</param>
/// <param name="fileDownloadName">The the file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="fileDownloadName">The file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="lastModified">The <see cref="DateTimeOffset"/> of when the file was last modified.
/// Used to configure the <c>Last-Modified</c> response header and perform conditional range requests.</param>
/// <param name="entityTag">The <see cref="EntityTagHeaderValue"/> to be configure the <c>ETag</c> response header
Expand Down Expand Up @@ -431,7 +431,7 @@ public static FileStreamHttpResult Stream(
/// </remarks>
/// <param name="pipeReader">The <see cref="System.IO.Pipelines.PipeReader"/> to write to the response.</param>
/// <param name="contentType">The <c>Content-Type</c> of the response. Defaults to <c>application/octet-stream</c>.</param>
/// <param name="fileDownloadName">The the file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="fileDownloadName">The file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="lastModified">The <see cref="DateTimeOffset"/> of when the file was last modified.
/// Used to configure the <c>Last-Modified</c> response header and perform conditional range requests.</param>
/// <param name="entityTag">The <see cref="EntityTagHeaderValue"/> to be configure the <c>ETag</c> response header
Expand Down Expand Up @@ -459,14 +459,10 @@ public static FileStreamHttpResult Stream(

/// <summary>
/// Allows writing directly to the response body.
/// <para>
/// This supports range requests (<see cref="StatusCodes.Status206PartialContent"/> or
/// <see cref="StatusCodes.Status416RangeNotSatisfiable"/> if the range is not satisfiable).
/// </para>
/// </summary>
/// <param name="streamWriterCallback">The callback that allows users to write directly to the response body.</param>
/// <param name="contentType">The <c>Content-Type</c> of the response. Defaults to <c>application/octet-stream</c>.</param>
/// <param name="fileDownloadName">The the file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="fileDownloadName">The file name to be used in the <c>Content-Disposition</c> header.</param>
/// <param name="lastModified">The <see cref="DateTimeOffset"/> of when the file was last modified.
/// Used to configure the <c>Last-Modified</c> response header and perform conditional range requests.</param>
/// <param name="entityTag">The <see cref="EntityTagHeaderValue"/> to be configure the <c>ETag</c> response header
Expand Down