public void BufferingWriter() { using var writer = new FileBufferingWriter(memoryThreshold: MemoryThreshold, asyncIO: false); foreach (var chunk in GetChunks()) { writer.Write(chunk.Span); } writer.Flush(); using var ms = new MemoryStream(content.Length); writer.CopyTo(ms); }