Table of Contents

Method WriteStreamAtomicAsync

Namespace
Oscova.Agents.Utils
Assembly
Oscova.Agents.dll

WriteStreamAtomicAsync(string, Stream, CancellationToken)

Writes a stream to path atomically by staging beside the target before replacing it.

public static Task WriteStreamAtomicAsync(string path, Stream content, CancellationToken cancellationToken = default)

Parameters

path string
content Stream
cancellationToken CancellationToken

Returns

Task