16 implementations of SendFileAsync
Microsoft.AspNetCore.Http (1)
StreamResponseBodyFeature.cs (1)
86public virtual async Task SendFileAsync(string path, long offset, long? count, CancellationToken cancellationToken)
Microsoft.AspNetCore.Http.Results.Tests (3)
ServerSentEventsResultTests.cs (1)
328public Task SendFileAsync(string path, long offset, long? count, CancellationToken cancellationToken = default)
src\Shared\ResultsTests\PhysicalFileResultTestBase.cs (1)
443public Task SendFileAsync(string path, long offset, long? length, CancellationToken cancellation)
src\Shared\ResultsTests\VirtualFileResultTestBase.cs (1)
546public Task SendFileAsync(string path, long offset, long? length, CancellationToken cancellation)
Microsoft.AspNetCore.HttpLogging (1)
ResponseBufferingStream.cs (1)
193public async Task SendFileAsync(string path, long offset, long? count, CancellationToken cancellation)
Microsoft.AspNetCore.Mvc.Core.Test (2)
src\Shared\ResultsTests\PhysicalFileResultTestBase.cs (1)
443public Task SendFileAsync(string path, long offset, long? length, CancellationToken cancellation)
src\Shared\ResultsTests\VirtualFileResultTestBase.cs (1)
546public Task SendFileAsync(string path, long offset, long? length, CancellationToken cancellation)
Microsoft.AspNetCore.Owin (1)
OwinFeatureCollection.cs (1)
229Task IHttpResponseBodyFeature.SendFileAsync(string path, long offset, long? length, CancellationToken cancellation)
Microsoft.AspNetCore.ResponseCaching.Microbenchmarks (1)
ResponseCachingBenchmark.cs (1)
130public Task SendFileAsync(string path, long offset, long? count, CancellationToken cancellationToken = default)
Microsoft.AspNetCore.ResponseCompression (1)
ResponseCompressionBody.cs (1)
285public Task SendFileAsync(string path, long offset, long? count, CancellationToken cancellation)
Microsoft.AspNetCore.ResponseCompression.Tests (1)
ResponseCompressionMiddlewareTest.cs (1)
1456public Task SendFileAsync(string path, long offset, long? count, CancellationToken cancellation)
Microsoft.AspNetCore.Server.HttpSys (1)
RequestProcessing\RequestContext.FeatureCollection.cs (1)
489async Task IHttpResponseBodyFeature.SendFileAsync(string path, long offset, long? length, CancellationToken cancellation)
Microsoft.AspNetCore.Server.IIS (1)
Core\IISHttpContext.FeatureCollection.cs (1)
215Task IHttpResponseBodyFeature.SendFileAsync(string path, long offset, long? count, CancellationToken cancellation)
Microsoft.AspNetCore.Server.Kestrel.Core (1)
Internal\Http\HttpProtocol.FeatureCollection.cs (1)
337Task IHttpResponseBodyFeature.SendFileAsync(string path, long offset, long? count, CancellationToken cancellation)
Microsoft.AspNetCore.StaticAssets (1)
Development\StaticAssetDevelopmentRuntimeHandler.cs (1)
174public Task SendFileAsync(string path, long offset, long? count, CancellationToken cancellationToken = default)
Microsoft.AspNetCore.TestHost (1)
ResponseFeature.cs (1)
143public Task SendFileAsync(string path, long offset, long? count, CancellationToken cancellation)
27 references to SendFileAsync
Microsoft.AspNetCore.Http.Extensions (1)
SendFileResponseExtensions.cs (1)
120await sendFile.SendFileAsync(fileName, offset, count, localCancel);
Microsoft.AspNetCore.Http.Results.Tests (1)
src\Shared\ResultsTests\PhysicalFileResultTestBase.cs (1)
273.Setup(s => s.SendFileAsync(path, 0, null, CancellationToken.None))
Microsoft.AspNetCore.HttpLogging (1)
ResponseBufferingStream.cs (1)
196await _innerBodyFeature.SendFileAsync(path, offset, count, cancellation);
Microsoft.AspNetCore.Mvc.Core.Test (1)
src\Shared\ResultsTests\PhysicalFileResultTestBase.cs (1)
273.Setup(s => s.SendFileAsync(path, 0, null, CancellationToken.None))
Microsoft.AspNetCore.Owin (1)
OwinEnvironment.cs (1)
440{ OwinConstants.SendFiles.SendAsync, new FeatureMap<IHttpResponseBodyFeature>(feature => new SendFileFunc(feature.SendFileAsync)) },
Microsoft.AspNetCore.ResponseCompression (1)
ResponseCompressionBody.cs (1)
294return _innerBodyFeature.SendFileAsync(path, offset, count, cancellation);
Microsoft.AspNetCore.ResponseCompression.Tests (4)
ResponseCompressionMiddlewareTest.cs (4)
1092return sendFile.SendFileAsync("testfile1kb.txt", 0, null, CancellationToken.None); 1142return sendFile.SendFileAsync("testfile1kb.txt", 0, null, CancellationToken.None); 1192await feature.SendFileAsync("testfile1kb.txt", 0, null, CancellationToken.None); 1460return InnerFeature.SendFileAsync(path, offset, count, cancellation);
Microsoft.AspNetCore.Server.HttpSys.FunctionalTests (14)
ResponseSendFileTests.cs (14)
45await sendFile.SendFileAsync(string.Empty, 0, null, CancellationToken.None); 68return sendFile.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); 87return sendFile.SendFileAsync(RelativeFilePath, 0, null, CancellationToken.None); 106return sendFile.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); 125sendFile.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None).Wait(); 126return sendFile.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); 145return sendFile.SendFileAsync(AbsoluteFilePath, 0, FileLength / 2, CancellationToken.None); 166sendFile.SendFileAsync(AbsoluteFilePath, 1234567, null, CancellationToken.None)); 185sendFile.SendFileAsync(AbsoluteFilePath, 0, 1234567, CancellationToken.None)); 202return sendFile.SendFileAsync(AbsoluteFilePath, 0, 0, CancellationToken.None); 222return sendFile.SendFileAsync(AbsoluteFilePath, 0, null, CancellationToken.None); 243return sendFile.SendFileAsync(AbsoluteFilePath, 0, 10, CancellationToken.None); 264return sendFile.SendFileAsync(AbsoluteFilePath, 0, 0, CancellationToken.None); 291return sendFile.SendFileAsync(AbsoluteFilePath, 0, 10, CancellationToken.None);
Microsoft.AspNetCore.StaticAssets (2)
Development\StaticAssetDevelopmentRuntimeHandler.cs (2)
231return _original.SendFileAsync(fileInfo.PhysicalPath!, offset, actualCount, cancellationToken); 237return _original.SendFileAsync(fileInfo.PhysicalPath!, 0, fileInfo.Length, cancellationToken);
Microsoft.AspNetCore.StaticFiles.Tests (1)
StaticFileMiddlewareTests.cs (1)
87mockSendFile.Setup(m => m.SendFileAsync(It.IsAny<string>(), It.IsAny<long>(), It.IsAny<long?>(), It.IsAny<CancellationToken>()))