I have large file (usually 300 MB to 2 GB) which consists of smaller files. I want to unpack them to folder and I want to do that efficiently (zero-copy).
I found, that .NET Framework have TransmitFile method for that
using (StreamWriter writer = File.CreateText(outputPath))
{
HttpResponse response = new HttpResponse(writer);
response.TransmitFile(inputPath, offset, length);
}
but what about .NET Core, that I'm targeting...?
IHttpSendFileFeature Interface looks promising and it is probably implemented in OwinFeatureCollection class, but how can I use it?