Synced
AtomicFile.WriteAllBytes
Section titled “AtomicFile.WriteAllBytes”
- Writes a complete byte payload and atomically installs it at the destination.
Required contracts
Section titled “Required contracts”API: engine
Project: Inno.Core.IO
Declaration
Section titled “Declaration”public static void Inno.Core.IO.AtomicFile.WriteAllBytes(string path, System.ReadOnlySpan<byte> data, bool overwrite = true)Parameters
Section titled “Parameters”Parameter path: The destination file path.
Parameter data: The complete file payload.
Parameter overwrite: Whether an existing destination may be replaced; false atomically rejects name collisions.
Exceptions
Section titled “Exceptions”Exception T:System.IO.IOException: Publication or cleanup fails, the destination already exists in create-only mode, or the filesystem cannot atomically publish a complete file. No copy fallback exposes partial content.
Exception T:System.PlatformNotSupportedException: The host does not provide an atomic create-only filesystem primitive.