Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ CopyToAsync() [4/4]

override Task System.IO.Strategies.AsyncWindowsFileStreamStrategy.CopyToAsync ( Stream destination,
int bufferSize,
CancellationToken cancellationToken )
inlinevirtual

Reimplemented from System.IO.Stream.

Definition at line 21 of file AsyncWindowsFileStreamStrategy.cs.

22 {
24 {
25 ThrowHelper.ThrowObjectDisposedException_FileClosed();
26 }
27 if (!CanRead)
28 {
29 ThrowHelper.ThrowNotSupportedException_UnreadableStream();
30 }
31 if (cancellationToken.IsCancellationRequested)
32 {
34 }
36 }
async Task AsyncModeCopyToAsync(Stream destination, int bufferSize, CancellationToken cancellationToken)
static Task FromCanceled(CancellationToken cancellationToken)
Definition Task.cs:3363

References System.IO.Strategies.OSFileStreamStrategy._fileHandle, System.IO.Strategies.AsyncWindowsFileStreamStrategy.AsyncModeCopyToAsync(), System.cancellationToken, System.IO.Strategies.OSFileStreamStrategy.CanRead, System.destination, System.Threading.Tasks.Task< TResult >.FromCanceled(), System.Runtime.InteropServices.SafeHandle.IsClosed, System.ThrowHelper.ThrowNotSupportedException_UnreadableStream(), and System.ThrowHelper.ThrowObjectDisposedException_FileClosed().