Cancel commands

This commit is contained in:
2023-07-28 13:08:46 +02:00
parent 12c9aa039a
commit ee42e38e45
19 changed files with 75 additions and 18 deletions

View File

@@ -15,7 +15,7 @@ public class LocalContentWriter : IContentWriter
_binaryWriter = new BinaryWriter(_writerStream);
}
public Task WriteBytesAsync(byte[] data, int? index = null)
public Task WriteBytesAsync(byte[] data, int? index = null, CancellationToken cancellationToken = default)
{
if (index != null)
{
@@ -28,7 +28,7 @@ public class LocalContentWriter : IContentWriter
return Task.CompletedTask;
}
public Task FlushAsync()
public Task FlushAsync(CancellationToken cancellationToken = default)
{
_binaryWriter.Flush();
return Task.CompletedTask;